Subversion Repositories autosfx

Rev

Rev 1 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
1 daniel-mar 1
VIATHINKSOFT AUTOSFX
2
====================
3
 
4
Benefits
5
--------
6
 
7
* Compatible with WinRAR and other software (Stub is small enough)
8
* Compatible with Linux' UnZip (No Warnings!)
9
* Compatible with AuthentiCode
10
* Compatible with Windows 7
11
* Compatible with Windows 95
12
 
13
Current overhead
14
----------------
15
 
16
458 KB (Delphi 2006)
17
 
4 daniel-mar 18
Cancel
19
------
20
 
21
Press ESC to cancel.
22
 
23
The program waits 1 second before starting extraction (Prevention of malicious
24
AutoRun's, which call the creator SFX in an infinite loop)
25
 
1 daniel-mar 26
Structure of a ViaThinkSoft AutoSFX Archive
27
-------------------------------------------
28
 
29
1. Extractor [UPX'ed]
30
   includes DelZip190.dll (B4) as Resource
31
2. ZIP (Offset adjusted)
32
   File comment includes "ViaThinkSoft AutoSFX Archive"
33
3. Optional: Authenticode Certificate
34
 
35
Process
36
-------
37
 
38
1. Extract DelZip DLL into TempDir
39
2. Extract contents directly
40
3. Open the extracted data and/or execute special AutoRun.inf (see below)
41
4. Delete the DLL from TempDir
42
 
43
Behavior
44
--------
45
 
46
ZIP has 1 file
47
	=> Extract in the same directory as the SFX
48
	Is it a directory?
49
		=> Open the new directory in Windows Explorer
50
	is it a file?
51
		=> Open Windows Explorer and select the new file.
52
ZIP has 2+ files
53
	=> Create a directory with the name of the SFX and extract into it
54
	=> Open the new created directory in Windows Explorer
55
 
56
Semantic archive comment
57
------------------------
58
 
59
The extractor looks into the file comment to determinate the behavior
60
while unzipping. YOU can influence the behavior when creating your
61
ZIP files.
62
 
63
Following switches are possible:
64
 
65
  C_ASFX_CB_OVR = 'AutoSFX Conflict Behavior: Overwrite all';
66
  C_ASFX_CB_NEW = 'AutoSFX Conflict Behavior: Overwrite older';
67
  C_ASFX_CB_ASK = 'AutoSFX Conflict Behavior: Ask';
68
  C_ASFX_CB_AVO = 'AutoSFX Conflict Behavior: Avoid';
69
 
70
  C_ASFX_CP_BEF = 'AutoSFX Comment Presentation: Before extracting';
71
  C_ASFX_CP_AFT = 'AutoSFX Comment Presentation: After extracting';
72
  C_ASFX_CP_NON = 'AutoSFX Comment Presentation: None';
73
 
74
  C_ASFX_FC_THS = 'AutoSFX Extraction Target: Extract here';
75
  C_ASFX_FC_DSK = 'AutoSFX Extraction Target: Extract to Desktop';
76
  C_ASFX_FC_ASK = 'AutoSFX Extraction Target: Choose directory';
77
 
78
Special AutoRun.inf
79
-------------------
80
 
81
[AutoSFX]
82
Operation=open			; Part of ShellExecute. Usually 'open' or 'runass' (e.g. for admin privilegies)
83
FileName=AutoRun.exe		; The filename to be executed
84
Parameters=			; Optional parameters
85
Directory=			; Optional Working directory
86
ShowCmd=			; (See MSDN Reference) Usually WS_NORMAL or WS_HIDE
87
OpenUnzippedContent=true	; After we have opened the application, should we still show the extracted data in Windows Explorer? (Default behavior if not AutoRun is set)
88
 
89
More information about the first 5 values:
90
http://msdn.microsoft.com/en-us/library/bb762153(VS.85).aspx
91
 
92
 
93
(C) 2010 ViaThinkSoft