skyhighatrist wrote:This is not exactly a f-- APT or anything, its effectively copypasta. It probably *is* some poor sods college assignment for a network security class or something that went a bit awry.
Thank you for your post.
I think you should see
the post/blog report well, instead using some Fxxx words in our respectful forum here.
But okay, below is the explanation of the case & post I made:
1. I posted analysis based on the reversing analysis on the binary found, linked it to the stuff in CNC. I reversed it just as that which its result explained in the blog post report. Our team mates found the github site
after the analysis was posted during further search. So I don't analyze how the source code to details afterward, in fact I did not see some of this threat Git files until now.
2. During the reversing we "smelled" MAYBE it was a kind of university project, but we couldn't confirm it that time, it is beyond our thought to imagine a university is opening such
viral research against public internet too. Below is the proof of our internal communication:
After further checks and communication was made, It was confirmed as a "school project", see the additional information in the posted blog, ..after
some take down request & etc communications,
we received the confession/apology from the coder himself.
No one EVER says about "
fxxxing APT" here, just
you in
your disrespectful ways.
3. I (and also researcher friend who spotted the binary in 1st place) agreed
to not want to disclose how source/this kernel module works, nor to discuss that details in public for the security purpose, not that unaware of how it works in details, yet, I posted way to
dispatch back the cr0 value in the
sys_call_table that was
actually being "hijacked" here, in the reddit post I made as per asked not to unhide the process back. as per the coded by the malcoder too, that was actually work (tested) in x32 kernel.
IF you can read that injected assembly code well, it said: The kernel_memory_allocate() was refreshed by setting back to space
0x80000000-0xFFFEFFFF (READ: refreshed), to then followed by returning the cr0 value to its original states, that uses eax as register to hold the value of cr0, "eax" is showing the x32 bit operation eventhough the "hijacking" kernel module code is designed to handle x64 too.
The "copy-pasta" below is a saying much of the original codes that was supported both arch. Even though the "current spotted" implementation of the actor is on x32 only, AND there is actually a x64 binary that is supposed to be downloaded but not be spotted yet too.
[quote ="tWiCe"] Did you manage to obtain a x64 sample mentioned on one of the screenshots from the article? [/quote]
This is where the sys_call_table_addr was hijacked, noted the usage of x32 _& x64 in there.
Code: Select all if (sys_call_table_addr == NULL) return -1;
old_getdents64 = sys_call_table_addr[__NR_getdents64];
sys_call_table_addr[__NR_getdents64] = new_getdents64;
old_getdents = sys_call_table_addr[__NR_getdents];
and here's where it returned to the original state. noted the usage of x32 _& x64 in there.
Code: Select all sys_call_table_addr[__NR_getdents64] = old_getdents64;
sys_call_table_addr[__NR_getdents] = old_getdents;
setback_cr0(orig_cr0);
4. Additionally, if I want to take this kernel internals matter FURTHER, there are actually some flaw in the kernel module malcode for the actual implementation, more than just x32 or x64 intel assembly matters that was coded there (we assumed the coder is developing all of these under his x32), as its relation to the incompatibility of the linux kernel versionS (noted the "s" as plural) in sys_call_table part which
may not run in some major systems (which is good for all of us), but I don't want to discuss about that either to "inspire" the dark side.
5. We decided to post the case for the linux hardening awareness (kernel module used malware) purpose & as evidence to stop the usage internet as the malware protect test bed.
Some correction of your post:
skyhighatrist wrote:
due to the inline assembler using only x64 registers.
You mean the "only x32 register"? ;) This is a big difference isn't it? Since when x64 register is "eax"?
Thank's and rgds - #MalwareMustDie