Git Product home page Git Product logo

f2b-sophosxg's People

Contributors

e-cite avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

f2b-sophosxg's Issues

ERROR 7f55eccee250 -- stderr: "AttributeError: 'NoneType' object has no attribute 'find'"

Hello, thank you very much for this script, I tried it today on a fresh Ubuntu 22.04 Install, but ran into an error.
I don't know if did something wrong, maybe you can help me.

i checked /var/log/fail2ban.log:

[5297]: ERROR 7f55eccee250 -- exec: python3 /usr/local/sbin/f2b-sophosxg.py ban --ip 192.168.223.25
2023-03-09 06:09:50,843 fail2ban.utils [5297]: ERROR 7f55eccee250 -- stdout: 'Ban: Banning single IP 192.168.223.25'
2023-03-09 06:09:50,843 fail2ban.utils [5297]: ERROR 7f55eccee250 -- stderr: 'Traceback (most recent call last):'
2023-03-09 06:09:50,843 fail2ban.utils [5297]: ERROR 7f55eccee250 -- stderr: ' File "/usr/local/sbin/f2b-sophosxg.py", line 66, in '
2023-03-09 06:09:50,843 fail2ban.utils [5297]: ERROR 7f55eccee250 -- stderr: ' ret = f2b.ban(args.ip)'
2023-03-09 06:09:50,844 fail2ban.utils [5297]: ERROR 7f55eccee250 -- stderr: ' File "/usr/local/lib/f2bsophosxg/libf2bsophosxg.py", line 151, in ban'
2023-03-09 06:09:50,844 fail2ban.utils [5297]: ERROR 7f55eccee250 -- stderr: ' if not self.sxg.isApiCallSuccessful(response): return 1'
2023-03-09 06:09:50,844 fail2ban.utils [5297]: ERROR 7f55eccee250 -- stderr: ' File "/usr/local/lib/f2bsophosxg/libsophosxg.py", line 80, in isApiCallSuccessful'
2023-03-09 06:09:50,844 fail2ban.utils [5297]: ERROR 7f55eccee250 -- stderr: ' loginStatusText = self.xml_getRespLoginStatus(response.content)'
2023-03-09 06:09:50,844 fail2ban.utils [5297]: ERROR 7f55eccee250 -- stderr: ' File "/usr/local/lib/f2bsophosxg/libsophosxg.py", line 52, in xml_getRespLoginStatus'
2023-03-09 06:09:50,844 fail2ban.utils [5297]: ERROR 7f55eccee250 -- stderr: " loginStatusMsg = login.find('status').text"
2023-03-09 06:09:50,844 fail2ban.utils [5297]: ERROR 7f55eccee250 -- stderr: "AttributeError: 'NoneType' object has no attribute 'find'"
2023-03-09 06:09:50,844 fail2ban.utils [5297]: ERROR 7f55eccee250 -- returned 1
2023-03-09 06:09:50,844 fail2ban.actions [5297]: ERROR Failed to execute ban jail 'sshd' action 'sophosxg' info 'ActionInfo({'ip': '192.168.223.25', 'family': 'inet4', 'fid': <function Actions.ActionInfo. at 0x7f55ed64c1f0>, 'raw-ticket': <function Actions.ActionInfo. at 0x7f55ed64c8b0>})': Error banning 192.168.223.25

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.