Code Monkey home page Code Monkey logo

Comments (24)

Adrianordp avatar Adrianordp commented on May 20, 2024

I'm pulling the fix

from wifi-password.

Adrianordp avatar Adrianordp commented on May 20, 2024

The pull request #5 fixes it.

from wifi-password.

sdushantha avatar sdushantha commented on May 20, 2024

Closing this issue since it has been fixed in #5

from wifi-password.

littlediobolic avatar littlediobolic commented on May 20, 2024

Just tested the newest version and this error seems to persist.

$ sudo wifi-password
ERROR: Can't find the 'iwgetid' command

from wifi-password.

theniwo avatar theniwo commented on May 20, 2024

I get:
ERROR: You need to run '/home/niwo/.local/bin/wifi-password' as root
and when run with sudo
sudo: wifi-password: command not found
:D

from wifi-password.

sdushantha avatar sdushantha commented on May 20, 2024

I don't have a Linux machine at the moment. Would you guys be willing to try and figure out why this error is arising?

from wifi-password.

littlediobolic avatar littlediobolic commented on May 20, 2024

Sure thing, after looking my box does not have the iwgetid binary. I am trying to locate and install it and see if that fixes the problem.

from wifi-password.

theniwo avatar theniwo commented on May 20, 2024

Isn't it possible for you to run a virtual machine?

from wifi-password.

sdushantha avatar sdushantha commented on May 20, 2024

@littlediobolic The only computer I have is my school MacBook. We unfortunately have restrictions when it comes to installing apps on our computers. So I can't install a virtual machine.

from wifi-password.

littlediobolic avatar littlediobolic commented on May 20, 2024

That's the problem, which I guess was obvious. I resolved by installing the wireless-tools package on my machine to get the iwgetid command.

For Arch/Manjaro: sudo pacman -S wireless_tools
For Ubuntu: sudo apt-get install wireless-tools

I'm not super programming savvy so I probably couldnt write something to install those packages on install, but I could make a PR with comments to install wireless-tools if you'd like?

from wifi-password.

theniwo avatar theniwo commented on May 20, 2024

install those packages on install

Not a good idea. Better print an error message that the package is missing. Also, if it is required it should to be mentioned in the readme

from wifi-password.

Adrianordp avatar Adrianordp commented on May 20, 2024

ERROR: You need to run '/home/niwo/.local/bin/wifi-password' as root
and when run with sudo
sudo: wifi-password: command not found

@theniwo Uninstall with sudo and without sudo:
pip3 uninstall wifi-password ; sudo pip3 uninstall wifi-password

Then reinstall via:
sudo pip3 install wifi-password.

Tell us if it works now.

from wifi-password.

theniwo avatar theniwo commented on May 20, 2024

ERROR: Cound not find password

(Wasn't that typo also fixed in the pr by ImranVirani)

from wifi-password.

jans-de avatar jans-de commented on May 20, 2024

That's the problem, which I guess was obvious. I resolved by installing the wireless-tools package on my machine to get the iwgetid command.

For Arch/Manjaro: sudo pacman -S wireless-tools
For Ubuntu: sudo apt-get install wireless-tools

I'm not super programming savvy so I probably couldnt write something to install those packages on install, but I could make a PR with comments to install wireless-tools if you'd like?

The package for Arch/Manjaro is actually called wireless_tools so the command is sudo pacman -S wireless_tools

from wifi-password.

littlediobolic avatar littlediobolic commented on May 20, 2024

The package for Arch/Manjaro is actually called wireless_tools so the command is sudo pacman -S wireless_tools

Yup just noticed and edited my comment. Im working on a PR to add this to the README and to the error message

from wifi-password.

sdushantha avatar sdushantha commented on May 20, 2024

I am closing this PR as this issue seems to be fixed

from wifi-password.

 avatar commented on May 20, 2024

I am closing this PR as this issue seems to be fixed

I'm in Debian 10, the problem persist after installing wireless-tools via APT.

ERROR: Can't find the 'iwgetid' command
Please ensure wireless-tools is installed on your machine.

If I go with sudo:

ERROR: Cound not find password

from wifi-password.

littlediobolic avatar littlediobolic commented on May 20, 2024

@Engineer22
Is iwgetid present on your system?

which iwgetid

from wifi-password.

Adrianordp avatar Adrianordp commented on May 20, 2024

@Engineer22 Your output for
/etc/NetworkManager/system-connections/
has your connection configuration files for each SSID you've connected. On Ubuntu, these files has the extension nmconnection. How does Debian's connection files look like?

from wifi-password.

 avatar commented on May 20, 2024

@Adrianordp @littlediobolic

these are the results with the SSIDs manipulated:

sudo which iwgetid
/usr/sbin/iwgetid

cd /etc/NetworkManager/system-connections/
ls
name1.nmconnection name2.nmconnection

from wifi-password.

Adrianordp avatar Adrianordp commented on May 20, 2024

Your SSID appears when you input
iwgetid -r
on terminal?

from wifi-password.

 avatar commented on May 20, 2024

Yes it does.

sudo iwgetid -r
name2

from wifi-password.

littlediobolic avatar littlediobolic commented on May 20, 2024

Does cat /etc/NetworkManager/system-connections/{ssid}.nmconnection | grep psk= return anything? Replacing {ssid} for name2 of course

from wifi-password.

 avatar commented on May 20, 2024

I found the problem.

I have 2 SSIDs, one named name1 and one named name2. Both have space between them:

name 1 & name 2

after reading again the results of /etc/NetworkManager/system-connections/ they're displayed as 'name 1' & 'name 2'.
If I create a new AP and name it as name3 (no space), the script prints successfully.

The program needs to take into consideration that some SSIDs may have space between their names.

from wifi-password.

Related Issues (20)

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.