会员: 密码:  免费注册 | 忘记密码 | 会员登录 网页功能: 加入收藏 设为首页 网站搜索  
技术文档 > Delphi
从注册表里得到屏保密码
发表日期:2003-04-07 00:00:00作者: 出处:  

size        : 1803

uploaded_on     : Fri Aug 13 00:00:00 1999

modified_on     : Wed Dec 8 14:02:52 1999

title        : Screensaver password

org_filename    : ScreenSaverPassword.txt

author       : Kristian

authoremail     : kk@thcnet.de

description     : How to get the screensaver's password from the registry

keywords      :

tested       : not tested yet

submitted_by    : The CKB Crew

submitted_by_email : ckb@netalive.org

uploaded_by     : nobody

modified_by     : nobody

owner        : nobody

lang        : plain

file-type      : text/plain

category      : delphi-registry

__END_OF_HEADER__

unit decoder;

interface

uses

 Windows, SysUtils, Forms, Registry, StdCtrls, Controls,

Classes;

type

 TForm1 = class(TForm)

  Edit1: TEdit;

  GroupBox1: TGroupBox;

  GroupBox2: TGroupBox;

  Label2: TLabel;

  Label3: TLabel;

  Label4: TLabel;

  procedure FormCreate(Sender: TObject);

 end;

var

 Form1: TForm1;

 reg: TRegistry;

const

 xorwert: array[1..128] of byte =

(72,238,118,29,103,105,161,

27,122,140,71,248,84,149,151,95,120,217,218,108,89,215,107,

 53,197,119,133,24,42,14,82,255,0,227,27,113,141,52,99,235,

145,195,36,15,183,194,248,227,182,84,76,53,84,231,201,73,40,

163,133,17,11,44,104,251,238,125,246,108,227,156,45,228,114,

195,187,133,26,18,60,50,227,107,79,77,244,169,36,200,250,120

,

173,35,161,228,109,154,4,206,43,197,182,197,239,147,92,168,

133,43,65,55,114,250,87,69,65,161,32,79,128,179,213,35,2,100

,

 63,108,241,15);

implementation

{$R *.DFM}

procedure TForm1.FormCreate(Sender: TObject);

var

 buf: Array[0..256] of char;

 laenge: word;

 a: byte;

 asdec: byte;

 passwort : String[128];

begin

 passwort := '';

 asdec := 0;

 reg := TRegistry.Create;

 reg.RootKey := HKEY_CURRENT_USER;

 Reg.OpenKey('\Control Panel\Desktop',FALSE);

 Reg.ReadBinaryData('ScreenSave_Data', buf, sizeof(buf));

 //... shr 1

 //Verschieben der Bits um eine Stelle nach Rechts -->

Division durch 2

 laenge := (Reg.GetDataSize('ScreenSave_Data') - 1) shr 1;

 if Reg.ReadBool('ScreenSaveUsePassword') then

 For a := 1 to laenge do

  begin

   asdec := strtoint('$' + buf[(a shl 1)-2] + buf[(a shl

1)-1]);

   passwort := concat(passwort, Chr(asdec xor xorwert

[a]));

   edit1.color := $FFFFFF;

   end else passwort := '+++ passwort deaktiviert +++';

 reg.free;

 edit1.Text := passwort;

 Edit1.SelectAll;

 Edit1.CopyToClipboard;

end;

end.

返回顶部】 【打印本页】 【关闭窗口

关于我们 / 给我留言 / 版权举报 / 意见建议 / 网站编程QQ群   
Copyright ©2003- 2024 Lihuasoft.net webmaster(at)lihuasoft.net 加载时间 0.00356