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
When using this python script the switch will not accept the calculated hash
# Program output
[3] Type 8 (PBKDF2-HMAC-SHA256)
[4] Type 9 (Scrypt)
[5] Exit
Your selection: 4
Enter a Plain Text Password to convert: TestText
Your Cisco Type 9 password hash is: $9$icj5vfNlTumwNB$64epo7fnBl03uRLMQT0Q5VWaOvHPipqZLFFsCbYdl4Y
# Switch output
TEST(config)# username test privilege 15 secret 9 $9$icj5vfNlTumwNB$64epo7fnBl03uRLMQT0Q5VWaOvHPipqZLFFsCbYdl4Y
ERROR: The secret you entered is not a valid encrypted secret.
To enter an UNENCRYPTED secret, do not specify type 9 encryption.
When you properly enter an UNENCRYPTED secret, it will be encrypted
The text was updated successfully, but these errors were encountered:
I've tried to use the salt that the switch has stored as a constant and calculated the hash. The has value calculated is the same as the hash in cisco running config.
for_inrange(14):
salt_chars.append(random.choice(cisco_b64chars))
salt="".join(salt_chars)
salt="pPsCfoFx0krK.E"# <------------####################################################
[4] Type9 (Scrypt)
[5] ExitYourselection: 4EnteraPlainTextPasswordtoconvert: TestTextYourCiscoType9passwordhashis: $9$pPsCfoFx0krK.E$yMeHAVYfOMb4yLYg9CkQyKaXkDH01slV9KdvNx7Afg##################################################### Switch output from running configTEST(config)# TEST(config)#do show run | i ....username .... privilege15secret9 $9$pPsCfoFx0krK.E$yMeHAVYfOMb4yLYg9CkQyKaXkDH01slV9KdvNx7Afg2
It seems that the salt is not a random value for IOS-XE 17.03.04
When using this python script the switch will not accept the calculated hash
The text was updated successfully, but these errors were encountered: