openhab / openhabian

openHABian - empowering the smart home, for Raspberry Pi and Debian systems
https://community.openhab.org/t/13379
ISC License
818 stars 251 forks source link

Update openhabian.bash to support yescrypt which is default hash with… #1851

Closed WolfgangSn closed 3 months ago

WolfgangSn commented 3 months ago

… bookworm

To support default password detection when OS is bookworm yescrypt hash needs to be supported. Modified code detects if yescrypt is used.

WolfgangSn commented 3 months ago

Or is that implicit because of the number of fields ?

The code needs to work on both, bookworm and on bullseye.

Indeed the number of the fields make the difference. Due to this is it will run on both OSs. According to https://manpages.debian.org/bullseye/libcrypt-dev/crypt.5.en.html even bullseye is already able to use yescrypt. Besides that not making it depending on the OS ( bookworm vs. bullseye ) it should run even with other OSs. Next to yesrypt also ghost-yescrypt uses the same number of fields and is covered. In the alternative path ( case * ) other hash methods are covered in the same way as before/without the patch.

mstormi commented 3 months ago

Closes: #1843