<s>
Direct	B-Device
kernel	I-Device
object	I-Device
manipulation	I-Device
(	O
DKOM	B-Device
)	O
is	O
a	O
common	O
rootkit	O
technique	O
for	O
Microsoft	B-Application
Windows	I-Application
to	O
hide	O
potentially	O
damaging	O
third-party	O
processes	B-Operating_System
,	O
drivers	B-Application
,	O
files	O
,	O
and	O
intermediate	O
connections	O
from	O
the	O
task	B-General_Concept
manager	I-General_Concept
and	O
event	O
scheduler	O
.	O
</s>
<s>
At	O
its	O
very	O
core	O
,	O
a	O
rootkit	O
that	O
employs	O
DKOM	B-Device
hides	O
itself	O
from	O
the	O
Object	O
Manager	O
or	O
Task	B-General_Concept
manager	I-General_Concept
.	O
</s>
<s>
By	O
modifying	O
the	O
linked	B-Data_Structure
list	I-Data_Structure
containing	O
a	O
list	O
of	O
all	O
active	O
threads	B-Operating_System
and	O
processes	B-Operating_System
,	O
this	O
type	O
of	O
rootkit	O
can	O
essentially	O
hide	O
all	O
traces	O
from	O
the	O
Object	O
Manager	O
by	O
wrapping	O
the	O
pointer	O
away	O
from	O
the	O
rootkit	O
itself	O
.	O
</s>
<s>
This	O
is	O
possible	O
due	O
to	O
the	O
fact	O
that	O
kernel	B-Operating_System
modules	O
and	O
loadable	O
drivers	B-Application
have	O
direct	O
access	O
to	O
the	O
kernel	B-Operating_System
memory	O
from	O
its	O
privileged	O
access	O
.	O
</s>
<s>
When	O
the	O
system	O
kernel	B-Operating_System
pings	O
to	O
find	O
the	O
list	O
of	O
all	O
processes	B-Operating_System
running	O
in	O
the	O
system	O
,	O
it	O
relies	O
on	O
the	O
EPROCESS	O
to	O
find	O
them	O
.	O
</s>
<s>
However	O
,	O
because	O
a	O
Windows	O
Kernel	B-Operating_System
is	O
thread	B-Operating_System
based	O
and	O
not	O
process	O
based	O
,	O
pointers	O
can	O
be	O
freely	O
modified	O
without	O
any	O
unintended	O
effects	O
.	O
</s>
<s>
By	O
modifying	O
linked	B-Data_Structure
list	I-Data_Structure
pointers	O
to	O
wrap	O
around	O
the	O
rootkit	O
process	O
itself	O
,	O
the	O
rootkit	O
becomes	O
invisible	O
to	O
the	O
Windows	O
event	O
viewer	O
and	O
any	O
system	O
integrity	O
applications	O
that	O
rely	O
on	O
this	O
list	O
.	O
</s>
<s>
This	O
allows	O
DKOM	B-Device
rootkits	O
to	O
have	O
free	O
rein	O
over	O
the	O
targeted	O
system	O
.	O
</s>
<s>
Within	O
each	O
process	O
,	O
there	O
is	O
a	O
pre-allocated	O
set	O
of	O
space	O
that	O
contains	O
the	O
address	O
of	O
the	O
current	O
,	O
next	O
,	O
and	O
mutex_locked	O
thread	B-Operating_System
.	O
</s>
<s>
This	O
vital	O
information	O
is	O
listed	O
in	O
the	O
EPROCESS	O
in	O
memory	O
;	O
the	O
section	O
in	O
the	O
object	O
manager	O
contains	O
a	O
double	O
linked	B-Data_Structure
list	I-Data_Structure
of	O
all	O
known	O
processes	B-Operating_System
running	O
,	O
which	O
is	O
also	O
known	O
as	O
the	O
EPROCESS	O
.	O
</s>
<s>
However	O
,	O
DKOM	B-Device
's	O
take	O
advantage	O
of	O
this	O
structure	O
by	O
modifying	O
the	O
front	O
link	O
(	O
FLINK	O
)	O
to	O
point	O
to	O
the	O
previous	O
node	O
of	O
the	O
processor	O
that	O
we	O
want	O
to	O
hide	O
,	O
and	O
pointing	O
the	O
back	O
link	O
(	O
BLINK	O
)	O
of	O
the	O
hidden	O
processor	O
to	O
the	O
previous	O
structure	O
.	O
</s>
<s>
By	O
modifying	O
a	O
subsection	O
of	O
the	O
EPROCESS	O
block	O
,	O
the	O
list	O
of	O
currently	O
active	O
processes	B-Operating_System
points	O
around	O
the	O
hidden	O
process	O
.	O
</s>
<s>
This	O
essentially	O
hides	O
any	O
paper	O
trail	O
of	O
a	O
given	O
process	O
or	O
injector	O
from	O
the	O
scrutiny	O
of	O
the	O
scheduler	O
because	O
the	O
process	O
is	O
hidden	O
;	O
yet	O
it	O
runs	O
indefinitely	O
because	O
the	O
thread	B-Operating_System
it	O
is	O
in	O
is	O
active	O
due	O
to	O
the	O
round-robin	B-Algorithm
policy	O
.	O
</s>
<s>
The	O
main	O
issue	O
with	O
this	O
type	O
of	O
rootkit	O
is	O
that	O
hidden	O
processes	B-Operating_System
are	O
still	O
able	O
to	O
run	O
despite	O
various	O
context	O
switches	O
.	O
</s>
<s>
In	O
a	O
Windows	O
scheduler	O
,	O
threads	B-Operating_System
are	O
segregated	O
to	O
perform	O
tasks	O
,	O
not	O
processes	B-Operating_System
.	O
</s>
<s>
Rather	O
,	O
a	O
thread	B-Operating_System
calls	O
multiple	O
processes	B-Operating_System
during	O
a	O
given	O
time	O
frame	O
.	O
</s>
<s>
This	O
process	O
is	O
controlled	O
by	O
the	O
round-robin	B-Algorithm
nature	O
of	O
the	O
scheduler	O
and	O
threads	B-Operating_System
are	O
put	O
on	O
idle	O
to	O
allow	O
other	O
threads	B-Operating_System
to	O
be	O
active	O
.	O
</s>
<s>
Even	O
though	O
a	O
process	O
becomes	O
invisible	O
to	O
the	O
task	B-General_Concept
manager	I-General_Concept
,	O
the	O
process	O
still	O
runs	O
concurrently	O
with	O
the	O
system	O
because	O
the	O
threads	B-Operating_System
are	O
active	O
.	O
</s>
<s>
This	O
makes	O
detecting	O
hidden	O
processes	B-Operating_System
created	O
by	O
the	O
rootkit	O
extremely	O
difficult	O
.	O
</s>
<s>
By	O
checking	O
the	O
CPU	O
usage	O
,	O
ongoing	O
and	O
outgoing	O
network	B-Protocol
traffic	I-Protocol
,	O
or	O
the	O
signatures	O
of	O
drivers	B-Application
,	O
simple	O
anti-virus	O
tools	O
can	O
detect	O
common	O
rootkits	O
.	O
</s>
<s>
However	O
,	O
this	O
is	O
not	O
the	O
case	O
with	O
a	O
kernel	B-Operating_System
type	O
rootkit	O
.	O
</s>
<s>
However	O
,	O
even	O
though	O
the	O
presence	O
of	O
any	O
malicious	O
processes	B-Operating_System
is	O
not	O
physically	O
present	O
in	O
the	O
handler	O
,	O
calls	O
are	O
made	O
to	O
it	O
in	O
the	O
background	O
.	O
</s>
<s>
These	O
processes	B-Operating_System
point	O
to	O
threads	B-Operating_System
,	O
network	O
connections	O
points	O
to	O
processes	B-Operating_System
,	O
and	O
drivers	B-Application
point	O
to	O
threads	B-Operating_System
.	O
</s>
<s>
For	O
a	O
DKOM	B-Device
rootkit	O
to	O
be	O
viable	O
,	O
it	O
has	O
to	O
hide	O
its	O
presence	O
from	O
every	O
single	O
reference	O
in	O
the	O
EPROCESS	O
.	O
</s>
<s>
By	O
iterating	O
through	O
each	O
and	O
every	O
entity	O
in	O
the	O
scheduler	O
(	O
threads	B-Operating_System
,	O
object	O
headers	O
etc	O
)	O
,	O
detecting	O
a	O
DKOM	B-Device
rootkit	O
is	O
possible	O
.	O
</s>
