Malops Silent Authenticator write-up

We get an ELF that's suppose to be some kind of PAM module backdoor. Looking for the hash, we can find it on a couple of platforms: https://www.virustotal.com/gui/file/7b7cd8d216b1f4cf86cc596bda5727a1d67a591d93363e8381885016430bf900/communityarrow-up-right

https://hybrid-analysis.com/sample/7b7cd8d216b1f4cf86cc596bda5727a1d67a591d93363e8381885016430bf900arrow-up-right

https://maltiverse.com/sample/7b7cd8d216b1f4cf86cc596bda5727a1d67a591d93363e8381885016430bf900arrow-up-right

One thing worth noting is that VT gives us a yara hit and the author is malgamy who authored this challenge:

Another interesting point is the name of the file on these platforms: pam_unix.so ; that hints that in a "normal" environment, this is a Pluggable Authentication Module loaded as a shared object.

Looking for previous litterature on pam backdoors, I also found https://www.nextron-systems.com/2025/08/01/plague-a-newly-discovered-pam-based-backdoor-for-linux/arrow-up-right

In IDA, the entry point doesn't get us very far:

However, if we xref this, we can see some interesting subroutines called right after:

That second sub_X has a call rax that we need to resolve somehow.

There's also a couple of exports that we can look at. This .so would replace the legitimate pam so and therefore, malicious code is likely in one of these exports.

If we look at the pam_authenticate export, we see a couple of calls to sub_32A0:

That subroutine has a xor dl, [rdi] instruction. If we trace back what ends up in dl, we see it's the xor key 0x54 ; I modified the ida script from nextron systems to emulate sub_32A0 to perform the xor and comment the string (honestly the below is probably overkill just for the purpose of xor emulation)

In that same routine, we see the shl value is 4 and the offset with the encrypted data is at +8 (we see a mov r8, [rdi+8] ). We also see a rdi+2 indicating length.

If we xref sub_32A0 we see 7 references. That's basically it! I won't go any further as I don't want to give out too many spoilers. Once you xor'd the stack strings, the rest is pretty straightforward and just involves reading assembly. Best of luck!

Last updated