$1$ marks the MD5-crypt password hash also commonly used in past years for user passwords in Linux systems. In that function, it's now been pretty much superseded by the similar SHA256-crypt and SHA512-crypt hashes (
$6$). None of those are just a single run of the underlying hash function, but iterate the hash repeatedly and include a salt (the part between the second and third
$ sign, so
mERr. On the other hand,
e04efcfd... is the result of a single evaluation of MD5 on the string
The underlying structure of those algorithms is rather needlessly complex, but apart from that, they're somewhat similar to PBKDF2. Other hashes might be suggested for new implementations, but compatibility sticks hard. The one Cisco Catalyst I have access to also seems to support other hashes (try
enable algorith-type ?). I don't know if those particular algorithms are used elsewhere.
I asked a question about the differences of PBKDF2 and the SHA2-based crypt hashes some years back, one of the answers there also mention MD5-crypt.
MD5-crypt hashes can be calculated with the
crypt() function in glibc, which is easily accessed with e.g. Perl:
$ perl -le 'print crypt("weakpassword", q/$1$mERr$/)'
while the plain MD5 hash can be calculated with the
$ printf 'weakpassword' | md5sum
Note that the output from the latter is in hex, while the
$1$ crypt uses Base64 encoding.