User Tools

Site Tools


wlasne_moduly

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
dodatkowe_funkcje [2018/06/17 12:14] – [Klasy] adminwlasne_moduly [2019/02/08 21:20] admin
Line 11: Line 11:
   uPSC_std   uPSC_std
   uPSC_classes   uPSC_classes
-  uPSR_controls +  uPSC_controls 
-  uPSR_forms+  uPSC_forms
   uPSC_dateutils   uPSC_dateutils
   uPSC_dll   uPSC_dll
Line 19: Line 19:
  
  
-==== Typy ====+==== Typy modułów ====
  
-<code delphi>type TModuleType = mtFile, mtRegistry</code>+<code delphi>type TModuleType = mtFile, mtRegistry, mtOther</code>
  
  
Line 78: Line 78:
  
 ==== Funkcje ==== ==== Funkcje ====
- 
-<code delphi>procedure ShowMessage(aMsg: string);</code> 
-<code delphi>procedure RegistryScan(RootType: DWord; RootKey: string);</code> 
  
 <code delphi>function CryptoHash(const AStr, AHash: string): string; <code delphi>function CryptoHash(const AStr, AHash: string): string;
Line 112: Line 109:
   RS, SDBM, SHIFTANDXOR, SUPERFAST, FNV1A64, FNV64, VXWORKS5   RS, SDBM, SHIFTANDXOR, SUPERFAST, FNV1A64, FNV64, VXWORKS5
   MOTOROLADOCSIS       MOTOROLADOCSIS    
 +  // windows //
 +  LM  
 </code> </code>
  
Line 138: Line 137:
 function IsValidNum(const s: string): boolean;</code> function IsValidNum(const s: string): boolean;</code>
  
-<code delphi>procedure AddItem(App, Item, User, Pass, FileName: string);</code>+<code delphi>procedure RegistryScan(RootType: DWord; RootKey: string); 
 +procedure AddItem(App, Item, User, Pass, FileName: string);</code> 
 + 
 +<code delphi>procedure ShowMessage(aMsg: string); 
 + 
 +function ExtractFilePath(const FileName: string): string; 
 +function ExtractFileDrive(const FileName: string): string; 
 +function ExtractFileName(const FileName: string): string; 
 +function ExtractFileExt(const FileName: string): string; 
 +function ExtractFileDir(Const FileName: string): string; 
 + 
 +function FileExists(const FileName: string): Boolean; 
 +function DirectoryExists(const DirName: string): Boolean; 
 + 
 +function ParamStr(l: LongInt):string; 
 +function ParamCount: LongInt; 
 +</code>
  
 ==== Parametry przekazywane z aplikacji ==== ==== Parametry przekazywane z aplikacji ====
  
-<code delphi>Registry = TRegistryEx</code> +<code delphi>var 
-<code delphi>FileRecord = TFileRecordObj</code>+  Registry = TRegistryEx 
 +  FileRecord = TFileRecordObj</code>
  
 ===== Przykład ===== ===== Przykład =====
Line 173: Line 189:
   ini := CreateIniFile(FileRecord.Full);   ini := CreateIniFile(FileRecord.Full);
   try   try
-    str := ini.ReadString('ultravnc', 'passwd', 'x');+    str := ini.ReadString('ultravnc', 'passwd', '');
     if IsValidHex(str) and (Length(str) > 0) then     if IsValidHex(str) and (Length(str) > 0) then
     begin     begin
Line 192: Line 208:
 ==== Obsługa rejestru ==== ==== Obsługa rejestru ====
  
-<code delphi> +<code delphi>function ModuleType: TModuleType;
-function ModuleType: TModuleType;+
 begin begin
   Result := mtRegistry;   Result := mtRegistry;
Line 206: Line 221:
 begin begin
   RegistryScan(ROOT_KEY, '\SOFTWARE\TigerVNC\WinVNC4');   RegistryScan(ROOT_KEY, '\SOFTWARE\TigerVNC\WinVNC4');
-  // execute OnCheck on each nodes 
   RegistryScan(ROOT_KEY, '\SOFTWARE\RealVNC\WinVNC4');   RegistryScan(ROOT_KEY, '\SOFTWARE\RealVNC\WinVNC4');
   RegistryScan(ROOT_KEY, '\SOFTWARE\ORL\WinVNC3');   RegistryScan(ROOT_KEY, '\SOFTWARE\ORL\WinVNC3');
Line 232: Line 246:
     else     else
       s := ModuleName;       s := ModuleName;
-    AddItem(s, +    AddItem(s, 'Custom Module', '', 
-            'Custom Module',  // protocol +       Trim(CryptoDecrypt(Registry.ReadString(Value), 
-            '',               // username +         #23#82#107#6#35#78#88#7, '', cmECBx, '1DESVNC')),'');
-            Trim(CryptoDecrypt(Registry.ReadString(Value),  // encrypted +
-                        #23#82#107#6#35#78#88#7,     // key +
-                        '',                          // iv +
-                        cmECBx,                      // mode +
-                        '1DESVNC')),                 // algorithm look@selftest +
-            '');               // filename+
   end;   end;
 end; end;
wlasne_moduly.txt · Last modified: 2019/03/26 02:22 by admin

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki