You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
SCRAM-SHA-256 support for states.postgres_user #51217
Current implementation either sends and compares plaintext or an md5hash.
There's no way to send plaintext for the server to hash, because it also adds UNENCRYPTED to the query.
ERROR: UNENCRYPTED PASSWORD is no longer supported
@dwoz not sure what you mean by example state, but see linked commit.
You can see from saltstack's source code that the states.postgres_user state is only able to compare and set unencrypted or MD5 passwords. To use SCRAM passwords, PostgreSQL 10 or higher is required.
sadly without SCRAM support the current postgres_user state has very limited usefulness. please also let the module work with already encrypted passwords like:
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
If this issue is closed prematurely, please leave a comment and we will gladly reopen the issue.
Activity
[-]SCRAM-SHA-1 support for states.postgres_user[/-][+]SCRAM-SHA-256 support for states.postgres_user[/+]OrangeDog commentedon Jan 17, 2019
Python 3 implementation of postgres' algorithm
dwoz commentedon Jan 17, 2019
@OrangeDog Can you provide me with an example state that I can use to test this?
Example workaround for saltstack/salt#51217
OrangeDog commentedon Jan 18, 2019
@dwoz not sure what you mean by example state, but see linked commit.
You can see from saltstack's source code that the
states.postgres_userstate is only able to compare and set unencrypted or MD5 passwords. To use SCRAM passwords, PostgreSQL 10 or higher is required.minusf commentedon Sep 12, 2019
sadly without SCRAM support the current
postgres_userstate has very limited usefulness. please also let the module work with already encrypted passwords like:stale commentedon Jan 7, 2020
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
If this issue is closed prematurely, please leave a comment and we will gladly reopen the issue.
OrangeDog commentedon Jan 7, 2020
Still a desired feature.
1 remaining item
OrangeDog commentedon Nov 10, 2020
There doesn't seem to be any python library providing just saslprep.
There is an implementation in
pymongo.Add SCRAM-SHA-256 support to postgres states (#59034)