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

WirelessGoPro asks for sudo password even if launched as sudo #578

Closed
grighi96 opened this issue Jul 30, 2024 · 3 comments
Closed

WirelessGoPro asks for sudo password even if launched as sudo #578

grighi96 opened this issue Jul 30, 2024 · 3 comments
Labels
bug Something isn't working demos Relating to demos wontfix This will not be worked on

Comments

@grighi96
Copy link

Hello, I'm implementing a Python script on a Raspberry Pi 3 to control a gopro via wifi.
I tried the gopro-wifi demo both as sudo and standard user and in both case it works. But in the standard user case it asks for sudo password and it accepts even a wrong password.
Then I created my personal Python script and if I launch it as sudo it keeps asking for the sudo password and I get the "Invalid password" error even if the password is correct.
Am I doing something wrong?

@github-actions github-actions bot added the triage Needs to be reviewed and assigned label Jul 30, 2024
@grighi96 grighi96 changed the title WirelessGoPro asks for sudo password WirelessGoPro asks for sudo password even if launched as sudo Jul 30, 2024
@grighi96
Copy link
Author

UPDATE: I looked at the log files and in the gopro-wifi demo I can see that when executed as sudo it gets:
org.freedesktop.NetworkManager.enable-disable-wifi yes
org.freedesktop.NetworkManager.wifi.scan yes
so it doesn't ask for a sudo password.

When executed as standard user it gets:
org.freedesktop.NetworkManager.enable-disable-wifi no
org.freedesktop.NetworkManager.wifi.scan auth
and it asks for a password and even if I input a wrong password it works.
On my script I get no and auth both with and without sudo and it doesn't accepts any password.

@grighi96 grighi96 reopened this Jul 31, 2024
@grighi96
Copy link
Author

SOLVED: I had to change the NetworkManager policy to allow scan and enable-disable-wifi

@tcamise-gpsw
Copy link
Collaborator

Glad you got it working.
FWIW the way that this is designed to work in demos is that you use the --password argument to read your password from stdin.

Anyway I don't see any changes here so will close this.

@tcamise-gpsw tcamise-gpsw closed this as not planned Won't fix, can't repro, duplicate, stale Aug 2, 2024
@tcamise-gpsw tcamise-gpsw added bug Something isn't working wontfix This will not be worked on tutorials Relating to tutorials and removed triage Needs to be reviewed and assigned labels Aug 2, 2024
@tcamise-gpsw tcamise-gpsw added demos Relating to demos and removed tutorials Relating to tutorials labels Aug 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working demos Relating to demos wontfix This will not be worked on
Projects
Status: To do
Development

No branches or pull requests

2 participants