-
Notifications
You must be signed in to change notification settings - Fork 19
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
24hr password reset still occurs if password updated manually #142
Comments
crontab: https://github.com/sudomesh/sudowrt-firmware/blob/master/files/etc/crontabs/root This is what cron runs: https://github.com/sudomesh/sudowrt-firmware/blob/master/files/opt/mesh/pw_reset @Juul noted that the crontab is set to run at midnight. We dont' think it's actually wwaiting 24hrs... |
I suggested it would be a good design goal to have these scripts that run via cront not |
Here's a proposed fix in the form of an edit to
Every time the router is on when the hour changes (e.g. exactly 6:00 pm, exactly 7:00 pm) a counter is increased in the file Question: In case the password isn't changed, and no ssh keys have been added to authorized_keys, after 24 hours should we install an ssh key so we can remotely reset the password for people? Warning that I haven't actually tested the above on a sudowrt router yet. |
Oh and for the above script change to work you will have to change
|
@Juul I like the password reset script change. 👍 @gobengo I like the idea of not destroying evidence. Wondering if we can do it with fewer moving parts and unexpected behaviors (e.g. when deleting the "this_thing_happened" file, which could easily look like cruft, and accidentally enabling some sleeping tasks). What about leaving a commented version of the cron job in place, with an additional line of explanation. Like:
|
I think I've addressed the issue with a lightly modified version the script suggested by @Juul . Tested on a virtual machine, and currently testing on an actual node (with an actual build of the firmware!). |
❤️❤️❤️ cool that it works with the admin password now too |
Excerpt from meeting
** cronjob runs every 24 hours
** Idea: log in before then and change password. Otherwise, cronjob changes it for you.
** Problem: If you don't remove the cronjob when you change your password, it just changes it again to something you don't know.
** eenblam - let's just fix that tonight.
** juul - have a tiny script for installing your ssh public key onto a node to bypass these quirks https://gist.github.com/Juul/726d85b429b394e2bdde375ef7de2e71
The text was updated successfully, but these errors were encountered: