I activated the "password encryption aes" command on one of my test routers and put the same IKEv1 PSKs and master keys. The encrypted result is not the same the two routers, which is completely logical because there must be an IV used to prevent the same inputs from having the same output. However, if I copy paste the encrypted PSK from the first router to the second one, it works well and I can establish the IPSEC tunnel.
Can someone explain me why copying the encrypted key to the other router work, please?