Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Got an error #1

Open
allenchak opened this issue Jun 6, 2023 · 1 comment
Open

Got an error #1

allenchak opened this issue Jun 6, 2023 · 1 comment

Comments

@allenchak
Copy link

python3 /opt/homebrew/lib/python3.11/site-packages/rtspscanner.py -m scan -c admin:admin -a 192.168.1.118 -p 554
Traceback (most recent call last):
  File "/opt/homebrew/lib/python3.11/site-packages/rtspscanner.py", line 321, in <module>
    main()
  File "/opt/homebrew/lib/python3.11/site-packages/rtspscanner.py", line 274, in main
    scanner.scanner()
  File "/opt/homebrew/lib/python3.11/site-packages/rtspscanner.py", line 132, in scanner
    self.scanResults = {"cameras":self.cameras,"flaky":flaky,"portscan":results}
                                                       ^^^^^
UnboundLocalError: cannot access local variable 'flaky' where it is not associated with a value

Using:

  • macOS Big Sur 11.2.2
  • Python 3.11.3
  • pip 23.0.1
  • beard-portscan 0.1.5
  • Pillow 9.5.0
  • requests 2.31.0
  • rtspscanner 0.1.5
@allenchak
Copy link
Author

Oh, I fix it, just move the flaky = [] before the for loop is OK

Result:

        flaky = []
        for result in results:

Thanks for your effort, but may I know how to using a File for the RTSP path in the argument.
rtspscanner -m scan -c admin:admin -a 192.168.1.118 -pp ~/rtsp_path.csv

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant