Similar to the unix passwd -l account to only allow su logins. Need this to do my SSO system properly.
## <bountysource-plugin>
Want to back this issue? **[Post a bounty on it!](https://www.bountysource.com/issues/286465-allow-password-less-accounts-which-cannot-be-looged-into-without-a-module-authorizing?utm_campaign=plugin&utm_content=tracker%2F1759&utm_medium=issues&utm_source=github)** We accept bounties via [Bountysource](https://www.bountysource.com/?utm_campaign=plugin&utm_content=tracker%2F1759&utm_medium=issues&utm_source=github).
</bountysource-plugin>
<!-- github-sync-id:13677864 -->
Uhm, just do a big hack and set a "broken" password hash? E.g. pUser->SetPass("Disabled", CUser::HASH_MD5);
(A little less ugly approach would be to add a new value to that eHashType enum which means "disabled", dunno if that is worth it)
P.S.: passwd -l just does the same: It "breaks" the password hash by prefixing it with a "!".
Uhm, just do a big hack and set a "broken" password hash? E.g. pUser->SetPass("Disabled", CUser::HASH_MD5);
(A little less ugly approach would be to add a new value to that eHashType enum which means "disabled", dunno if that is worth it)
P.S.: passwd -l just does the same: It "breaks" the password hash by prefixing it with a "!".
<!-- github-comment-id:17117156 -->
@md-5 what did you do to accomplish your implementation?
The cyrusauth module does to SetPass on generic creations, the problem is that a user can still come back and set a password, thus invalidating the pass through.
@md-5 what did you do to accomplish your implementation?
The cyrusauth module does to SetPass on generic creations, the problem is that a user can still come back and set a password, thus invalidating the pass through.
https://github.com/znc/znc/blob/2b8e3f997f5d1a154e9c6e8c8efb9c115834afda/modules/cyrusauth.cpp#L137-L140
<!-- github-comment-id:93785463 -->
I wish that loging back in via SSO would reset it back to the ::, but it doesnt as far as i can see.
Also, it sounds nice to let breaking SSO be their decision, but typically your SSO system has enforced password policies, including change frequency. If they bypass it here they can 'make it easier' for their IRC config, while lowering your security posture.
I wish that loging back in via SSO would reset it back to the ::, but it doesnt as far as i can see.
Also, it sounds nice to let breaking SSO be their decision, but typically your SSO system has enforced password policies, including change frequency. If they bypass it here they can 'make it easier' for their IRC config, while lowering your security posture.
<!-- github-comment-id:94471623 -->
I wish that loging back in via SSO would reset it back to the ::, but it doesnt as far as i can see.
My addon does
> I wish that loging back in via SSO would reset it back to the ::, but it doesnt as far as i can see.
My addon does
<!-- github-comment-id:94619504 -->
I noticed i'm on 1.4 (i install from epel) and so I'm gonna eval the 1.6 release as soon as I can.
That being said, in the scenario i listed they would have to reason to log back in with their SSO password, and thus it would never reset, so that is a mute point. It seems that a better security posture would be achieved by disabling local auth explicitly if using external auth method.
I noticed i'm on 1.4 (i install from epel) and so I'm gonna eval the 1.6 release as soon as I can.
That being said, in the scenario i listed they would have to reason to log back in with their SSO password, and thus it would never reset, so that is a mute point. It seems that a better security posture would be achieved by disabling local auth explicitly if using external auth method.
<!-- github-comment-id:95416307 -->
It seems that a better security posture would be achieved by disabling local auth explicitly if using external auth method.
Easily done with a small tweak to your SSO addon
> It seems that a better security posture would be achieved by disabling local auth explicitly if using external auth method.
Easily done with a small tweak to your SSO addon
<!-- github-comment-id:95469261 -->
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Similar to the unix passwd -l account to only allow su logins. Need this to do my SSO system properly.
Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.
Also, this could be used in conjunction with the certfile and cyrus modules.
Uhm, just do a big hack and set a "broken" password hash? E.g. pUser->SetPass("Disabled", CUser::HASH_MD5);
(A little less ugly approach would be to add a new value to that eHashType enum which means "disabled", dunno if that is worth it)
P.S.: passwd -l just does the same: It "breaks" the password hash by prefixing it with a "!".
I took a leaf from the Cyrus module and did just that. Would be nice to have the proper web/status hook.
@md-5 what did you do to accomplish your implementation?
The cyrusauth module does to SetPass on generic creations, the problem is that a user can still come back and set a password, thus invalidating the pass through.
https://github.com/znc/znc/blob/2b8e3f997f5d1a154e9c6e8c8efb9c115834afda/modules/cyrusauth.cpp#L137-L140
I did the same as cyrus above
ok. so how are you preventing them from changing their passwords and thus bypassing your backend's password system
I'm not.
do you care? (bring serious, not snide)
Not really, if they want to break their SSO that is their decision :p
Logging in again with their SSO password will set their hash back to :: and make them require that pass.
I wish that loging back in via SSO would reset it back to the ::, but it doesnt as far as i can see.
Also, it sounds nice to let breaking SSO be their decision, but typically your SSO system has enforced password policies, including change frequency. If they bypass it here they can 'make it easier' for their IRC config, while lowering your security posture.
My addon does
I noticed i'm on 1.4 (i install from epel) and so I'm gonna eval the 1.6 release as soon as I can.
That being said, in the scenario i listed they would have to reason to log back in with their SSO password, and thus it would never reset, so that is a mute point. It seems that a better security posture would be achieved by disabling local auth explicitly if using external auth method.
Easily done with a small tweak to your SSO addon