librex 0.0.42 → 0.0.43

Sign up to get free protection for your applications and to get access to all the features.
Files changed (34) hide show
  1. data/README.markdown +1 -1
  2. data/lib/rex/compat.rb +10 -0
  3. data/lib/rex/post/meterpreter/channels/pools/file.rb +1 -1
  4. data/lib/rex/post/meterpreter/extensions/stdapi/fs/dir.rb +20 -18
  5. data/lib/rex/post/meterpreter/extensions/stdapi/fs/file.rb +11 -22
  6. data/lib/rex/post/meterpreter/extensions/stdapi/fs/file_stat.rb +2 -1
  7. data/lib/rex/post/meterpreter/extensions/stdapi/railgun.rb.ts.rb +4 -0
  8. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/api_constants.rb +27 -0
  9. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/api_constants.rb.ut.rb +7 -0
  10. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/def/def_advapi32.rb +498 -242
  11. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/def/def_iphlpapi.rb +18 -18
  12. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/def/def_kernel32.rb +695 -694
  13. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/def/def_netapi32.rb +6 -5
  14. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/def/def_ntdll.rb +24 -24
  15. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/def/def_shell32.rb +5 -4
  16. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/def/def_user32.rb +551 -551
  17. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/def/def_ws2_32.rb +93 -93
  18. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/dll.rb +56 -42
  19. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/dll.rb.ut.rb +4 -4
  20. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/dll_helper.rb.ut.rb +5 -5
  21. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/dll_wrapper.rb +26 -0
  22. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/dll_wrapper.rb.ut.rb +63 -0
  23. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/multicall.rb +4 -4
  24. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/railgun.rb +151 -96
  25. data/lib/rex/post/meterpreter/extensions/stdapi/railgun/railgun.rb.ut.rb +80 -5
  26. data/lib/rex/post/meterpreter/extensions/stdapi/sys/config.rb +3 -3
  27. data/lib/rex/post/meterpreter/extensions/stdapi/sys/process.rb +11 -11
  28. data/lib/rex/post/meterpreter/extensions/stdapi/sys/registry.rb +3 -3
  29. data/lib/rex/post/meterpreter/packet.rb +12 -11
  30. data/lib/rex/proto/dhcp/server.rb +36 -42
  31. data/lib/rex/socket/range_walker.rb +1 -1
  32. data/lib/rex/text.rb +18 -1
  33. data/lib/rex/ui/text/table.rb +1 -1
  34. metadata +5 -3
@@ -8,85 +8,85 @@ module Def
8
8
 
9
9
  class Def_iphlpapi
10
10
 
11
- def self.add_imports(railgun)
12
-
13
- railgun.add_dll('iphlpapi')
11
+ def self.create_dll(dll_path = 'iphlpapi')
12
+ dll = DLL.new(dll_path, ApiConstants.manager)
14
13
 
15
- railgun.add_function( 'iphlpapi', 'CancelIPChangeNotify', 'BOOL',[
14
+ dll.add_function('CancelIPChangeNotify', 'BOOL',[
16
15
  ["PBLOB","notifyOverlapped","in"],
17
16
  ])
18
17
 
19
- railgun.add_function( 'iphlpapi', 'CreateProxyArpEntry', 'DWORD',[
18
+ dll.add_function('CreateProxyArpEntry', 'DWORD',[
20
19
  ["DWORD","dwAddress","in"],
21
20
  ["DWORD","dwMask","in"],
22
21
  ["DWORD","dwIfIndex","in"],
23
22
  ])
24
23
 
25
- railgun.add_function( 'iphlpapi', 'DeleteIPAddress', 'DWORD',[
24
+ dll.add_function('DeleteIPAddress', 'DWORD',[
26
25
  ["DWORD","NTEContext","in"],
27
26
  ])
28
27
 
29
- railgun.add_function( 'iphlpapi', 'DeleteProxyArpEntry', 'DWORD',[
28
+ dll.add_function('DeleteProxyArpEntry', 'DWORD',[
30
29
  ["DWORD","dwAddress","in"],
31
30
  ["DWORD","dwMask","in"],
32
31
  ["DWORD","dwIfIndex","in"],
33
32
  ])
34
33
 
35
- railgun.add_function( 'iphlpapi', 'FlushIpNetTable', 'DWORD',[
34
+ dll.add_function('FlushIpNetTable', 'DWORD',[
36
35
  ["DWORD","dwIfIndex","in"],
37
36
  ])
38
37
 
39
- railgun.add_function( 'iphlpapi', 'GetAdapterIndex', 'DWORD',[
38
+ dll.add_function('GetAdapterIndex', 'DWORD',[
40
39
  ["PWCHAR","AdapterName","in"],
41
40
  ["PDWORD","IfIndex","inout"],
42
41
  ])
43
42
 
44
- railgun.add_function( 'iphlpapi', 'GetBestInterface', 'DWORD',[
43
+ dll.add_function('GetBestInterface', 'DWORD',[
45
44
  ["DWORD","dwDestAddr","in"],
46
45
  ["PDWORD","pdwBestIfIndex","inout"],
47
46
  ])
48
47
 
49
- railgun.add_function( 'iphlpapi', 'GetBestInterfaceEx', 'DWORD',[
48
+ dll.add_function('GetBestInterfaceEx', 'DWORD',[
50
49
  ["PBLOB","pDestAddr","in"],
51
50
  ["PDWORD","pdwBestIfIndex","inout"],
52
51
  ])
53
52
 
54
- railgun.add_function( 'iphlpapi', 'GetFriendlyIfIndex', 'DWORD',[
53
+ dll.add_function('GetFriendlyIfIndex', 'DWORD',[
55
54
  ["DWORD","IfIndex","in"],
56
55
  ])
57
56
 
58
- railgun.add_function( 'iphlpapi', 'GetNumberOfInterfaces', 'DWORD',[
57
+ dll.add_function('GetNumberOfInterfaces', 'DWORD',[
59
58
  ["PDWORD","pdwNumIf","inout"],
60
59
  ])
61
60
 
62
- railgun.add_function( 'iphlpapi', 'GetRTTAndHopCount', 'BOOL',[
61
+ dll.add_function('GetRTTAndHopCount', 'BOOL',[
63
62
  ["DWORD","DestIpAddress","in"],
64
63
  ["PDWORD","HopCount","inout"],
65
64
  ["DWORD","MaxHops","in"],
66
65
  ["PDWORD","RTT","inout"],
67
66
  ])
68
67
 
69
- railgun.add_function( 'iphlpapi', 'NotifyAddrChange', 'DWORD',[
68
+ dll.add_function('NotifyAddrChange', 'DWORD',[
70
69
  ["PDWORD","Handle","inout"],
71
70
  ["PBLOB","overlapped","in"],
72
71
  ])
73
72
 
74
- railgun.add_function( 'iphlpapi', 'NotifyRouteChange', 'DWORD',[
73
+ dll.add_function('NotifyRouteChange', 'DWORD',[
75
74
  ["PDWORD","Handle","inout"],
76
75
  ["PBLOB","overlapped","in"],
77
76
  ])
78
77
 
79
- railgun.add_function( 'iphlpapi', 'SendARP', 'DWORD',[
78
+ dll.add_function('SendARP', 'DWORD',[
80
79
  ["DWORD","DestIP","in"],
81
80
  ["DWORD","SrcIP","in"],
82
81
  ["PBLOB","pMacAddr","out"],
83
82
  ["PDWORD","PhyAddrLen","inout"],
84
83
  ])
85
84
 
86
- railgun.add_function( 'iphlpapi', 'SetIpTTL', 'DWORD',[
85
+ dll.add_function('SetIpTTL', 'DWORD',[
87
86
  ["DWORD","nTTL","in"],
88
87
  ])
89
88
 
89
+ return dll
90
90
  end
91
91
 
92
92
  end
@@ -7,52 +7,52 @@ module Railgun
7
7
  module Def
8
8
 
9
9
  class Def_kernel32
10
- def self.add_imports(railgun)
11
-
12
- railgun.add_dll('kernel32')
10
+
11
+ def self.create_dll(dll_path = 'kernel32')
12
+ dll = DLL.new(dll_path, ApiConstants.manager)
13
13
 
14
- railgun.add_function('kernel32', 'ActivateActCtx', 'BOOL',[
14
+ dll.add_function( 'ActivateActCtx', 'BOOL',[
15
15
  ["HANDLE","hActCtx","inout"],
16
16
  ["PBLOB","lpCookie","out"],
17
17
  ])
18
18
 
19
- railgun.add_function('kernel32', 'AddAtomA', 'WORD',[
19
+ dll.add_function( 'AddAtomA', 'WORD',[
20
20
  ["PCHAR","lpString","in"],
21
21
  ])
22
22
 
23
- railgun.add_function('kernel32', 'AddAtomW', 'WORD',[
23
+ dll.add_function( 'AddAtomW', 'WORD',[
24
24
  ["PWCHAR","lpString","in"],
25
25
  ])
26
26
 
27
- railgun.add_function('kernel32', 'AddRefActCtx', 'VOID',[
27
+ dll.add_function( 'AddRefActCtx', 'VOID',[
28
28
  ["HANDLE","hActCtx","inout"],
29
29
  ])
30
30
 
31
- railgun.add_function('kernel32', 'AddVectoredContinueHandler', 'LPVOID',[
31
+ dll.add_function( 'AddVectoredContinueHandler', 'LPVOID',[
32
32
  ["DWORD","First","in"],
33
33
  ["PBLOB","Handler","in"],
34
34
  ])
35
35
 
36
- railgun.add_function('kernel32', 'AddVectoredExceptionHandler', 'LPVOID',[
36
+ dll.add_function( 'AddVectoredExceptionHandler', 'LPVOID',[
37
37
  ["DWORD","First","in"],
38
38
  ["PBLOB","Handler","in"],
39
39
  ])
40
40
 
41
- railgun.add_function('kernel32', 'AllocateUserPhysicalPages', 'BOOL',[
41
+ dll.add_function( 'AllocateUserPhysicalPages', 'BOOL',[
42
42
  ["HANDLE","hProcess","in"],
43
43
  ["PBLOB","NumberOfPages","inout"],
44
44
  ["PBLOB","PageArray","out"],
45
45
  ])
46
46
 
47
- railgun.add_function('kernel32', 'AreFileApisANSI', 'BOOL',[
47
+ dll.add_function( 'AreFileApisANSI', 'BOOL',[
48
48
  ])
49
49
 
50
- railgun.add_function('kernel32', 'AssignProcessToJobObject', 'BOOL',[
50
+ dll.add_function( 'AssignProcessToJobObject', 'BOOL',[
51
51
  ["HANDLE","hJob","in"],
52
52
  ["HANDLE","hProcess","in"],
53
53
  ])
54
54
 
55
- railgun.add_function('kernel32', 'BackupRead', 'BOOL',[
55
+ dll.add_function( 'BackupRead', 'BOOL',[
56
56
  ["HANDLE","hFile","in"],
57
57
  ["PBLOB","lpBuffer","out"],
58
58
  ["DWORD","nNumberOfBytesToRead","in"],
@@ -62,7 +62,7 @@ class Def_kernel32
62
62
  ["PBLOB","lpContext","inout"],
63
63
  ])
64
64
 
65
- railgun.add_function('kernel32', 'BackupSeek', 'BOOL',[
65
+ dll.add_function( 'BackupSeek', 'BOOL',[
66
66
  ["HANDLE","hFile","in"],
67
67
  ["DWORD","dwLowBytesToSeek","in"],
68
68
  ["DWORD","dwHighBytesToSeek","in"],
@@ -71,7 +71,7 @@ class Def_kernel32
71
71
  ["PBLOB","lpContext","inout"],
72
72
  ])
73
73
 
74
- railgun.add_function('kernel32', 'BackupWrite', 'BOOL',[
74
+ dll.add_function( 'BackupWrite', 'BOOL',[
75
75
  ["HANDLE","hFile","in"],
76
76
  ["PBLOB","lpBuffer","in"],
77
77
  ["DWORD","nNumberOfBytesToWrite","in"],
@@ -81,50 +81,50 @@ class Def_kernel32
81
81
  ["PBLOB","lpContext","inout"],
82
82
  ])
83
83
 
84
- railgun.add_function('kernel32', 'Beep', 'BOOL',[
84
+ dll.add_function( 'Beep', 'BOOL',[
85
85
  ["DWORD","dwFreq","in"],
86
86
  ["DWORD","dwDuration","in"],
87
87
  ])
88
88
 
89
- railgun.add_function('kernel32', 'BeginUpdateResourceA', 'DWORD',[
89
+ dll.add_function( 'BeginUpdateResourceA', 'DWORD',[
90
90
  ["PCHAR","pFileName","in"],
91
91
  ["BOOL","bDeleteExistingResources","in"],
92
92
  ])
93
93
 
94
- railgun.add_function('kernel32', 'BeginUpdateResourceW', 'DWORD',[
94
+ dll.add_function( 'BeginUpdateResourceW', 'DWORD',[
95
95
  ["PWCHAR","pFileName","in"],
96
96
  ["BOOL","bDeleteExistingResources","in"],
97
97
  ])
98
98
 
99
- railgun.add_function('kernel32', 'BindIoCompletionCallback', 'BOOL',[
99
+ dll.add_function( 'BindIoCompletionCallback', 'BOOL',[
100
100
  ["DWORD","FileHandle","in"],
101
101
  ["PBLOB","Function","in"],
102
102
  ["DWORD","Flags","in"],
103
103
  ])
104
104
 
105
- railgun.add_function('kernel32', 'BuildCommDCBA', 'BOOL',[
105
+ dll.add_function( 'BuildCommDCBA', 'BOOL',[
106
106
  ["PCHAR","lpDef","in"],
107
107
  ["PBLOB","lpDCB","out"],
108
108
  ])
109
109
 
110
- railgun.add_function('kernel32', 'BuildCommDCBAndTimeoutsA', 'BOOL',[
110
+ dll.add_function( 'BuildCommDCBAndTimeoutsA', 'BOOL',[
111
111
  ["PCHAR","lpDef","in"],
112
112
  ["PBLOB","lpDCB","out"],
113
113
  ["PBLOB","lpCommTimeouts","out"],
114
114
  ])
115
115
 
116
- railgun.add_function('kernel32', 'BuildCommDCBAndTimeoutsW', 'BOOL',[
116
+ dll.add_function( 'BuildCommDCBAndTimeoutsW', 'BOOL',[
117
117
  ["PWCHAR","lpDef","in"],
118
118
  ["PBLOB","lpDCB","out"],
119
119
  ["PBLOB","lpCommTimeouts","out"],
120
120
  ])
121
121
 
122
- railgun.add_function('kernel32', 'BuildCommDCBW', 'BOOL',[
122
+ dll.add_function( 'BuildCommDCBW', 'BOOL',[
123
123
  ["PWCHAR","lpDef","in"],
124
124
  ["PBLOB","lpDCB","out"],
125
125
  ])
126
126
 
127
- railgun.add_function('kernel32', 'CallNamedPipeA', 'BOOL',[
127
+ dll.add_function( 'CallNamedPipeA', 'BOOL',[
128
128
  ["PCHAR","lpNamedPipeName","in"],
129
129
  ["PBLOB","lpInBuffer","in"],
130
130
  ["DWORD","nInBufferSize","in"],
@@ -134,7 +134,7 @@ class Def_kernel32
134
134
  ["DWORD","nTimeOut","in"],
135
135
  ])
136
136
 
137
- railgun.add_function('kernel32', 'CallNamedPipeW', 'BOOL',[
137
+ dll.add_function( 'CallNamedPipeW', 'BOOL',[
138
138
  ["PWCHAR","lpNamedPipeName","in"],
139
139
  ["PBLOB","lpInBuffer","in"],
140
140
  ["DWORD","nInBufferSize","in"],
@@ -144,31 +144,31 @@ class Def_kernel32
144
144
  ["DWORD","nTimeOut","in"],
145
145
  ])
146
146
 
147
- railgun.add_function('kernel32', 'CancelDeviceWakeupRequest', 'BOOL',[
147
+ dll.add_function( 'CancelDeviceWakeupRequest', 'BOOL',[
148
148
  ["HANDLE","hDevice","in"],
149
149
  ])
150
150
 
151
- railgun.add_function('kernel32', 'CancelIo', 'BOOL',[
151
+ dll.add_function( 'CancelIo', 'BOOL',[
152
152
  ["HANDLE","hFile","in"],
153
153
  ])
154
154
 
155
- railgun.add_function('kernel32', 'CancelTimerQueueTimer', 'BOOL',[
155
+ dll.add_function( 'CancelTimerQueueTimer', 'BOOL',[
156
156
  ["DWORD","TimerQueue","in"],
157
157
  ["DWORD","Timer","in"],
158
158
  ])
159
159
 
160
- railgun.add_function('kernel32', 'CancelWaitableTimer', 'BOOL',[
160
+ dll.add_function( 'CancelWaitableTimer', 'BOOL',[
161
161
  ["HANDLE","hTimer","in"],
162
162
  ])
163
163
 
164
- railgun.add_function('kernel32', 'ChangeTimerQueueTimer', 'BOOL',[
164
+ dll.add_function( 'ChangeTimerQueueTimer', 'BOOL',[
165
165
  ["DWORD","TimerQueue","in"],
166
166
  ["DWORD","Timer","inout"],
167
167
  ["DWORD","DueTime","in"],
168
168
  ["DWORD","Period","in"],
169
169
  ])
170
170
 
171
- railgun.add_function('kernel32', 'CheckNameLegalDOS8Dot3A', 'BOOL',[
171
+ dll.add_function( 'CheckNameLegalDOS8Dot3A', 'BOOL',[
172
172
  ["PCHAR","lpName","in"],
173
173
  ["PCHAR","lpOemName","out"],
174
174
  ["DWORD","OemNameSize","in"],
@@ -176,7 +176,7 @@ class Def_kernel32
176
176
  ["PBLOB","pbNameLegal","out"],
177
177
  ])
178
178
 
179
- railgun.add_function('kernel32', 'CheckNameLegalDOS8Dot3W', 'BOOL',[
179
+ dll.add_function( 'CheckNameLegalDOS8Dot3W', 'BOOL',[
180
180
  ["PWCHAR","lpName","in"],
181
181
  ["PCHAR","lpOemName","out"],
182
182
  ["DWORD","OemNameSize","in"],
@@ -184,72 +184,72 @@ class Def_kernel32
184
184
  ["PBLOB","pbNameLegal","out"],
185
185
  ])
186
186
 
187
- railgun.add_function('kernel32', 'CheckRemoteDebuggerPresent', 'BOOL',[
187
+ dll.add_function( 'CheckRemoteDebuggerPresent', 'BOOL',[
188
188
  ["HANDLE","hProcess","in"],
189
189
  ["PBLOB","pbDebuggerPresent","out"],
190
190
  ])
191
191
 
192
- railgun.add_function('kernel32', 'ClearCommBreak', 'BOOL',[
192
+ dll.add_function( 'ClearCommBreak', 'BOOL',[
193
193
  ["HANDLE","hFile","in"],
194
194
  ])
195
195
 
196
- railgun.add_function('kernel32', 'ClearCommError', 'BOOL',[
196
+ dll.add_function( 'ClearCommError', 'BOOL',[
197
197
  ["HANDLE","hFile","in"],
198
198
  ["PDWORD","lpErrors","out"],
199
199
  ["PBLOB","lpStat","out"],
200
200
  ])
201
201
 
202
- railgun.add_function('kernel32', 'CloseHandle', 'BOOL',[
202
+ dll.add_function( 'CloseHandle', 'BOOL',[
203
203
  ["HANDLE","hObject","in"],
204
204
  ])
205
205
 
206
- railgun.add_function('kernel32', 'CommConfigDialogA', 'BOOL',[
206
+ dll.add_function( 'CommConfigDialogA', 'BOOL',[
207
207
  ["PCHAR","lpszName","in"],
208
208
  ["HANDLE","hWnd","in"],
209
209
  ["PBLOB","lpCC","inout"],
210
210
  ])
211
211
 
212
- railgun.add_function('kernel32', 'CommConfigDialogW', 'BOOL',[
212
+ dll.add_function( 'CommConfigDialogW', 'BOOL',[
213
213
  ["PWCHAR","lpszName","in"],
214
214
  ["HANDLE","hWnd","in"],
215
215
  ["PBLOB","lpCC","inout"],
216
216
  ])
217
217
 
218
- railgun.add_function('kernel32', 'CompareFileTime', 'DWORD',[
218
+ dll.add_function( 'CompareFileTime', 'DWORD',[
219
219
  ["PBLOB","lpFileTime1","in"],
220
220
  ["PBLOB","lpFileTime2","in"],
221
221
  ])
222
222
 
223
- railgun.add_function('kernel32', 'ConnectNamedPipe', 'BOOL',[
223
+ dll.add_function( 'ConnectNamedPipe', 'BOOL',[
224
224
  ["HANDLE","hNamedPipe","in"],
225
225
  ["PBLOB","lpOverlapped","inout"],
226
226
  ])
227
227
 
228
- railgun.add_function('kernel32', 'ContinueDebugEvent', 'BOOL',[
228
+ dll.add_function( 'ContinueDebugEvent', 'BOOL',[
229
229
  ["DWORD","dwProcessId","in"],
230
230
  ["DWORD","dwThreadId","in"],
231
231
  ["DWORD","dwContinueStatus","in"],
232
232
  ])
233
233
 
234
- railgun.add_function('kernel32', 'ConvertFiberToThread', 'BOOL',[
234
+ dll.add_function( 'ConvertFiberToThread', 'BOOL',[
235
235
  ])
236
236
 
237
- railgun.add_function('kernel32', 'ConvertThreadToFiber', 'LPVOID',[
237
+ dll.add_function( 'ConvertThreadToFiber', 'LPVOID',[
238
238
  ["PBLOB","lpParameter","in"],
239
239
  ])
240
240
 
241
- railgun.add_function('kernel32', 'ConvertThreadToFiberEx', 'LPVOID',[
241
+ dll.add_function( 'ConvertThreadToFiberEx', 'LPVOID',[
242
242
  ["PBLOB","lpParameter","in"],
243
243
  ["DWORD","dwFlags","in"],
244
244
  ])
245
245
 
246
- railgun.add_function('kernel32', 'CopyFileA', 'BOOL',[
246
+ dll.add_function( 'CopyFileA', 'BOOL',[
247
247
  ["PCHAR","lpExistingFileName","in"],
248
248
  ["PCHAR","lpNewFileName","in"],
249
249
  ["BOOL","bFailIfExists","in"],
250
250
  ])
251
251
 
252
- railgun.add_function('kernel32', 'CopyFileExA', 'BOOL',[
252
+ dll.add_function( 'CopyFileExA', 'BOOL',[
253
253
  ["PCHAR","lpExistingFileName","in"],
254
254
  ["PCHAR","lpNewFileName","in"],
255
255
  ["PBLOB","lpProgressRoutine","in"],
@@ -258,7 +258,7 @@ class Def_kernel32
258
258
  ["DWORD","dwCopyFlags","in"],
259
259
  ])
260
260
 
261
- railgun.add_function('kernel32', 'CopyFileExW', 'BOOL',[
261
+ dll.add_function( 'CopyFileExW', 'BOOL',[
262
262
  ["PWCHAR","lpExistingFileName","in"],
263
263
  ["PWCHAR","lpNewFileName","in"],
264
264
  ["PBLOB","lpProgressRoutine","in"],
@@ -267,63 +267,63 @@ class Def_kernel32
267
267
  ["DWORD","dwCopyFlags","in"],
268
268
  ])
269
269
 
270
- railgun.add_function('kernel32', 'CopyFileW', 'BOOL',[
270
+ dll.add_function( 'CopyFileW', 'BOOL',[
271
271
  ["PWCHAR","lpExistingFileName","in"],
272
272
  ["PWCHAR","lpNewFileName","in"],
273
273
  ["BOOL","bFailIfExists","in"],
274
274
  ])
275
275
 
276
- railgun.add_function('kernel32', 'CreateActCtxA', 'DWORD',[
276
+ dll.add_function( 'CreateActCtxA', 'DWORD',[
277
277
  ["PBLOB","pActCtx","in"],
278
278
  ])
279
279
 
280
- railgun.add_function('kernel32', 'CreateActCtxW', 'DWORD',[
280
+ dll.add_function( 'CreateActCtxW', 'DWORD',[
281
281
  ["PBLOB","pActCtx","in"],
282
282
  ])
283
283
 
284
- railgun.add_function('kernel32', 'CreateDirectoryA', 'BOOL',[
284
+ dll.add_function( 'CreateDirectoryA', 'BOOL',[
285
285
  ["PCHAR","lpPathName","in"],
286
286
  ["PBLOB","lpSecurityAttributes","in"],
287
287
  ])
288
288
 
289
- railgun.add_function('kernel32', 'CreateDirectoryExA', 'BOOL',[
289
+ dll.add_function( 'CreateDirectoryExA', 'BOOL',[
290
290
  ["PCHAR","lpTemplateDirectory","in"],
291
291
  ["PCHAR","lpNewDirectory","in"],
292
292
  ["PBLOB","lpSecurityAttributes","in"],
293
293
  ])
294
294
 
295
- railgun.add_function('kernel32', 'CreateDirectoryExW', 'BOOL',[
295
+ dll.add_function( 'CreateDirectoryExW', 'BOOL',[
296
296
  ["PWCHAR","lpTemplateDirectory","in"],
297
297
  ["PWCHAR","lpNewDirectory","in"],
298
298
  ["PBLOB","lpSecurityAttributes","in"],
299
299
  ])
300
300
 
301
- railgun.add_function('kernel32', 'CreateDirectoryW', 'BOOL',[
301
+ dll.add_function( 'CreateDirectoryW', 'BOOL',[
302
302
  ["PWCHAR","lpPathName","in"],
303
303
  ["PBLOB","lpSecurityAttributes","in"],
304
304
  ])
305
305
 
306
- railgun.add_function('kernel32', 'CreateEventA', 'DWORD',[
306
+ dll.add_function( 'CreateEventA', 'DWORD',[
307
307
  ["PBLOB","lpEventAttributes","in"],
308
308
  ["BOOL","bManualReset","in"],
309
309
  ["BOOL","bInitialState","in"],
310
310
  ["PCHAR","lpName","in"],
311
311
  ])
312
312
 
313
- railgun.add_function('kernel32', 'CreateEventW', 'DWORD',[
313
+ dll.add_function( 'CreateEventW', 'DWORD',[
314
314
  ["PBLOB","lpEventAttributes","in"],
315
315
  ["BOOL","bManualReset","in"],
316
316
  ["BOOL","bInitialState","in"],
317
317
  ["PWCHAR","lpName","in"],
318
318
  ])
319
319
 
320
- railgun.add_function('kernel32', 'CreateFiber', 'LPVOID',[
320
+ dll.add_function( 'CreateFiber', 'LPVOID',[
321
321
  ["DWORD","dwStackSize","in"],
322
322
  ["PBLOB","lpStartAddress","in"],
323
323
  ["PBLOB","lpParameter","in"],
324
324
  ])
325
325
 
326
- railgun.add_function('kernel32', 'CreateFiberEx', 'LPVOID',[
326
+ dll.add_function( 'CreateFiberEx', 'LPVOID',[
327
327
  ["DWORD","dwStackCommitSize","in"],
328
328
  ["DWORD","dwStackReserveSize","in"],
329
329
  ["DWORD","dwFlags","in"],
@@ -331,7 +331,7 @@ class Def_kernel32
331
331
  ["PBLOB","lpParameter","in"],
332
332
  ])
333
333
 
334
- railgun.add_function('kernel32', 'CreateFileA', 'DWORD',[
334
+ dll.add_function( 'CreateFileA', 'DWORD',[
335
335
  ["PCHAR","lpFileName","in"],
336
336
  ["DWORD","dwDesiredAccess","in"],
337
337
  ["DWORD","dwShareMode","in"],
@@ -341,7 +341,7 @@ class Def_kernel32
341
341
  ["HANDLE","hTemplateFile","in"],
342
342
  ])
343
343
 
344
- railgun.add_function('kernel32', 'CreateFileMappingA', 'DWORD',[
344
+ dll.add_function( 'CreateFileMappingA', 'DWORD',[
345
345
  ["HANDLE","hFile","in"],
346
346
  ["PBLOB","lpFileMappingAttributes","in"],
347
347
  ["DWORD","flProtect","in"],
@@ -350,7 +350,7 @@ class Def_kernel32
350
350
  ["PCHAR","lpName","in"],
351
351
  ])
352
352
 
353
- railgun.add_function('kernel32', 'CreateFileMappingW', 'DWORD',[
353
+ dll.add_function( 'CreateFileMappingW', 'DWORD',[
354
354
  ["HANDLE","hFile","in"],
355
355
  ["PBLOB","lpFileMappingAttributes","in"],
356
356
  ["DWORD","flProtect","in"],
@@ -359,7 +359,7 @@ class Def_kernel32
359
359
  ["PWCHAR","lpName","in"],
360
360
  ])
361
361
 
362
- railgun.add_function('kernel32', 'CreateFileW', 'DWORD',[
362
+ dll.add_function( 'CreateFileW', 'DWORD',[
363
363
  ["PWCHAR","lpFileName","in"],
364
364
  ["DWORD","dwDesiredAccess","in"],
365
365
  ["DWORD","dwShareMode","in"],
@@ -369,72 +369,72 @@ class Def_kernel32
369
369
  ["HANDLE","hTemplateFile","in"],
370
370
  ])
371
371
 
372
- railgun.add_function('kernel32', 'CreateHardLinkA', 'BOOL',[
372
+ dll.add_function( 'CreateHardLinkA', 'BOOL',[
373
373
  ["PCHAR","lpFileName","in"],
374
374
  ["PCHAR","lpExistingFileName","in"],
375
375
  ["PBLOB","lpSecurityAttributes","inout"],
376
376
  ])
377
377
 
378
- railgun.add_function('kernel32', 'CreateHardLinkW', 'BOOL',[
378
+ dll.add_function( 'CreateHardLinkW', 'BOOL',[
379
379
  ["PWCHAR","lpFileName","in"],
380
380
  ["PWCHAR","lpExistingFileName","in"],
381
381
  ["PBLOB","lpSecurityAttributes","inout"],
382
382
  ])
383
383
 
384
- railgun.add_function('kernel32', 'CreateIoCompletionPort', 'DWORD',[
384
+ dll.add_function( 'CreateIoCompletionPort', 'DWORD',[
385
385
  ["DWORD","FileHandle","in"],
386
386
  ["DWORD","ExistingCompletionPort","in"],
387
387
  ["PDWORD","CompletionKey","in"],
388
388
  ["DWORD","NumberOfConcurrentThreads","in"],
389
389
  ])
390
390
 
391
- railgun.add_function('kernel32', 'CreateJobObjectA', 'DWORD',[
391
+ dll.add_function( 'CreateJobObjectA', 'DWORD',[
392
392
  ["PBLOB","lpJobAttributes","in"],
393
393
  ["PCHAR","lpName","in"],
394
394
  ])
395
395
 
396
- railgun.add_function('kernel32', 'CreateJobObjectW', 'DWORD',[
396
+ dll.add_function( 'CreateJobObjectW', 'DWORD',[
397
397
  ["PBLOB","lpJobAttributes","in"],
398
398
  ["PWCHAR","lpName","in"],
399
399
  ])
400
400
 
401
- railgun.add_function('kernel32', 'CreateJobSet', 'BOOL',[
401
+ dll.add_function( 'CreateJobSet', 'BOOL',[
402
402
  ["DWORD","NumJob","in"],
403
403
  ["PBLOB","UserJobSet","in"],
404
404
  ["DWORD","Flags","in"],
405
405
  ])
406
406
 
407
- railgun.add_function('kernel32', 'CreateMailslotA', 'DWORD',[
407
+ dll.add_function( 'CreateMailslotA', 'DWORD',[
408
408
  ["PCHAR","lpName","in"],
409
409
  ["DWORD","nMaxMessageSize","in"],
410
410
  ["DWORD","lReadTimeout","in"],
411
411
  ["PBLOB","lpSecurityAttributes","in"],
412
412
  ])
413
413
 
414
- railgun.add_function('kernel32', 'CreateMailslotW', 'DWORD',[
414
+ dll.add_function( 'CreateMailslotW', 'DWORD',[
415
415
  ["PWCHAR","lpName","in"],
416
416
  ["DWORD","nMaxMessageSize","in"],
417
417
  ["DWORD","lReadTimeout","in"],
418
418
  ["PBLOB","lpSecurityAttributes","in"],
419
419
  ])
420
420
 
421
- railgun.add_function('kernel32', 'CreateMemoryResourceNotification', 'DWORD',[
421
+ dll.add_function( 'CreateMemoryResourceNotification', 'DWORD',[
422
422
  ["PDWORD","NotificationType","in"],
423
423
  ])
424
424
 
425
- railgun.add_function('kernel32', 'CreateMutexA', 'DWORD',[
425
+ dll.add_function( 'CreateMutexA', 'DWORD',[
426
426
  ["PBLOB","lpMutexAttributes","in"],
427
427
  ["BOOL","bInitialOwner","in"],
428
428
  ["PCHAR","lpName","in"],
429
429
  ])
430
430
 
431
- railgun.add_function('kernel32', 'CreateMutexW', 'DWORD',[
431
+ dll.add_function( 'CreateMutexW', 'DWORD',[
432
432
  ["PBLOB","lpMutexAttributes","in"],
433
433
  ["BOOL","bInitialOwner","in"],
434
434
  ["PWCHAR","lpName","in"],
435
435
  ])
436
436
 
437
- railgun.add_function('kernel32', 'CreateNamedPipeA', 'DWORD',[
437
+ dll.add_function( 'CreateNamedPipeA', 'DWORD',[
438
438
  ["PCHAR","lpName","in"],
439
439
  ["DWORD","dwOpenMode","in"],
440
440
  ["DWORD","dwPipeMode","in"],
@@ -445,7 +445,7 @@ class Def_kernel32
445
445
  ["PBLOB","lpSecurityAttributes","in"],
446
446
  ])
447
447
 
448
- railgun.add_function('kernel32', 'CreateNamedPipeW', 'DWORD',[
448
+ dll.add_function( 'CreateNamedPipeW', 'DWORD',[
449
449
  ["PWCHAR","lpName","in"],
450
450
  ["DWORD","dwOpenMode","in"],
451
451
  ["DWORD","dwPipeMode","in"],
@@ -456,14 +456,14 @@ class Def_kernel32
456
456
  ["PBLOB","lpSecurityAttributes","in"],
457
457
  ])
458
458
 
459
- railgun.add_function('kernel32', 'CreatePipe', 'BOOL',[
459
+ dll.add_function( 'CreatePipe', 'BOOL',[
460
460
  ["PDWORD","hReadPipe","out"],
461
461
  ["PDWORD","hWritePipe","out"],
462
462
  ["PBLOB","lpPipeAttributes","in"],
463
463
  ["DWORD","nSize","in"],
464
464
  ])
465
465
 
466
- railgun.add_function('kernel32', 'CreateProcessA', 'BOOL',[
466
+ dll.add_function( 'CreateProcessA', 'BOOL',[
467
467
  ["PCHAR","lpApplicationName","in"],
468
468
  ["PCHAR","lpCommandLine","inout"],
469
469
  ["PBLOB","lpProcessAttributes","in"],
@@ -476,7 +476,7 @@ class Def_kernel32
476
476
  ["PBLOB","lpProcessInformation","out"],
477
477
  ])
478
478
 
479
- railgun.add_function('kernel32', 'CreateProcessW', 'BOOL',[
479
+ dll.add_function( 'CreateProcessW', 'BOOL',[
480
480
  ["PWCHAR","lpApplicationName","in"],
481
481
  ["PWCHAR","lpCommandLine","inout"],
482
482
  ["PBLOB","lpProcessAttributes","in"],
@@ -489,7 +489,7 @@ class Def_kernel32
489
489
  ["PBLOB","lpProcessInformation","out"],
490
490
  ])
491
491
 
492
- railgun.add_function('kernel32', 'CreateRemoteThread', 'DWORD',[
492
+ dll.add_function( 'CreateRemoteThread', 'DWORD',[
493
493
  ["HANDLE","hProcess","in"],
494
494
  ["PBLOB","lpThreadAttributes","in"],
495
495
  ["DWORD","dwStackSize","in"],
@@ -499,28 +499,28 @@ class Def_kernel32
499
499
  ["PDWORD","lpThreadId","out"],
500
500
  ])
501
501
 
502
- railgun.add_function('kernel32', 'CreateSemaphoreA', 'DWORD',[
502
+ dll.add_function( 'CreateSemaphoreA', 'DWORD',[
503
503
  ["PBLOB","lpSemaphoreAttributes","in"],
504
504
  ["DWORD","lInitialCount","in"],
505
505
  ["DWORD","lMaximumCount","in"],
506
506
  ["PCHAR","lpName","in"],
507
507
  ])
508
508
 
509
- railgun.add_function('kernel32', 'CreateSemaphoreW', 'DWORD',[
509
+ dll.add_function( 'CreateSemaphoreW', 'DWORD',[
510
510
  ["PBLOB","lpSemaphoreAttributes","in"],
511
511
  ["DWORD","lInitialCount","in"],
512
512
  ["DWORD","lMaximumCount","in"],
513
513
  ["PWCHAR","lpName","in"],
514
514
  ])
515
515
 
516
- railgun.add_function('kernel32', 'CreateTapePartition', 'DWORD',[
516
+ dll.add_function( 'CreateTapePartition', 'DWORD',[
517
517
  ["HANDLE","hDevice","in"],
518
518
  ["DWORD","dwPartitionMethod","in"],
519
519
  ["DWORD","dwCount","in"],
520
520
  ["DWORD","dwSize","in"],
521
521
  ])
522
522
 
523
- railgun.add_function('kernel32', 'CreateThread', 'HANDLE',[
523
+ dll.add_function( 'CreateThread', 'HANDLE',[
524
524
  ["PBLOB","lpThreadAttributes","in"],
525
525
  ["DWORD","dwStackSize","in"],
526
526
  ["LPVOID","lpStartAddress","in"],
@@ -529,10 +529,10 @@ class Def_kernel32
529
529
  ["PDWORD","lpThreadId","out"],
530
530
  ])
531
531
 
532
- railgun.add_function('kernel32', 'CreateTimerQueue', 'DWORD',[
532
+ dll.add_function( 'CreateTimerQueue', 'DWORD',[
533
533
  ])
534
534
 
535
- railgun.add_function('kernel32', 'CreateTimerQueueTimer', 'BOOL',[
535
+ dll.add_function( 'CreateTimerQueueTimer', 'BOOL',[
536
536
  ["PDWORD","phNewTimer","out"],
537
537
  ["DWORD","TimerQueue","in"],
538
538
  ["PBLOB","Callback","in"],
@@ -542,106 +542,106 @@ class Def_kernel32
542
542
  ["DWORD","Flags","in"],
543
543
  ])
544
544
 
545
- railgun.add_function('kernel32', 'CreateWaitableTimerA', 'DWORD',[
545
+ dll.add_function( 'CreateWaitableTimerA', 'DWORD',[
546
546
  ["PBLOB","lpTimerAttributes","in"],
547
547
  ["BOOL","bManualReset","in"],
548
548
  ["PCHAR","lpTimerName","in"],
549
549
  ])
550
550
 
551
- railgun.add_function('kernel32', 'CreateWaitableTimerW', 'DWORD',[
551
+ dll.add_function( 'CreateWaitableTimerW', 'DWORD',[
552
552
  ["PBLOB","lpTimerAttributes","in"],
553
553
  ["BOOL","bManualReset","in"],
554
554
  ["PWCHAR","lpTimerName","in"],
555
555
  ])
556
556
 
557
- railgun.add_function('kernel32', 'DeactivateActCtx', 'BOOL',[
557
+ dll.add_function( 'DeactivateActCtx', 'BOOL',[
558
558
  ["DWORD","dwFlags","in"],
559
559
  ["PDWORD","ulCookie","in"],
560
560
  ])
561
561
 
562
- railgun.add_function('kernel32', 'DebugActiveProcess', 'BOOL',[
562
+ dll.add_function( 'DebugActiveProcess', 'BOOL',[
563
563
  ["DWORD","dwProcessId","in"],
564
564
  ])
565
565
 
566
- railgun.add_function('kernel32', 'DebugActiveProcessStop', 'BOOL',[
566
+ dll.add_function( 'DebugActiveProcessStop', 'BOOL',[
567
567
  ["DWORD","dwProcessId","in"],
568
568
  ])
569
569
 
570
- railgun.add_function('kernel32', 'DebugBreak', 'VOID',[
570
+ dll.add_function( 'DebugBreak', 'VOID',[
571
571
  ])
572
572
 
573
- railgun.add_function('kernel32', 'DebugBreakProcess', 'BOOL',[
573
+ dll.add_function( 'DebugBreakProcess', 'BOOL',[
574
574
  ["DWORD","Process","in"],
575
575
  ])
576
576
 
577
- railgun.add_function('kernel32', 'DebugSetProcessKillOnExit', 'BOOL',[
577
+ dll.add_function( 'DebugSetProcessKillOnExit', 'BOOL',[
578
578
  ["BOOL","KillOnExit","in"],
579
579
  ])
580
580
 
581
- railgun.add_function('kernel32', 'DecodePointer', 'LPVOID',[
581
+ dll.add_function( 'DecodePointer', 'LPVOID',[
582
582
  ["PBLOB","Ptr","in"],
583
583
  ])
584
584
 
585
- railgun.add_function('kernel32', 'DecodeSystemPointer', 'LPVOID',[
585
+ dll.add_function( 'DecodeSystemPointer', 'LPVOID',[
586
586
  ["PBLOB","Ptr","in"],
587
587
  ])
588
588
 
589
- railgun.add_function('kernel32', 'DefineDosDeviceA', 'BOOL',[
589
+ dll.add_function( 'DefineDosDeviceA', 'BOOL',[
590
590
  ["DWORD","dwFlags","in"],
591
591
  ["PCHAR","lpDeviceName","in"],
592
592
  ["PCHAR","lpTargetPath","in"],
593
593
  ])
594
594
 
595
- railgun.add_function('kernel32', 'DefineDosDeviceW', 'BOOL',[
595
+ dll.add_function( 'DefineDosDeviceW', 'BOOL',[
596
596
  ["DWORD","dwFlags","in"],
597
597
  ["PWCHAR","lpDeviceName","in"],
598
598
  ["PWCHAR","lpTargetPath","in"],
599
599
  ])
600
600
 
601
- railgun.add_function('kernel32', 'DeleteAtom', 'WORD',[
601
+ dll.add_function( 'DeleteAtom', 'WORD',[
602
602
  ["WORD","nAtom","in"],
603
603
  ])
604
604
 
605
- railgun.add_function('kernel32', 'DeleteCriticalSection', 'VOID',[
605
+ dll.add_function( 'DeleteCriticalSection', 'VOID',[
606
606
  ["PBLOB","lpCriticalSection","inout"],
607
607
  ])
608
608
 
609
- railgun.add_function('kernel32', 'DeleteFiber', 'VOID',[
609
+ dll.add_function( 'DeleteFiber', 'VOID',[
610
610
  ["PBLOB","lpFiber","in"],
611
611
  ])
612
612
 
613
- railgun.add_function('kernel32', 'DeleteFileA', 'BOOL',[
613
+ dll.add_function( 'DeleteFileA', 'BOOL',[
614
614
  ["PCHAR","lpFileName","in"],
615
615
  ])
616
616
 
617
- railgun.add_function('kernel32', 'DeleteFileW', 'BOOL',[
617
+ dll.add_function( 'DeleteFileW', 'BOOL',[
618
618
  ["PWCHAR","lpFileName","in"],
619
619
  ])
620
620
 
621
- railgun.add_function('kernel32', 'DeleteTimerQueue', 'BOOL',[
621
+ dll.add_function( 'DeleteTimerQueue', 'BOOL',[
622
622
  ["DWORD","TimerQueue","in"],
623
623
  ])
624
624
 
625
- railgun.add_function('kernel32', 'DeleteTimerQueueEx', 'BOOL',[
625
+ dll.add_function( 'DeleteTimerQueueEx', 'BOOL',[
626
626
  ["DWORD","TimerQueue","in"],
627
627
  ["DWORD","CompletionEvent","in"],
628
628
  ])
629
629
 
630
- railgun.add_function('kernel32', 'DeleteTimerQueueTimer', 'BOOL',[
630
+ dll.add_function( 'DeleteTimerQueueTimer', 'BOOL',[
631
631
  ["DWORD","TimerQueue","in"],
632
632
  ["DWORD","Timer","in"],
633
633
  ["DWORD","CompletionEvent","in"],
634
634
  ])
635
635
 
636
- railgun.add_function('kernel32', 'DeleteVolumeMountPointA', 'BOOL',[
636
+ dll.add_function( 'DeleteVolumeMountPointA', 'BOOL',[
637
637
  ["PCHAR","lpszVolumeMountPoint","in"],
638
638
  ])
639
639
 
640
- railgun.add_function('kernel32', 'DeleteVolumeMountPointW', 'BOOL',[
640
+ dll.add_function( 'DeleteVolumeMountPointW', 'BOOL',[
641
641
  ["PWCHAR","lpszVolumeMountPoint","in"],
642
642
  ])
643
643
 
644
- railgun.add_function('kernel32', 'DeviceIoControl', 'BOOL',[
644
+ dll.add_function( 'DeviceIoControl', 'BOOL',[
645
645
  ["HANDLE","hDevice","in"],
646
646
  ["DWORD","dwIoControlCode","in"],
647
647
  ["PBLOB","lpInBuffer","in"],
@@ -652,33 +652,33 @@ class Def_kernel32
652
652
  ["PBLOB","lpOverlapped","inout"],
653
653
  ])
654
654
 
655
- railgun.add_function('kernel32', 'DisableThreadLibraryCalls', 'BOOL',[
655
+ dll.add_function( 'DisableThreadLibraryCalls', 'BOOL',[
656
656
  ["HANDLE","hLibModule","in"],
657
657
  ])
658
658
 
659
- railgun.add_function('kernel32', 'DisconnectNamedPipe', 'BOOL',[
659
+ dll.add_function( 'DisconnectNamedPipe', 'BOOL',[
660
660
  ["HANDLE","hNamedPipe","in"],
661
661
  ])
662
662
 
663
- railgun.add_function('kernel32', 'DnsHostnameToComputerNameA', 'BOOL',[
663
+ dll.add_function( 'DnsHostnameToComputerNameA', 'BOOL',[
664
664
  ["PCHAR","Hostname","in"],
665
665
  ["PCHAR","ComputerName","out"],
666
666
  ["PDWORD","nSize","inout"],
667
667
  ])
668
668
 
669
- railgun.add_function('kernel32', 'DnsHostnameToComputerNameW', 'BOOL',[
669
+ dll.add_function( 'DnsHostnameToComputerNameW', 'BOOL',[
670
670
  ["PWCHAR","Hostname","in"],
671
671
  ["PWCHAR","ComputerName","out"],
672
672
  ["PDWORD","nSize","inout"],
673
673
  ])
674
674
 
675
- railgun.add_function('kernel32', 'DosDateTimeToFileTime', 'BOOL',[
675
+ dll.add_function( 'DosDateTimeToFileTime', 'BOOL',[
676
676
  ["WORD","wFatDate","in"],
677
677
  ["WORD","wFatTime","in"],
678
678
  ["PBLOB","lpFileTime","out"],
679
679
  ])
680
680
 
681
- railgun.add_function('kernel32', 'DuplicateHandle', 'BOOL',[
681
+ dll.add_function( 'DuplicateHandle', 'BOOL',[
682
682
  ["HANDLE","hSourceProcessHandle","in"],
683
683
  ["HANDLE","hSourceHandle","in"],
684
684
  ["HANDLE","hTargetProcessHandle","in"],
@@ -688,29 +688,29 @@ class Def_kernel32
688
688
  ["DWORD","dwOptions","in"],
689
689
  ])
690
690
 
691
- railgun.add_function('kernel32', 'EncodePointer', 'LPVOID',[
691
+ dll.add_function( 'EncodePointer', 'LPVOID',[
692
692
  ["PBLOB","Ptr","in"],
693
693
  ])
694
694
 
695
- railgun.add_function('kernel32', 'EncodeSystemPointer', 'LPVOID',[
695
+ dll.add_function( 'EncodeSystemPointer', 'LPVOID',[
696
696
  ["PBLOB","Ptr","in"],
697
697
  ])
698
698
 
699
- railgun.add_function('kernel32', 'EndUpdateResourceA', 'BOOL',[
699
+ dll.add_function( 'EndUpdateResourceA', 'BOOL',[
700
700
  ["HANDLE","hUpdate","in"],
701
701
  ["BOOL","fDiscard","in"],
702
702
  ])
703
703
 
704
- railgun.add_function('kernel32', 'EndUpdateResourceW', 'BOOL',[
704
+ dll.add_function( 'EndUpdateResourceW', 'BOOL',[
705
705
  ["HANDLE","hUpdate","in"],
706
706
  ["BOOL","fDiscard","in"],
707
707
  ])
708
708
 
709
- railgun.add_function('kernel32', 'EnterCriticalSection', 'VOID',[
709
+ dll.add_function( 'EnterCriticalSection', 'VOID',[
710
710
  ["PBLOB","lpCriticalSection","inout"],
711
711
  ])
712
712
 
713
- railgun.add_function('kernel32', 'EnumResourceLanguagesA', 'BOOL',[
713
+ dll.add_function( 'EnumResourceLanguagesA', 'BOOL',[
714
714
  ["HANDLE","hModule","in"],
715
715
  ["PCHAR","lpType","in"],
716
716
  ["PCHAR","lpName","in"],
@@ -718,7 +718,7 @@ class Def_kernel32
718
718
  ["PBLOB","lparam","in"],
719
719
  ])
720
720
 
721
- railgun.add_function('kernel32', 'EnumResourceLanguagesW', 'BOOL',[
721
+ dll.add_function( 'EnumResourceLanguagesW', 'BOOL',[
722
722
  ["HANDLE","hModule","in"],
723
723
  ["PWCHAR","lpType","in"],
724
724
  ["PWCHAR","lpName","in"],
@@ -726,100 +726,100 @@ class Def_kernel32
726
726
  ["PBLOB","lparam","in"],
727
727
  ])
728
728
 
729
- railgun.add_function('kernel32', 'EnumResourceNamesA', 'BOOL',[
729
+ dll.add_function( 'EnumResourceNamesA', 'BOOL',[
730
730
  ["HANDLE","hModule","in"],
731
731
  ["PCHAR","lpType","in"],
732
732
  ["PBLOB","lpEnumFunc","in"],
733
733
  ["PBLOB","lparam","in"],
734
734
  ])
735
735
 
736
- railgun.add_function('kernel32', 'EnumResourceNamesW', 'BOOL',[
736
+ dll.add_function( 'EnumResourceNamesW', 'BOOL',[
737
737
  ["HANDLE","hModule","in"],
738
738
  ["PWCHAR","lpType","in"],
739
739
  ["PBLOB","lpEnumFunc","in"],
740
740
  ["PBLOB","lparam","in"],
741
741
  ])
742
742
 
743
- railgun.add_function('kernel32', 'EnumResourceTypesA', 'BOOL',[
743
+ dll.add_function( 'EnumResourceTypesA', 'BOOL',[
744
744
  ["HANDLE","hModule","in"],
745
745
  ["PBLOB","lpEnumFunc","in"],
746
746
  ["PBLOB","lparam","in"],
747
747
  ])
748
748
 
749
- railgun.add_function('kernel32', 'EnumResourceTypesW', 'BOOL',[
749
+ dll.add_function( 'EnumResourceTypesW', 'BOOL',[
750
750
  ["HANDLE","hModule","in"],
751
751
  ["PBLOB","lpEnumFunc","in"],
752
752
  ["PBLOB","lparam","in"],
753
753
  ])
754
754
 
755
- railgun.add_function('kernel32', 'EnumSystemFirmwareTables', 'DWORD',[
755
+ dll.add_function( 'EnumSystemFirmwareTables', 'DWORD',[
756
756
  ["DWORD","FirmwareTableProviderSignature","in"],
757
757
  ["PBLOB","pFirmwareTableEnumBuffer","out"],
758
758
  ["DWORD","BufferSize","in"],
759
759
  ])
760
760
 
761
- railgun.add_function('kernel32', 'EraseTape', 'DWORD',[
761
+ dll.add_function( 'EraseTape', 'DWORD',[
762
762
  ["HANDLE","hDevice","in"],
763
763
  ["DWORD","dwEraseType","in"],
764
764
  ["BOOL","bImmediate","in"],
765
765
  ])
766
766
 
767
- railgun.add_function('kernel32', 'EscapeCommFunction', 'BOOL',[
767
+ dll.add_function( 'EscapeCommFunction', 'BOOL',[
768
768
  ["HANDLE","hFile","in"],
769
769
  ["DWORD","dwFunc","in"],
770
770
  ])
771
771
 
772
- railgun.add_function('kernel32', 'ExitProcess', 'VOID',[
772
+ dll.add_function( 'ExitProcess', 'VOID',[
773
773
  ["DWORD","uExitCode","in"],
774
774
  ])
775
775
 
776
- railgun.add_function('kernel32', 'ExitThread', 'VOID',[
776
+ dll.add_function( 'ExitThread', 'VOID',[
777
777
  ["DWORD","dwExitCode","in"],
778
778
  ])
779
779
 
780
- railgun.add_function('kernel32', 'ExpandEnvironmentStringsA', 'DWORD',[
780
+ dll.add_function( 'ExpandEnvironmentStringsA', 'DWORD',[
781
781
  ["PCHAR","lpSrc","in"],
782
782
  ["PCHAR","lpDst","out"],
783
783
  ["DWORD","nSize","in"],
784
784
  ])
785
785
 
786
- railgun.add_function('kernel32', 'ExpandEnvironmentStringsW', 'DWORD',[
786
+ dll.add_function( 'ExpandEnvironmentStringsW', 'DWORD',[
787
787
  ["PWCHAR","lpSrc","in"],
788
788
  ["PWCHAR","lpDst","out"],
789
789
  ["DWORD","nSize","in"],
790
790
  ])
791
791
 
792
- railgun.add_function('kernel32', 'FatalAppExitA', 'VOID',[
792
+ dll.add_function( 'FatalAppExitA', 'VOID',[
793
793
  ["DWORD","uAction","in"],
794
794
  ["PCHAR","lpMessageText","in"],
795
795
  ])
796
796
 
797
- railgun.add_function('kernel32', 'FatalAppExitW', 'VOID',[
797
+ dll.add_function( 'FatalAppExitW', 'VOID',[
798
798
  ["DWORD","uAction","in"],
799
799
  ["PWCHAR","lpMessageText","in"],
800
800
  ])
801
801
 
802
- railgun.add_function('kernel32', 'FatalExit', 'VOID',[
802
+ dll.add_function( 'FatalExit', 'VOID',[
803
803
  ["DWORD","ExitCode","in"],
804
804
  ])
805
805
 
806
- railgun.add_function('kernel32', 'FileTimeToDosDateTime', 'BOOL',[
806
+ dll.add_function( 'FileTimeToDosDateTime', 'BOOL',[
807
807
  ["PBLOB","lpFileTime","in"],
808
808
  ["PBLOB","lpFatDate","out"],
809
809
  ["PBLOB","lpFatTime","out"],
810
810
  ])
811
811
 
812
- railgun.add_function('kernel32', 'FileTimeToLocalFileTime', 'BOOL',[
812
+ dll.add_function( 'FileTimeToLocalFileTime', 'BOOL',[
813
813
  ["PBLOB","lpFileTime","in"],
814
814
  ["PBLOB","lpLocalFileTime","out"],
815
815
  ])
816
816
 
817
- railgun.add_function('kernel32', 'FileTimeToSystemTime', 'BOOL',[
817
+ dll.add_function( 'FileTimeToSystemTime', 'BOOL',[
818
818
  ["PBLOB","lpFileTime","in"],
819
819
  ["PBLOB","lpSystemTime","out"],
820
820
  ])
821
821
 
822
- railgun.add_function('kernel32', 'FindActCtxSectionGuid', 'BOOL',[
822
+ dll.add_function( 'FindActCtxSectionGuid', 'BOOL',[
823
823
  ["DWORD","dwFlags","in"],
824
824
  ["PBLOB","lpExtensionGuid","inout"],
825
825
  ["DWORD","ulSectionId","in"],
@@ -827,7 +827,7 @@ class Def_kernel32
827
827
  ["PBLOB","ReturnedData","out"],
828
828
  ])
829
829
 
830
- railgun.add_function('kernel32', 'FindActCtxSectionStringA', 'BOOL',[
830
+ dll.add_function( 'FindActCtxSectionStringA', 'BOOL',[
831
831
  ["DWORD","dwFlags","in"],
832
832
  ["PBLOB","lpExtensionGuid","inout"],
833
833
  ["DWORD","ulSectionId","in"],
@@ -835,7 +835,7 @@ class Def_kernel32
835
835
  ["PBLOB","ReturnedData","out"],
836
836
  ])
837
837
 
838
- railgun.add_function('kernel32', 'FindActCtxSectionStringW', 'BOOL',[
838
+ dll.add_function( 'FindActCtxSectionStringW', 'BOOL',[
839
839
  ["DWORD","dwFlags","in"],
840
840
  ["PBLOB","lpExtensionGuid","inout"],
841
841
  ["DWORD","ulSectionId","in"],
@@ -843,40 +843,40 @@ class Def_kernel32
843
843
  ["PBLOB","ReturnedData","out"],
844
844
  ])
845
845
 
846
- railgun.add_function('kernel32', 'FindAtomA', 'WORD',[
846
+ dll.add_function( 'FindAtomA', 'WORD',[
847
847
  ["PCHAR","lpString","in"],
848
848
  ])
849
849
 
850
- railgun.add_function('kernel32', 'FindAtomW', 'WORD',[
850
+ dll.add_function( 'FindAtomW', 'WORD',[
851
851
  ["PWCHAR","lpString","in"],
852
852
  ])
853
853
 
854
- railgun.add_function('kernel32', 'FindClose', 'BOOL',[
854
+ dll.add_function( 'FindClose', 'BOOL',[
855
855
  ["HANDLE","hFindFile","inout"],
856
856
  ])
857
857
 
858
- railgun.add_function('kernel32', 'FindCloseChangeNotification', 'BOOL',[
858
+ dll.add_function( 'FindCloseChangeNotification', 'BOOL',[
859
859
  ["HANDLE","hChangeHandle","in"],
860
860
  ])
861
861
 
862
- railgun.add_function('kernel32', 'FindFirstChangeNotificationA', 'DWORD',[
862
+ dll.add_function( 'FindFirstChangeNotificationA', 'DWORD',[
863
863
  ["PCHAR","lpPathName","in"],
864
864
  ["BOOL","bWatchSubtree","in"],
865
865
  ["DWORD","dwNotifyFilter","in"],
866
866
  ])
867
867
 
868
- railgun.add_function('kernel32', 'FindFirstChangeNotificationW', 'DWORD',[
868
+ dll.add_function( 'FindFirstChangeNotificationW', 'DWORD',[
869
869
  ["PWCHAR","lpPathName","in"],
870
870
  ["BOOL","bWatchSubtree","in"],
871
871
  ["DWORD","dwNotifyFilter","in"],
872
872
  ])
873
873
 
874
- railgun.add_function('kernel32', 'FindFirstFileA', 'DWORD',[
874
+ dll.add_function( 'FindFirstFileA', 'DWORD',[
875
875
  ["PCHAR","lpFileName","in"],
876
876
  ["PBLOB","lpFindFileData","out"],
877
877
  ])
878
878
 
879
- railgun.add_function('kernel32', 'FindFirstFileExA', 'DWORD',[
879
+ dll.add_function( 'FindFirstFileExA', 'DWORD',[
880
880
  ["PCHAR","lpFileName","in"],
881
881
  ["PBLOB","fInfoLevelId","in"],
882
882
  ["PBLOB","lpFindFileData","out"],
@@ -885,7 +885,7 @@ class Def_kernel32
885
885
  ["DWORD","dwAdditionalFlags","in"],
886
886
  ])
887
887
 
888
- railgun.add_function('kernel32', 'FindFirstFileExW', 'DWORD',[
888
+ dll.add_function( 'FindFirstFileExW', 'DWORD',[
889
889
  ["PWCHAR","lpFileName","in"],
890
890
  ["PBLOB","fInfoLevelId","in"],
891
891
  ["PBLOB","lpFindFileData","out"],
@@ -894,314 +894,314 @@ class Def_kernel32
894
894
  ["DWORD","dwAdditionalFlags","in"],
895
895
  ])
896
896
 
897
- railgun.add_function('kernel32', 'FindFirstFileW', 'DWORD',[
897
+ dll.add_function( 'FindFirstFileW', 'DWORD',[
898
898
  ["PWCHAR","lpFileName","in"],
899
899
  ["PBLOB","lpFindFileData","out"],
900
900
  ])
901
901
 
902
- railgun.add_function('kernel32', 'FindFirstStreamW', 'DWORD',[
902
+ dll.add_function( 'FindFirstStreamW', 'DWORD',[
903
903
  ["PWCHAR","lpFileName","in"],
904
904
  ["PBLOB","InfoLevel","in"],
905
905
  ["PBLOB","lpFindStreamData","out"],
906
906
  ["DWORD","dwFlags","inout"],
907
907
  ])
908
908
 
909
- railgun.add_function('kernel32', 'FindFirstVolumeA', 'DWORD',[
909
+ dll.add_function( 'FindFirstVolumeA', 'DWORD',[
910
910
  ["PCHAR","lpszVolumeName","out"],
911
911
  ["DWORD","cchBufferLength","in"],
912
912
  ])
913
913
 
914
- railgun.add_function('kernel32', 'FindFirstVolumeMountPointA', 'DWORD',[
914
+ dll.add_function( 'FindFirstVolumeMountPointA', 'DWORD',[
915
915
  ["PCHAR","lpszRootPathName","in"],
916
916
  ["PCHAR","lpszVolumeMountPoint","out"],
917
917
  ["DWORD","cchBufferLength","in"],
918
918
  ])
919
919
 
920
- railgun.add_function('kernel32', 'FindFirstVolumeMountPointW', 'DWORD',[
920
+ dll.add_function( 'FindFirstVolumeMountPointW', 'DWORD',[
921
921
  ["PWCHAR","lpszRootPathName","in"],
922
922
  ["PWCHAR","lpszVolumeMountPoint","out"],
923
923
  ["DWORD","cchBufferLength","in"],
924
924
  ])
925
925
 
926
- railgun.add_function('kernel32', 'FindFirstVolumeW', 'DWORD',[
926
+ dll.add_function( 'FindFirstVolumeW', 'DWORD',[
927
927
  ["PWCHAR","lpszVolumeName","out"],
928
928
  ["DWORD","cchBufferLength","in"],
929
929
  ])
930
930
 
931
- railgun.add_function('kernel32', 'FindNextChangeNotification', 'BOOL',[
931
+ dll.add_function( 'FindNextChangeNotification', 'BOOL',[
932
932
  ["HANDLE","hChangeHandle","in"],
933
933
  ])
934
934
 
935
- railgun.add_function('kernel32', 'FindNextFileA', 'BOOL',[
935
+ dll.add_function( 'FindNextFileA', 'BOOL',[
936
936
  ["HANDLE","hFindFile","in"],
937
937
  ["PBLOB","lpFindFileData","out"],
938
938
  ])
939
939
 
940
- railgun.add_function('kernel32', 'FindNextFileW', 'BOOL',[
940
+ dll.add_function( 'FindNextFileW', 'BOOL',[
941
941
  ["HANDLE","hFindFile","in"],
942
942
  ["PBLOB","lpFindFileData","out"],
943
943
  ])
944
944
 
945
- railgun.add_function('kernel32', 'FindNextStreamW', 'BOOL',[
945
+ dll.add_function( 'FindNextStreamW', 'BOOL',[
946
946
  ["HANDLE","hFindStream","in"],
947
947
  ["PBLOB","lpFindStreamData","out"],
948
948
  ])
949
949
 
950
- railgun.add_function('kernel32', 'FindNextVolumeA', 'BOOL',[
950
+ dll.add_function( 'FindNextVolumeA', 'BOOL',[
951
951
  ["HANDLE","hFindVolume","inout"],
952
952
  ["PCHAR","lpszVolumeName","out"],
953
953
  ["DWORD","cchBufferLength","in"],
954
954
  ])
955
955
 
956
- railgun.add_function('kernel32', 'FindNextVolumeMountPointA', 'BOOL',[
956
+ dll.add_function( 'FindNextVolumeMountPointA', 'BOOL',[
957
957
  ["HANDLE","hFindVolumeMountPoint","in"],
958
958
  ["PCHAR","lpszVolumeMountPoint","out"],
959
959
  ["DWORD","cchBufferLength","in"],
960
960
  ])
961
961
 
962
- railgun.add_function('kernel32', 'FindNextVolumeMountPointW', 'BOOL',[
962
+ dll.add_function( 'FindNextVolumeMountPointW', 'BOOL',[
963
963
  ["HANDLE","hFindVolumeMountPoint","in"],
964
964
  ["PWCHAR","lpszVolumeMountPoint","out"],
965
965
  ["DWORD","cchBufferLength","in"],
966
966
  ])
967
967
 
968
- railgun.add_function('kernel32', 'FindNextVolumeW', 'BOOL',[
968
+ dll.add_function( 'FindNextVolumeW', 'BOOL',[
969
969
  ["HANDLE","hFindVolume","inout"],
970
970
  ["PWCHAR","lpszVolumeName","out"],
971
971
  ["DWORD","cchBufferLength","in"],
972
972
  ])
973
973
 
974
- railgun.add_function('kernel32', 'FindResourceA', 'DWORD',[
974
+ dll.add_function( 'FindResourceA', 'DWORD',[
975
975
  ["HANDLE","hModule","in"],
976
976
  ["PCHAR","lpName","in"],
977
977
  ["PCHAR","lpType","in"],
978
978
  ])
979
979
 
980
- railgun.add_function('kernel32', 'FindResourceExA', 'DWORD',[
980
+ dll.add_function( 'FindResourceExA', 'DWORD',[
981
981
  ["HANDLE","hModule","in"],
982
982
  ["PCHAR","lpType","in"],
983
983
  ["PCHAR","lpName","in"],
984
984
  ["WORD","wLanguage","in"],
985
985
  ])
986
986
 
987
- railgun.add_function('kernel32', 'FindResourceExW', 'DWORD',[
987
+ dll.add_function( 'FindResourceExW', 'DWORD',[
988
988
  ["HANDLE","hModule","in"],
989
989
  ["PWCHAR","lpType","in"],
990
990
  ["PWCHAR","lpName","in"],
991
991
  ["WORD","wLanguage","in"],
992
992
  ])
993
993
 
994
- railgun.add_function('kernel32', 'FindResourceW', 'DWORD',[
994
+ dll.add_function( 'FindResourceW', 'DWORD',[
995
995
  ["HANDLE","hModule","in"],
996
996
  ["PWCHAR","lpName","in"],
997
997
  ["PWCHAR","lpType","in"],
998
998
  ])
999
999
 
1000
- railgun.add_function('kernel32', 'FindVolumeClose', 'BOOL',[
1000
+ dll.add_function( 'FindVolumeClose', 'BOOL',[
1001
1001
  ["HANDLE","hFindVolume","in"],
1002
1002
  ])
1003
1003
 
1004
- railgun.add_function('kernel32', 'FindVolumeMountPointClose', 'BOOL',[
1004
+ dll.add_function( 'FindVolumeMountPointClose', 'BOOL',[
1005
1005
  ["HANDLE","hFindVolumeMountPoint","in"],
1006
1006
  ])
1007
1007
 
1008
- railgun.add_function('kernel32', 'FlsAlloc', 'DWORD',[
1008
+ dll.add_function( 'FlsAlloc', 'DWORD',[
1009
1009
  ["PBLOB","lpCallback","in"],
1010
1010
  ])
1011
1011
 
1012
- railgun.add_function('kernel32', 'FlsFree', 'BOOL',[
1012
+ dll.add_function( 'FlsFree', 'BOOL',[
1013
1013
  ["DWORD","dwFlsIndex","in"],
1014
1014
  ])
1015
1015
 
1016
- railgun.add_function('kernel32', 'FlsGetValue', 'LPVOID',[
1016
+ dll.add_function( 'FlsGetValue', 'LPVOID',[
1017
1017
  ["DWORD","dwFlsIndex","in"],
1018
1018
  ])
1019
1019
 
1020
- railgun.add_function('kernel32', 'FlsSetValue', 'BOOL',[
1020
+ dll.add_function( 'FlsSetValue', 'BOOL',[
1021
1021
  ["DWORD","dwFlsIndex","in"],
1022
1022
  ["PBLOB","lpFlsData","in"],
1023
1023
  ])
1024
1024
 
1025
- railgun.add_function('kernel32', 'FlushFileBuffers', 'BOOL',[
1025
+ dll.add_function( 'FlushFileBuffers', 'BOOL',[
1026
1026
  ["HANDLE","hFile","in"],
1027
1027
  ])
1028
1028
 
1029
- railgun.add_function('kernel32', 'FlushInstructionCache', 'BOOL',[
1029
+ dll.add_function( 'FlushInstructionCache', 'BOOL',[
1030
1030
  ["HANDLE","hProcess","in"],
1031
1031
  ["PBLOB","lpBaseAddress","in"],
1032
1032
  ["DWORD","dwSize","in"],
1033
1033
  ])
1034
1034
 
1035
- railgun.add_function('kernel32', 'FlushViewOfFile', 'BOOL',[
1035
+ dll.add_function( 'FlushViewOfFile', 'BOOL',[
1036
1036
  ["PBLOB","lpBaseAddress","in"],
1037
1037
  ["DWORD","dwNumberOfBytesToFlush","in"],
1038
1038
  ])
1039
1039
 
1040
- railgun.add_function('kernel32', 'FreeEnvironmentStringsA', 'BOOL',[
1040
+ dll.add_function( 'FreeEnvironmentStringsA', 'BOOL',[
1041
1041
  ["PBLOB","param0","in"],
1042
1042
  ])
1043
1043
 
1044
- railgun.add_function('kernel32', 'FreeEnvironmentStringsW', 'BOOL',[
1044
+ dll.add_function( 'FreeEnvironmentStringsW', 'BOOL',[
1045
1045
  ["PBLOB","param0","in"],
1046
1046
  ])
1047
1047
 
1048
- railgun.add_function('kernel32', 'FreeLibrary', 'BOOL',[
1048
+ dll.add_function( 'FreeLibrary', 'BOOL',[
1049
1049
  ["HANDLE","hLibModule","in"],
1050
1050
  ])
1051
1051
 
1052
- railgun.add_function('kernel32', 'FreeLibraryAndExitThread', 'VOID',[
1052
+ dll.add_function( 'FreeLibraryAndExitThread', 'VOID',[
1053
1053
  ["HANDLE","hLibModule","in"],
1054
1054
  ["DWORD","dwExitCode","in"],
1055
1055
  ])
1056
1056
 
1057
- railgun.add_function('kernel32', 'FreeResource', 'BOOL',[
1057
+ dll.add_function( 'FreeResource', 'BOOL',[
1058
1058
  ["HANDLE","hResData","in"],
1059
1059
  ])
1060
1060
 
1061
- railgun.add_function('kernel32', 'FreeUserPhysicalPages', 'BOOL',[
1061
+ dll.add_function( 'FreeUserPhysicalPages', 'BOOL',[
1062
1062
  ["HANDLE","hProcess","in"],
1063
1063
  ["PBLOB","NumberOfPages","inout"],
1064
1064
  ["PBLOB","PageArray","in"],
1065
1065
  ])
1066
1066
 
1067
- railgun.add_function('kernel32', 'GetAtomNameA', 'DWORD',[
1067
+ dll.add_function( 'GetAtomNameA', 'DWORD',[
1068
1068
  ["WORD","nAtom","in"],
1069
1069
  ["PCHAR","lpBuffer","out"],
1070
1070
  ["DWORD","nSize","in"],
1071
1071
  ])
1072
1072
 
1073
- railgun.add_function('kernel32', 'GetAtomNameW', 'DWORD',[
1073
+ dll.add_function( 'GetAtomNameW', 'DWORD',[
1074
1074
  ["WORD","nAtom","in"],
1075
1075
  ["PWCHAR","lpBuffer","out"],
1076
1076
  ["DWORD","nSize","in"],
1077
1077
  ])
1078
1078
 
1079
- railgun.add_function('kernel32', 'GetBinaryTypeA', 'BOOL',[
1079
+ dll.add_function( 'GetBinaryTypeA', 'BOOL',[
1080
1080
  ["PCHAR","lpApplicationName","in"],
1081
1081
  ["PDWORD","lpBinaryType","out"],
1082
1082
  ])
1083
1083
 
1084
- railgun.add_function('kernel32', 'GetBinaryTypeW', 'BOOL',[
1084
+ dll.add_function( 'GetBinaryTypeW', 'BOOL',[
1085
1085
  ["PWCHAR","lpApplicationName","in"],
1086
1086
  ["PDWORD","lpBinaryType","out"],
1087
1087
  ])
1088
1088
 
1089
- railgun.add_function('kernel32', 'GetCommConfig', 'BOOL',[
1089
+ dll.add_function( 'GetCommConfig', 'BOOL',[
1090
1090
  ["HANDLE","hCommDev","in"],
1091
1091
  ["PBLOB","lpCC","out"],
1092
1092
  ["PDWORD","lpdwSize","inout"],
1093
1093
  ])
1094
1094
 
1095
- railgun.add_function('kernel32', 'GetCommMask', 'BOOL',[
1095
+ dll.add_function( 'GetCommMask', 'BOOL',[
1096
1096
  ["HANDLE","hFile","in"],
1097
1097
  ["PDWORD","lpEvtMask","out"],
1098
1098
  ])
1099
1099
 
1100
- railgun.add_function('kernel32', 'GetCommModemStatus', 'BOOL',[
1100
+ dll.add_function( 'GetCommModemStatus', 'BOOL',[
1101
1101
  ["HANDLE","hFile","in"],
1102
1102
  ["PDWORD","lpModemStat","out"],
1103
1103
  ])
1104
1104
 
1105
- railgun.add_function('kernel32', 'GetCommProperties', 'BOOL',[
1105
+ dll.add_function( 'GetCommProperties', 'BOOL',[
1106
1106
  ["HANDLE","hFile","in"],
1107
1107
  ["PBLOB","lpCommProp","out"],
1108
1108
  ])
1109
1109
 
1110
- railgun.add_function('kernel32', 'GetCommState', 'BOOL',[
1110
+ dll.add_function( 'GetCommState', 'BOOL',[
1111
1111
  ["HANDLE","hFile","in"],
1112
1112
  ["PBLOB","lpDCB","out"],
1113
1113
  ])
1114
1114
 
1115
- railgun.add_function('kernel32', 'GetCommTimeouts', 'BOOL',[
1115
+ dll.add_function( 'GetCommTimeouts', 'BOOL',[
1116
1116
  ["HANDLE","hFile","in"],
1117
1117
  ["PBLOB","lpCommTimeouts","out"],
1118
1118
  ])
1119
1119
 
1120
- #railgun.add_function('kernel32', 'GetCommandLineA', 'PCHAR',[
1120
+ #dll.add_function( 'GetCommandLineA', 'PCHAR',[
1121
1121
  # ])
1122
1122
 
1123
- #railgun.add_function('kernel32', 'GetCommandLineW', 'PWCHAR',[
1123
+ #dll.add_function( 'GetCommandLineW', 'PWCHAR',[
1124
1124
  # ])
1125
1125
 
1126
- railgun.add_function('kernel32', 'GetCompressedFileSizeA', 'DWORD',[
1126
+ dll.add_function( 'GetCompressedFileSizeA', 'DWORD',[
1127
1127
  ["PCHAR","lpFileName","in"],
1128
1128
  ["PDWORD","lpFileSizeHigh","out"],
1129
1129
  ])
1130
1130
 
1131
- railgun.add_function('kernel32', 'GetCompressedFileSizeW', 'DWORD',[
1131
+ dll.add_function( 'GetCompressedFileSizeW', 'DWORD',[
1132
1132
  ["PWCHAR","lpFileName","in"],
1133
1133
  ["PDWORD","lpFileSizeHigh","out"],
1134
1134
  ])
1135
1135
 
1136
- railgun.add_function('kernel32', 'GetComputerNameA', 'BOOL',[
1136
+ dll.add_function( 'GetComputerNameA', 'BOOL',[
1137
1137
  ["PCHAR","lpBuffer","out"],
1138
1138
  ["PDWORD","nSize","inout"],
1139
1139
  ])
1140
1140
 
1141
- railgun.add_function('kernel32', 'GetComputerNameExA', 'BOOL',[
1141
+ dll.add_function( 'GetComputerNameExA', 'BOOL',[
1142
1142
  ["DWORD","NameType","in"],
1143
1143
  ["PCHAR","lpBuffer","out"],
1144
1144
  ["PDWORD","nSize","inout"],
1145
1145
  ])
1146
1146
 
1147
- railgun.add_function('kernel32', 'GetComputerNameExW', 'BOOL',[
1147
+ dll.add_function( 'GetComputerNameExW', 'BOOL',[
1148
1148
  ["DWORD","NameType","in"],
1149
1149
  ["PWCHAR","lpBuffer","out"],
1150
1150
  ["PDWORD","nSize","inout"],
1151
1151
  ])
1152
1152
 
1153
- railgun.add_function('kernel32', 'GetComputerNameW', 'BOOL',[
1153
+ dll.add_function( 'GetComputerNameW', 'BOOL',[
1154
1154
  ["PWCHAR","lpBuffer","out"],
1155
1155
  ["PDWORD","nSize","inout"],
1156
1156
  ])
1157
1157
 
1158
- railgun.add_function('kernel32', 'GetCurrentActCtx', 'BOOL',[
1158
+ dll.add_function( 'GetCurrentActCtx', 'BOOL',[
1159
1159
  ["PDWORD","lphActCtx","out"],
1160
1160
  ])
1161
1161
 
1162
- railgun.add_function('kernel32', 'GetCurrentDirectoryA', 'DWORD',[
1162
+ dll.add_function( 'GetCurrentDirectoryA', 'DWORD',[
1163
1163
  ["DWORD","nBufferLength","in"],
1164
1164
  ["PCHAR","lpBuffer","out"],
1165
1165
  ])
1166
1166
 
1167
- railgun.add_function('kernel32', 'GetCurrentDirectoryW', 'DWORD',[
1167
+ dll.add_function( 'GetCurrentDirectoryW', 'DWORD',[
1168
1168
  ["DWORD","nBufferLength","in"],
1169
1169
  ["PWCHAR","lpBuffer","out"],
1170
1170
  ])
1171
1171
 
1172
- railgun.add_function('kernel32', 'GetCurrentProcess', 'HANDLE',[
1172
+ dll.add_function( 'GetCurrentProcess', 'HANDLE',[
1173
1173
  ])
1174
1174
 
1175
- railgun.add_function('kernel32', 'GetCurrentProcessId', 'DWORD',[
1175
+ dll.add_function( 'GetCurrentProcessId', 'DWORD',[
1176
1176
  ])
1177
1177
 
1178
- railgun.add_function('kernel32', 'GetCurrentProcessorNumber', 'DWORD',[
1178
+ dll.add_function( 'GetCurrentProcessorNumber', 'DWORD',[
1179
1179
  ])
1180
1180
 
1181
- railgun.add_function('kernel32', 'GetCurrentThread', 'HANDLE',[
1181
+ dll.add_function( 'GetCurrentThread', 'HANDLE',[
1182
1182
  ])
1183
1183
 
1184
- railgun.add_function('kernel32', 'GetCurrentThreadId', 'DWORD',[
1184
+ dll.add_function( 'GetCurrentThreadId', 'DWORD',[
1185
1185
  ])
1186
1186
 
1187
- railgun.add_function('kernel32', 'GetDefaultCommConfigA', 'BOOL',[
1187
+ dll.add_function( 'GetDefaultCommConfigA', 'BOOL',[
1188
1188
  ["PCHAR","lpszName","in"],
1189
1189
  ["PBLOB","lpCC","out"],
1190
1190
  ["PDWORD","lpdwSize","inout"],
1191
1191
  ])
1192
1192
 
1193
- railgun.add_function('kernel32', 'GetDefaultCommConfigW', 'BOOL',[
1193
+ dll.add_function( 'GetDefaultCommConfigW', 'BOOL',[
1194
1194
  ["PWCHAR","lpszName","in"],
1195
1195
  ["PBLOB","lpCC","out"],
1196
1196
  ["PDWORD","lpdwSize","inout"],
1197
1197
  ])
1198
1198
 
1199
- railgun.add_function('kernel32', 'GetDevicePowerState', 'BOOL',[
1199
+ dll.add_function( 'GetDevicePowerState', 'BOOL',[
1200
1200
  ["HANDLE","hDevice","in"],
1201
1201
  ["PBLOB","pfOn","out"],
1202
1202
  ])
1203
1203
 
1204
- railgun.add_function('kernel32', 'GetDiskFreeSpaceA', 'BOOL',[
1204
+ dll.add_function( 'GetDiskFreeSpaceA', 'BOOL',[
1205
1205
  ["PCHAR","lpRootPathName","in"],
1206
1206
  ["PDWORD","lpSectorsPerCluster","out"],
1207
1207
  ["PDWORD","lpBytesPerSector","out"],
@@ -1209,21 +1209,21 @@ class Def_kernel32
1209
1209
  ["PDWORD","lpTotalNumberOfClusters","out"],
1210
1210
  ])
1211
1211
 
1212
- railgun.add_function('kernel32', 'GetDiskFreeSpaceExA', 'BOOL',[
1212
+ dll.add_function( 'GetDiskFreeSpaceExA', 'BOOL',[
1213
1213
  ["PCHAR","lpDirectoryName","in"],
1214
1214
  ["PBLOB","lpFreeBytesAvailableToCaller","out"],
1215
1215
  ["PBLOB","lpTotalNumberOfBytes","out"],
1216
1216
  ["PBLOB","lpTotalNumberOfFreeBytes","out"],
1217
1217
  ])
1218
1218
 
1219
- railgun.add_function('kernel32', 'GetDiskFreeSpaceExW', 'BOOL',[
1219
+ dll.add_function( 'GetDiskFreeSpaceExW', 'BOOL',[
1220
1220
  ["PWCHAR","lpDirectoryName","in"],
1221
1221
  ["PBLOB","lpFreeBytesAvailableToCaller","out"],
1222
1222
  ["PBLOB","lpTotalNumberOfBytes","out"],
1223
1223
  ["PBLOB","lpTotalNumberOfFreeBytes","out"],
1224
1224
  ])
1225
1225
 
1226
- railgun.add_function('kernel32', 'GetDiskFreeSpaceW', 'BOOL',[
1226
+ dll.add_function( 'GetDiskFreeSpaceW', 'BOOL',[
1227
1227
  ["PWCHAR","lpRootPathName","in"],
1228
1228
  ["PDWORD","lpSectorsPerCluster","out"],
1229
1229
  ["PDWORD","lpBytesPerSector","out"],
@@ -1231,172 +1231,172 @@ class Def_kernel32
1231
1231
  ["PDWORD","lpTotalNumberOfClusters","out"],
1232
1232
  ])
1233
1233
 
1234
- railgun.add_function('kernel32', 'GetDllDirectoryA', 'DWORD',[
1234
+ dll.add_function( 'GetDllDirectoryA', 'DWORD',[
1235
1235
  ["DWORD","nBufferLength","in"],
1236
1236
  ["PCHAR","lpBuffer","out"],
1237
1237
  ])
1238
1238
 
1239
- railgun.add_function('kernel32', 'GetDllDirectoryW', 'DWORD',[
1239
+ dll.add_function( 'GetDllDirectoryW', 'DWORD',[
1240
1240
  ["DWORD","nBufferLength","in"],
1241
1241
  ["PWCHAR","lpBuffer","out"],
1242
1242
  ])
1243
1243
 
1244
- railgun.add_function('kernel32', 'GetDriveTypeA', 'DWORD',[
1244
+ dll.add_function( 'GetDriveTypeA', 'DWORD',[
1245
1245
  ["PCHAR","lpRootPathName","in"],
1246
1246
  ])
1247
1247
 
1248
- railgun.add_function('kernel32', 'GetDriveTypeW', 'DWORD',[
1248
+ dll.add_function( 'GetDriveTypeW', 'DWORD',[
1249
1249
  ["PWCHAR","lpRootPathName","in"],
1250
1250
  ])
1251
1251
 
1252
- railgun.add_function('kernel32', 'GetEnvironmentStrings', 'LPVOID',[
1252
+ dll.add_function( 'GetEnvironmentStrings', 'LPVOID',[
1253
1253
  ])
1254
1254
 
1255
- railgun.add_function('kernel32', 'GetEnvironmentStringsW', 'LPVOID',[
1255
+ dll.add_function( 'GetEnvironmentStringsW', 'LPVOID',[
1256
1256
  ])
1257
1257
 
1258
- railgun.add_function('kernel32', 'GetEnvironmentVariableA', 'DWORD',[
1258
+ dll.add_function( 'GetEnvironmentVariableA', 'DWORD',[
1259
1259
  ["PCHAR","lpName","in"],
1260
1260
  ["PCHAR","lpBuffer","out"],
1261
1261
  ["DWORD","nSize","in"],
1262
1262
  ])
1263
1263
 
1264
- railgun.add_function('kernel32', 'GetEnvironmentVariableW', 'DWORD',[
1264
+ dll.add_function( 'GetEnvironmentVariableW', 'DWORD',[
1265
1265
  ["PWCHAR","lpName","in"],
1266
1266
  ["PWCHAR","lpBuffer","out"],
1267
1267
  ["DWORD","nSize","in"],
1268
1268
  ])
1269
1269
 
1270
- railgun.add_function('kernel32', 'GetExitCodeProcess', 'BOOL',[
1270
+ dll.add_function( 'GetExitCodeProcess', 'BOOL',[
1271
1271
  ["HANDLE","hProcess","in"],
1272
1272
  ["PDWORD","lpExitCode","out"],
1273
1273
  ])
1274
1274
 
1275
- railgun.add_function('kernel32', 'GetExitCodeThread', 'BOOL',[
1275
+ dll.add_function( 'GetExitCodeThread', 'BOOL',[
1276
1276
  ["HANDLE","hThread","in"],
1277
1277
  ["PDWORD","lpExitCode","out"],
1278
1278
  ])
1279
1279
 
1280
- railgun.add_function('kernel32', 'GetFileAttributesA', 'DWORD',[
1280
+ dll.add_function( 'GetFileAttributesA', 'DWORD',[
1281
1281
  ["PCHAR","lpFileName","in"],
1282
1282
  ])
1283
1283
 
1284
- railgun.add_function('kernel32', 'GetFileAttributesExA', 'BOOL',[
1284
+ dll.add_function( 'GetFileAttributesExA', 'BOOL',[
1285
1285
  ["PCHAR","lpFileName","in"],
1286
1286
  ["PBLOB","fInfoLevelId","in"],
1287
1287
  ["PBLOB","lpFileInformation","out"],
1288
1288
  ])
1289
1289
 
1290
- railgun.add_function('kernel32', 'GetFileAttributesExW', 'BOOL',[
1290
+ dll.add_function( 'GetFileAttributesExW', 'BOOL',[
1291
1291
  ["PWCHAR","lpFileName","in"],
1292
1292
  ["PBLOB","fInfoLevelId","in"],
1293
1293
  ["PBLOB","lpFileInformation","out"],
1294
1294
  ])
1295
1295
 
1296
- railgun.add_function('kernel32', 'GetFileAttributesW', 'DWORD',[
1296
+ dll.add_function( 'GetFileAttributesW', 'DWORD',[
1297
1297
  ["PWCHAR","lpFileName","in"],
1298
1298
  ])
1299
1299
 
1300
- railgun.add_function('kernel32', 'GetFileInformationByHandle', 'BOOL',[
1300
+ dll.add_function( 'GetFileInformationByHandle', 'BOOL',[
1301
1301
  ["HANDLE","hFile","in"],
1302
1302
  ["PBLOB","lpFileInformation","out"],
1303
1303
  ])
1304
1304
 
1305
- railgun.add_function('kernel32', 'GetFileSize', 'DWORD',[
1305
+ dll.add_function( 'GetFileSize', 'DWORD',[
1306
1306
  ["HANDLE","hFile","in"],
1307
1307
  ["PDWORD","lpFileSizeHigh","out"],
1308
1308
  ])
1309
1309
 
1310
- railgun.add_function('kernel32', 'GetFileSizeEx', 'BOOL',[
1310
+ dll.add_function( 'GetFileSizeEx', 'BOOL',[
1311
1311
  ["HANDLE","hFile","in"],
1312
1312
  ["PBLOB","lpFileSize","out"],
1313
1313
  ])
1314
1314
 
1315
- railgun.add_function('kernel32', 'GetFileTime', 'BOOL',[
1315
+ dll.add_function( 'GetFileTime', 'BOOL',[
1316
1316
  ["HANDLE","hFile","in"],
1317
1317
  ["PBLOB","lpCreationTime","out"],
1318
1318
  ["PBLOB","lpLastAccessTime","out"],
1319
1319
  ["PBLOB","lpLastWriteTime","out"],
1320
1320
  ])
1321
1321
 
1322
- railgun.add_function('kernel32', 'GetFileType', 'DWORD',[
1322
+ dll.add_function( 'GetFileType', 'DWORD',[
1323
1323
  ["HANDLE","hFile","in"],
1324
1324
  ])
1325
1325
 
1326
- railgun.add_function('kernel32', 'GetFirmwareEnvironmentVariableA', 'DWORD',[
1326
+ dll.add_function( 'GetFirmwareEnvironmentVariableA', 'DWORD',[
1327
1327
  ["PCHAR","lpName","in"],
1328
1328
  ["PCHAR","lpGuid","in"],
1329
1329
  ["PBLOB","pBuffer","out"],
1330
1330
  ["DWORD","nSize","in"],
1331
1331
  ])
1332
1332
 
1333
- railgun.add_function('kernel32', 'GetFirmwareEnvironmentVariableW', 'DWORD',[
1333
+ dll.add_function( 'GetFirmwareEnvironmentVariableW', 'DWORD',[
1334
1334
  ["PWCHAR","lpName","in"],
1335
1335
  ["PWCHAR","lpGuid","in"],
1336
1336
  ["PBLOB","pBuffer","out"],
1337
1337
  ["DWORD","nSize","in"],
1338
1338
  ])
1339
1339
 
1340
- railgun.add_function('kernel32', 'GetFullPathNameA', 'DWORD',[
1340
+ dll.add_function( 'GetFullPathNameA', 'DWORD',[
1341
1341
  ["PCHAR","lpFileName","in"],
1342
1342
  ["DWORD","nBufferLength","in"],
1343
1343
  ["PCHAR","lpBuffer","out"],
1344
1344
  ["PBLOB","lpFilePart","out"],
1345
1345
  ])
1346
1346
 
1347
- railgun.add_function('kernel32', 'GetFullPathNameW', 'DWORD',[
1347
+ dll.add_function( 'GetFullPathNameW', 'DWORD',[
1348
1348
  ["PWCHAR","lpFileName","in"],
1349
1349
  ["DWORD","nBufferLength","in"],
1350
1350
  ["PWCHAR","lpBuffer","out"],
1351
1351
  ["PBLOB","lpFilePart","out"],
1352
1352
  ])
1353
1353
 
1354
- railgun.add_function('kernel32', 'GetHandleInformation', 'BOOL',[
1354
+ dll.add_function( 'GetHandleInformation', 'BOOL',[
1355
1355
  ["HANDLE","hObject","in"],
1356
1356
  ["PDWORD","lpdwFlags","out"],
1357
1357
  ])
1358
1358
 
1359
- railgun.add_function('kernel32', 'GetLargePageMinimum', 'DWORD',[
1359
+ dll.add_function( 'GetLargePageMinimum', 'DWORD',[
1360
1360
  ])
1361
1361
 
1362
- railgun.add_function('kernel32', 'GetLastError', 'DWORD',[
1362
+ dll.add_function( 'GetLastError', 'DWORD',[
1363
1363
  ])
1364
1364
 
1365
- railgun.add_function('kernel32', 'GetLocalTime', 'VOID',[
1365
+ dll.add_function( 'GetLocalTime', 'VOID',[
1366
1366
  ["PBLOB","lpSystemTime","out"],
1367
1367
  ])
1368
1368
 
1369
- railgun.add_function('kernel32', 'GetLogicalDriveStringsA', 'DWORD',[
1369
+ dll.add_function( 'GetLogicalDriveStringsA', 'DWORD',[
1370
1370
  ["DWORD","nBufferLength","in"],
1371
1371
  ["PCHAR","lpBuffer","out"],
1372
1372
  ])
1373
1373
 
1374
- railgun.add_function('kernel32', 'GetLogicalDriveStringsW', 'DWORD',[
1374
+ dll.add_function( 'GetLogicalDriveStringsW', 'DWORD',[
1375
1375
  ["DWORD","nBufferLength","in"],
1376
1376
  ["PWCHAR","lpBuffer","out"],
1377
1377
  ])
1378
1378
 
1379
- railgun.add_function('kernel32', 'GetLogicalDrives', 'DWORD',[
1379
+ dll.add_function( 'GetLogicalDrives', 'DWORD',[
1380
1380
  ])
1381
1381
 
1382
- railgun.add_function('kernel32', 'GetLogicalProcessorInformation', 'BOOL',[
1382
+ dll.add_function( 'GetLogicalProcessorInformation', 'BOOL',[
1383
1383
  ["PBLOB","Buffer","out"],
1384
1384
  ["PDWORD","ReturnedLength","inout"],
1385
1385
  ])
1386
1386
 
1387
- railgun.add_function('kernel32', 'GetLongPathNameA', 'DWORD',[
1387
+ dll.add_function( 'GetLongPathNameA', 'DWORD',[
1388
1388
  ["PCHAR","lpszShortPath","in"],
1389
1389
  ["PCHAR","lpszLongPath","out"],
1390
1390
  ["DWORD","cchBuffer","in"],
1391
1391
  ])
1392
1392
 
1393
- railgun.add_function('kernel32', 'GetLongPathNameW', 'DWORD',[
1393
+ dll.add_function( 'GetLongPathNameW', 'DWORD',[
1394
1394
  ["PWCHAR","lpszShortPath","in"],
1395
1395
  ["PWCHAR","lpszLongPath","out"],
1396
1396
  ["DWORD","cchBuffer","in"],
1397
1397
  ])
1398
1398
 
1399
- railgun.add_function('kernel32', 'GetMailslotInfo', 'BOOL',[
1399
+ dll.add_function( 'GetMailslotInfo', 'BOOL',[
1400
1400
  ["HANDLE","hMailslot","in"],
1401
1401
  ["PDWORD","lpMaxMessageSize","out"],
1402
1402
  ["PDWORD","lpNextSize","out"],
@@ -1404,39 +1404,39 @@ class Def_kernel32
1404
1404
  ["PDWORD","lpReadTimeout","out"],
1405
1405
  ])
1406
1406
 
1407
- railgun.add_function('kernel32', 'GetModuleFileNameA', 'DWORD',[
1407
+ dll.add_function( 'GetModuleFileNameA', 'DWORD',[
1408
1408
  ["HANDLE","hModule","in"],
1409
1409
  ["PBLOB","lpFilename","out"],
1410
1410
  ["DWORD","nSize","in"],
1411
1411
  ])
1412
1412
 
1413
- railgun.add_function('kernel32', 'GetModuleFileNameW', 'DWORD',[
1413
+ dll.add_function( 'GetModuleFileNameW', 'DWORD',[
1414
1414
  ["HANDLE","hModule","in"],
1415
1415
  ["PBLOB","lpFilename","out"],
1416
1416
  ["DWORD","nSize","in"],
1417
1417
  ])
1418
1418
 
1419
- railgun.add_function('kernel32', 'GetModuleHandleA', 'DWORD',[
1419
+ dll.add_function( 'GetModuleHandleA', 'DWORD',[
1420
1420
  ["PCHAR","lpModuleName","in"],
1421
1421
  ])
1422
1422
 
1423
- railgun.add_function('kernel32', 'GetModuleHandleExA', 'BOOL',[
1423
+ dll.add_function( 'GetModuleHandleExA', 'BOOL',[
1424
1424
  ["DWORD","dwFlags","in"],
1425
1425
  ["PCHAR","lpModuleName","in"],
1426
1426
  ["PDWORD","phModule","out"],
1427
1427
  ])
1428
1428
 
1429
- railgun.add_function('kernel32', 'GetModuleHandleExW', 'BOOL',[
1429
+ dll.add_function( 'GetModuleHandleExW', 'BOOL',[
1430
1430
  ["DWORD","dwFlags","in"],
1431
1431
  ["PWCHAR","lpModuleName","in"],
1432
1432
  ["PDWORD","phModule","out"],
1433
1433
  ])
1434
1434
 
1435
- railgun.add_function('kernel32', 'GetModuleHandleW', 'DWORD',[
1435
+ dll.add_function( 'GetModuleHandleW', 'DWORD',[
1436
1436
  ["PWCHAR","lpModuleName","in"],
1437
1437
  ])
1438
1438
 
1439
- railgun.add_function('kernel32', 'GetNamedPipeHandleStateA', 'BOOL',[
1439
+ dll.add_function( 'GetNamedPipeHandleStateA', 'BOOL',[
1440
1440
  ["HANDLE","hNamedPipe","in"],
1441
1441
  ["PDWORD","lpState","out"],
1442
1442
  ["PDWORD","lpCurInstances","out"],
@@ -1446,7 +1446,7 @@ class Def_kernel32
1446
1446
  ["DWORD","nMaxUserNameSize","in"],
1447
1447
  ])
1448
1448
 
1449
- railgun.add_function('kernel32', 'GetNamedPipeHandleStateW', 'BOOL',[
1449
+ dll.add_function( 'GetNamedPipeHandleStateW', 'BOOL',[
1450
1450
  ["HANDLE","hNamedPipe","in"],
1451
1451
  ["PDWORD","lpState","out"],
1452
1452
  ["PDWORD","lpCurInstances","out"],
@@ -1456,7 +1456,7 @@ class Def_kernel32
1456
1456
  ["DWORD","nMaxUserNameSize","in"],
1457
1457
  ])
1458
1458
 
1459
- railgun.add_function('kernel32', 'GetNamedPipeInfo', 'BOOL',[
1459
+ dll.add_function( 'GetNamedPipeInfo', 'BOOL',[
1460
1460
  ["HANDLE","hNamedPipe","in"],
1461
1461
  ["PDWORD","lpFlags","out"],
1462
1462
  ["PDWORD","lpOutBufferSize","out"],
@@ -1464,81 +1464,81 @@ class Def_kernel32
1464
1464
  ["PDWORD","lpMaxInstances","out"],
1465
1465
  ])
1466
1466
 
1467
- railgun.add_function('kernel32', 'GetNativeSystemInfo', 'VOID',[
1467
+ dll.add_function( 'GetNativeSystemInfo', 'VOID',[
1468
1468
  ["PBLOB","lpSystemInfo","out"],
1469
1469
  ])
1470
1470
 
1471
- railgun.add_function('kernel32', 'GetNumaAvailableMemoryNode', 'BOOL',[
1471
+ dll.add_function( 'GetNumaAvailableMemoryNode', 'BOOL',[
1472
1472
  ["BYTE","Node","in"],
1473
1473
  ["PBLOB","AvailableBytes","out"],
1474
1474
  ])
1475
1475
 
1476
- railgun.add_function('kernel32', 'GetNumaHighestNodeNumber', 'BOOL',[
1476
+ dll.add_function( 'GetNumaHighestNodeNumber', 'BOOL',[
1477
1477
  ["PDWORD","HighestNodeNumber","out"],
1478
1478
  ])
1479
1479
 
1480
- railgun.add_function('kernel32', 'GetNumaNodeProcessorMask', 'BOOL',[
1480
+ dll.add_function( 'GetNumaNodeProcessorMask', 'BOOL',[
1481
1481
  ["BYTE","Node","in"],
1482
1482
  ["PBLOB","ProcessorMask","out"],
1483
1483
  ])
1484
1484
 
1485
- railgun.add_function('kernel32', 'GetNumaProcessorNode', 'BOOL',[
1485
+ dll.add_function( 'GetNumaProcessorNode', 'BOOL',[
1486
1486
  ["BYTE","Processor","in"],
1487
1487
  ["PBLOB","NodeNumber","out"],
1488
1488
  ])
1489
1489
 
1490
- railgun.add_function('kernel32', 'GetOverlappedResult', 'BOOL',[
1490
+ dll.add_function( 'GetOverlappedResult', 'BOOL',[
1491
1491
  ["HANDLE","hFile","in"],
1492
1492
  ["PBLOB","lpOverlapped","in"],
1493
1493
  ["PDWORD","lpNumberOfBytesTransferred","out"],
1494
1494
  ["BOOL","bWait","in"],
1495
1495
  ])
1496
1496
 
1497
- railgun.add_function('kernel32', 'GetPriorityClass', 'DWORD',[
1497
+ dll.add_function( 'GetPriorityClass', 'DWORD',[
1498
1498
  ["HANDLE","hProcess","in"],
1499
1499
  ])
1500
1500
 
1501
- railgun.add_function('kernel32', 'GetPrivateProfileIntA', 'DWORD',[
1501
+ dll.add_function( 'GetPrivateProfileIntA', 'DWORD',[
1502
1502
  ["PCHAR","lpAppName","in"],
1503
1503
  ["PCHAR","lpKeyName","in"],
1504
1504
  ["DWORD","nDefault","in"],
1505
1505
  ["PCHAR","lpFileName","in"],
1506
1506
  ])
1507
1507
 
1508
- railgun.add_function('kernel32', 'GetPrivateProfileIntW', 'DWORD',[
1508
+ dll.add_function( 'GetPrivateProfileIntW', 'DWORD',[
1509
1509
  ["PWCHAR","lpAppName","in"],
1510
1510
  ["PWCHAR","lpKeyName","in"],
1511
1511
  ["DWORD","nDefault","in"],
1512
1512
  ["PWCHAR","lpFileName","in"],
1513
1513
  ])
1514
1514
 
1515
- railgun.add_function('kernel32', 'GetPrivateProfileSectionA', 'DWORD',[
1515
+ dll.add_function( 'GetPrivateProfileSectionA', 'DWORD',[
1516
1516
  ["PCHAR","lpAppName","in"],
1517
1517
  ["PCHAR","lpReturnedString","out"],
1518
1518
  ["DWORD","nSize","in"],
1519
1519
  ["PCHAR","lpFileName","in"],
1520
1520
  ])
1521
1521
 
1522
- railgun.add_function('kernel32', 'GetPrivateProfileSectionNamesA', 'DWORD',[
1522
+ dll.add_function( 'GetPrivateProfileSectionNamesA', 'DWORD',[
1523
1523
  ["PCHAR","lpszReturnBuffer","out"],
1524
1524
  ["DWORD","nSize","in"],
1525
1525
  ["PCHAR","lpFileName","in"],
1526
1526
  ])
1527
1527
 
1528
- railgun.add_function('kernel32', 'GetPrivateProfileSectionNamesW', 'DWORD',[
1528
+ dll.add_function( 'GetPrivateProfileSectionNamesW', 'DWORD',[
1529
1529
  ["PWCHAR","lpszReturnBuffer","out"],
1530
1530
  ["DWORD","nSize","in"],
1531
1531
  ["PWCHAR","lpFileName","in"],
1532
1532
  ])
1533
1533
 
1534
- railgun.add_function('kernel32', 'GetPrivateProfileSectionW', 'DWORD',[
1534
+ dll.add_function( 'GetPrivateProfileSectionW', 'DWORD',[
1535
1535
  ["PWCHAR","lpAppName","in"],
1536
1536
  ["PWCHAR","lpReturnedString","out"],
1537
1537
  ["DWORD","nSize","in"],
1538
1538
  ["PWCHAR","lpFileName","in"],
1539
1539
  ])
1540
1540
 
1541
- railgun.add_function('kernel32', 'GetPrivateProfileStringA', 'DWORD',[
1541
+ dll.add_function( 'GetPrivateProfileStringA', 'DWORD',[
1542
1542
  ["PCHAR","lpAppName","in"],
1543
1543
  ["PCHAR","lpKeyName","in"],
1544
1544
  ["PCHAR","lpDefault","in"],
@@ -1547,7 +1547,7 @@ class Def_kernel32
1547
1547
  ["PCHAR","lpFileName","in"],
1548
1548
  ])
1549
1549
 
1550
- railgun.add_function('kernel32', 'GetPrivateProfileStringW', 'DWORD',[
1550
+ dll.add_function( 'GetPrivateProfileStringW', 'DWORD',[
1551
1551
  ["PWCHAR","lpAppName","in"],
1552
1552
  ["PWCHAR","lpKeyName","in"],
1553
1553
  ["PWCHAR","lpDefault","in"],
@@ -1556,7 +1556,7 @@ class Def_kernel32
1556
1556
  ["PWCHAR","lpFileName","in"],
1557
1557
  ])
1558
1558
 
1559
- railgun.add_function('kernel32', 'GetPrivateProfileStructA', 'BOOL',[
1559
+ dll.add_function( 'GetPrivateProfileStructA', 'BOOL',[
1560
1560
  ["PCHAR","lpszSection","in"],
1561
1561
  ["PCHAR","lpszKey","in"],
1562
1562
  ["PBLOB","lpStruct","out"],
@@ -1564,7 +1564,7 @@ class Def_kernel32
1564
1564
  ["PCHAR","szFile","in"],
1565
1565
  ])
1566
1566
 
1567
- railgun.add_function('kernel32', 'GetPrivateProfileStructW', 'BOOL',[
1567
+ dll.add_function( 'GetPrivateProfileStructW', 'BOOL',[
1568
1568
  ["PWCHAR","lpszSection","in"],
1569
1569
  ["PWCHAR","lpszKey","in"],
1570
1570
  ["PBLOB","lpStruct","out"],
@@ -1572,54 +1572,54 @@ class Def_kernel32
1572
1572
  ["PWCHAR","szFile","in"],
1573
1573
  ])
1574
1574
 
1575
- railgun.add_function('kernel32', 'GetProcAddress', 'LPVOID',[
1575
+ dll.add_function( 'GetProcAddress', 'LPVOID',[
1576
1576
  ["HANDLE","hModule","in"],
1577
1577
  ["PCHAR","lpProcName","in"],
1578
1578
  ])
1579
1579
 
1580
- railgun.add_function('kernel32', 'GetProcessAffinityMask', 'BOOL',[
1580
+ dll.add_function( 'GetProcessAffinityMask', 'BOOL',[
1581
1581
  ["HANDLE","hProcess","in"],
1582
1582
  ["PBLOB","lpProcessAffinityMask","out"],
1583
1583
  ["PBLOB","lpSystemAffinityMask","out"],
1584
1584
  ])
1585
1585
 
1586
- railgun.add_function('kernel32', 'GetProcessHandleCount', 'BOOL',[
1586
+ dll.add_function( 'GetProcessHandleCount', 'BOOL',[
1587
1587
  ["HANDLE","hProcess","in"],
1588
1588
  ["PDWORD","pdwHandleCount","out"],
1589
1589
  ])
1590
1590
 
1591
- railgun.add_function('kernel32', 'GetProcessHeap', 'DWORD',[
1591
+ dll.add_function( 'GetProcessHeap', 'DWORD',[
1592
1592
  ])
1593
1593
 
1594
- railgun.add_function('kernel32', 'GetProcessHeaps', 'DWORD',[
1594
+ dll.add_function( 'GetProcessHeaps', 'DWORD',[
1595
1595
  ["DWORD","NumberOfHeaps","in"],
1596
- ["PDWORD","ProcessHeaps","out"],
1596
+ ["PBLOB","ProcessHeaps","out"],
1597
1597
  ])
1598
1598
 
1599
- railgun.add_function('kernel32', 'GetProcessId', 'DWORD',[
1599
+ dll.add_function( 'GetProcessId', 'DWORD',[
1600
1600
  ["DWORD","Process","in"],
1601
1601
  ])
1602
1602
 
1603
- railgun.add_function('kernel32', 'GetProcessIdOfThread', 'DWORD',[
1603
+ dll.add_function( 'GetProcessIdOfThread', 'DWORD',[
1604
1604
  ["DWORD","Thread","in"],
1605
1605
  ])
1606
1606
 
1607
- railgun.add_function('kernel32', 'GetProcessIoCounters', 'BOOL',[
1607
+ dll.add_function( 'GetProcessIoCounters', 'BOOL',[
1608
1608
  ["HANDLE","hProcess","in"],
1609
1609
  ["PBLOB","lpIoCounters","out"],
1610
1610
  ])
1611
1611
 
1612
- railgun.add_function('kernel32', 'GetProcessPriorityBoost', 'BOOL',[
1612
+ dll.add_function( 'GetProcessPriorityBoost', 'BOOL',[
1613
1613
  ["HANDLE","hProcess","in"],
1614
1614
  ["PBLOB","pDisablePriorityBoost","out"],
1615
1615
  ])
1616
1616
 
1617
- railgun.add_function('kernel32', 'GetProcessShutdownParameters', 'BOOL',[
1617
+ dll.add_function( 'GetProcessShutdownParameters', 'BOOL',[
1618
1618
  ["PDWORD","lpdwLevel","out"],
1619
1619
  ["PDWORD","lpdwFlags","out"],
1620
1620
  ])
1621
1621
 
1622
- railgun.add_function('kernel32', 'GetProcessTimes', 'BOOL',[
1622
+ dll.add_function( 'GetProcessTimes', 'BOOL',[
1623
1623
  ["HANDLE","hProcess","in"],
1624
1624
  ["PBLOB","lpCreationTime","out"],
1625
1625
  ["PBLOB","lpExitTime","out"],
@@ -1627,48 +1627,48 @@ class Def_kernel32
1627
1627
  ["PBLOB","lpUserTime","out"],
1628
1628
  ])
1629
1629
 
1630
- railgun.add_function('kernel32', 'GetProcessVersion', 'DWORD',[
1630
+ dll.add_function( 'GetProcessVersion', 'DWORD',[
1631
1631
  ["DWORD","ProcessId","in"],
1632
1632
  ])
1633
1633
 
1634
- railgun.add_function('kernel32', 'GetProcessWorkingSetSize', 'BOOL',[
1634
+ dll.add_function( 'GetProcessWorkingSetSize', 'BOOL',[
1635
1635
  ["HANDLE","hProcess","in"],
1636
1636
  ["PDWORD","lpMinimumWorkingSetSize","out"],
1637
1637
  ["PDWORD","lpMaximumWorkingSetSize","out"],
1638
1638
  ])
1639
1639
 
1640
- railgun.add_function('kernel32', 'GetProcessWorkingSetSizeEx', 'BOOL',[
1640
+ dll.add_function( 'GetProcessWorkingSetSizeEx', 'BOOL',[
1641
1641
  ["HANDLE","hProcess","in"],
1642
1642
  ["PDWORD","lpMinimumWorkingSetSize","out"],
1643
1643
  ["PDWORD","lpMaximumWorkingSetSize","out"],
1644
1644
  ["PDWORD","Flags","out"],
1645
1645
  ])
1646
1646
 
1647
- railgun.add_function('kernel32', 'GetProfileIntA', 'DWORD',[
1647
+ dll.add_function( 'GetProfileIntA', 'DWORD',[
1648
1648
  ["PCHAR","lpAppName","in"],
1649
1649
  ["PCHAR","lpKeyName","in"],
1650
1650
  ["DWORD","nDefault","in"],
1651
1651
  ])
1652
1652
 
1653
- railgun.add_function('kernel32', 'GetProfileIntW', 'DWORD',[
1653
+ dll.add_function( 'GetProfileIntW', 'DWORD',[
1654
1654
  ["PWCHAR","lpAppName","in"],
1655
1655
  ["PWCHAR","lpKeyName","in"],
1656
1656
  ["DWORD","nDefault","in"],
1657
1657
  ])
1658
1658
 
1659
- railgun.add_function('kernel32', 'GetProfileSectionA', 'DWORD',[
1659
+ dll.add_function( 'GetProfileSectionA', 'DWORD',[
1660
1660
  ["PCHAR","lpAppName","in"],
1661
1661
  ["PCHAR","lpReturnedString","out"],
1662
1662
  ["DWORD","nSize","in"],
1663
1663
  ])
1664
1664
 
1665
- railgun.add_function('kernel32', 'GetProfileSectionW', 'DWORD',[
1665
+ dll.add_function( 'GetProfileSectionW', 'DWORD',[
1666
1666
  ["PWCHAR","lpAppName","in"],
1667
1667
  ["PWCHAR","lpReturnedString","out"],
1668
1668
  ["DWORD","nSize","in"],
1669
1669
  ])
1670
1670
 
1671
- railgun.add_function('kernel32', 'GetProfileStringA', 'DWORD',[
1671
+ dll.add_function( 'GetProfileStringA', 'DWORD',[
1672
1672
  ["PCHAR","lpAppName","in"],
1673
1673
  ["PCHAR","lpKeyName","in"],
1674
1674
  ["PCHAR","lpDefault","in"],
@@ -1676,7 +1676,7 @@ class Def_kernel32
1676
1676
  ["DWORD","nSize","in"],
1677
1677
  ])
1678
1678
 
1679
- railgun.add_function('kernel32', 'GetProfileStringW', 'DWORD',[
1679
+ dll.add_function( 'GetProfileStringW', 'DWORD',[
1680
1680
  ["PWCHAR","lpAppName","in"],
1681
1681
  ["PWCHAR","lpKeyName","in"],
1682
1682
  ["PWCHAR","lpDefault","in"],
@@ -1684,7 +1684,7 @@ class Def_kernel32
1684
1684
  ["DWORD","nSize","in"],
1685
1685
  ])
1686
1686
 
1687
- railgun.add_function('kernel32', 'GetQueuedCompletionStatus', 'BOOL',[
1687
+ dll.add_function( 'GetQueuedCompletionStatus', 'BOOL',[
1688
1688
  ["DWORD","CompletionPort","in"],
1689
1689
  ["PDWORD","lpNumberOfBytesTransferred","out"],
1690
1690
  ["PBLOB","lpCompletionKey","out"],
@@ -1692,114 +1692,114 @@ class Def_kernel32
1692
1692
  ["DWORD","dwMilliseconds","in"],
1693
1693
  ])
1694
1694
 
1695
- railgun.add_function('kernel32', 'GetShortPathNameA', 'DWORD',[
1695
+ dll.add_function( 'GetShortPathNameA', 'DWORD',[
1696
1696
  ["PCHAR","lpszLongPath","in"],
1697
1697
  ["PCHAR","lpszShortPath","out"],
1698
1698
  ["DWORD","cchBuffer","in"],
1699
1699
  ])
1700
1700
 
1701
- railgun.add_function('kernel32', 'GetShortPathNameW', 'DWORD',[
1701
+ dll.add_function( 'GetShortPathNameW', 'DWORD',[
1702
1702
  ["PWCHAR","lpszLongPath","in"],
1703
1703
  ["PWCHAR","lpszShortPath","out"],
1704
1704
  ["DWORD","cchBuffer","in"],
1705
1705
  ])
1706
1706
 
1707
- railgun.add_function('kernel32', 'GetStartupInfoA', 'VOID',[
1707
+ dll.add_function( 'GetStartupInfoA', 'VOID',[
1708
1708
  ["PBLOB","lpStartupInfo","out"],
1709
1709
  ])
1710
1710
 
1711
- railgun.add_function('kernel32', 'GetStartupInfoW', 'VOID',[
1711
+ dll.add_function( 'GetStartupInfoW', 'VOID',[
1712
1712
  ["PBLOB","lpStartupInfo","out"],
1713
1713
  ])
1714
1714
 
1715
- railgun.add_function('kernel32', 'GetStdHandle', 'DWORD',[
1715
+ dll.add_function( 'GetStdHandle', 'DWORD',[
1716
1716
  ["DWORD","nStdHandle","in"],
1717
1717
  ])
1718
1718
 
1719
- railgun.add_function('kernel32', 'GetSystemDirectoryA', 'DWORD',[
1719
+ dll.add_function( 'GetSystemDirectoryA', 'DWORD',[
1720
1720
  ["PCHAR","lpBuffer","out"],
1721
1721
  ["DWORD","uSize","in"],
1722
1722
  ])
1723
1723
 
1724
- railgun.add_function('kernel32', 'GetSystemDirectoryW', 'DWORD',[
1724
+ dll.add_function( 'GetSystemDirectoryW', 'DWORD',[
1725
1725
  ["PWCHAR","lpBuffer","out"],
1726
1726
  ["DWORD","uSize","in"],
1727
1727
  ])
1728
1728
 
1729
- railgun.add_function('kernel32', 'GetSystemFileCacheSize', 'BOOL',[
1729
+ dll.add_function( 'GetSystemFileCacheSize', 'BOOL',[
1730
1730
  ["PDWORD","lpMinimumFileCacheSize","out"],
1731
1731
  ["PDWORD","lpMaximumFileCacheSize","out"],
1732
1732
  ["PDWORD","lpFlags","out"],
1733
1733
  ])
1734
1734
 
1735
- railgun.add_function('kernel32', 'GetSystemFirmwareTable', 'DWORD',[
1735
+ dll.add_function( 'GetSystemFirmwareTable', 'DWORD',[
1736
1736
  ["DWORD","FirmwareTableProviderSignature","in"],
1737
1737
  ["DWORD","FirmwareTableID","in"],
1738
1738
  ["PBLOB","pFirmwareTableBuffer","out"],
1739
1739
  ["DWORD","BufferSize","in"],
1740
1740
  ])
1741
1741
 
1742
- railgun.add_function('kernel32', 'GetSystemInfo', 'VOID',[
1742
+ dll.add_function( 'GetSystemInfo', 'VOID',[
1743
1743
  ["PBLOB","lpSystemInfo","out"],
1744
1744
  ])
1745
1745
 
1746
- railgun.add_function('kernel32', 'GetSystemPowerStatus', 'BOOL',[
1746
+ dll.add_function( 'GetSystemPowerStatus', 'BOOL',[
1747
1747
  ["PBLOB","lpSystemPowerStatus","out"],
1748
1748
  ])
1749
1749
 
1750
- railgun.add_function('kernel32', 'GetSystemRegistryQuota', 'BOOL',[
1750
+ dll.add_function( 'GetSystemRegistryQuota', 'BOOL',[
1751
1751
  ["PDWORD","pdwQuotaAllowed","out"],
1752
1752
  ["PDWORD","pdwQuotaUsed","out"],
1753
1753
  ])
1754
1754
 
1755
- railgun.add_function('kernel32', 'GetSystemTime', 'VOID',[
1755
+ dll.add_function( 'GetSystemTime', 'VOID',[
1756
1756
  ["PBLOB","lpSystemTime","out"],
1757
1757
  ])
1758
1758
 
1759
- railgun.add_function('kernel32', 'GetSystemTimeAdjustment', 'BOOL',[
1759
+ dll.add_function( 'GetSystemTimeAdjustment', 'BOOL',[
1760
1760
  ["PDWORD","lpTimeAdjustment","out"],
1761
1761
  ["PDWORD","lpTimeIncrement","out"],
1762
1762
  ["PBLOB","lpTimeAdjustmentDisabled","out"],
1763
1763
  ])
1764
1764
 
1765
- railgun.add_function('kernel32', 'GetSystemTimeAsFileTime', 'VOID',[
1765
+ dll.add_function( 'GetSystemTimeAsFileTime', 'VOID',[
1766
1766
  ["PBLOB","lpSystemTimeAsFileTime","out"],
1767
1767
  ])
1768
1768
 
1769
- railgun.add_function('kernel32', 'GetSystemTimes', 'BOOL',[
1769
+ dll.add_function( 'GetSystemTimes', 'BOOL',[
1770
1770
  ["PBLOB","lpIdleTime","out"],
1771
1771
  ["PBLOB","lpKernelTime","out"],
1772
1772
  ["PBLOB","lpUserTime","out"],
1773
1773
  ])
1774
1774
 
1775
- railgun.add_function('kernel32', 'GetSystemWindowsDirectoryA', 'DWORD',[
1775
+ dll.add_function( 'GetSystemWindowsDirectoryA', 'DWORD',[
1776
1776
  ["PCHAR","lpBuffer","out"],
1777
1777
  ["DWORD","uSize","in"],
1778
1778
  ])
1779
1779
 
1780
- railgun.add_function('kernel32', 'GetSystemWindowsDirectoryW', 'DWORD',[
1780
+ dll.add_function( 'GetSystemWindowsDirectoryW', 'DWORD',[
1781
1781
  ["PWCHAR","lpBuffer","out"],
1782
1782
  ["DWORD","uSize","in"],
1783
1783
  ])
1784
1784
 
1785
- railgun.add_function('kernel32', 'GetSystemWow64DirectoryA', 'DWORD',[
1785
+ dll.add_function( 'GetSystemWow64DirectoryA', 'DWORD',[
1786
1786
  ["PCHAR","lpBuffer","out"],
1787
1787
  ["DWORD","uSize","in"],
1788
1788
  ])
1789
1789
 
1790
- railgun.add_function('kernel32', 'GetSystemWow64DirectoryW', 'DWORD',[
1790
+ dll.add_function( 'GetSystemWow64DirectoryW', 'DWORD',[
1791
1791
  ["PWCHAR","lpBuffer","out"],
1792
1792
  ["DWORD","uSize","in"],
1793
1793
  ])
1794
1794
 
1795
- railgun.add_function('kernel32', 'GetTapeParameters', 'DWORD',[
1795
+ dll.add_function( 'GetTapeParameters', 'DWORD',[
1796
1796
  ["HANDLE","hDevice","in"],
1797
1797
  ["DWORD","dwOperation","in"],
1798
1798
  ["PDWORD","lpdwSize","inout"],
1799
1799
  ["PBLOB","lpTapeInformation","out"],
1800
1800
  ])
1801
1801
 
1802
- railgun.add_function('kernel32', 'GetTapePosition', 'DWORD',[
1802
+ dll.add_function( 'GetTapePosition', 'DWORD',[
1803
1803
  ["HANDLE","hDevice","in"],
1804
1804
  ["DWORD","dwPositionType","in"],
1805
1805
  ["PDWORD","lpdwPartition","out"],
@@ -1807,64 +1807,64 @@ class Def_kernel32
1807
1807
  ["PDWORD","lpdwOffsetHigh","out"],
1808
1808
  ])
1809
1809
 
1810
- railgun.add_function('kernel32', 'GetTapeStatus', 'DWORD',[
1810
+ dll.add_function( 'GetTapeStatus', 'DWORD',[
1811
1811
  ["HANDLE","hDevice","in"],
1812
1812
  ])
1813
1813
 
1814
- railgun.add_function('kernel32', 'GetTempFileNameA', 'DWORD',[
1814
+ dll.add_function( 'GetTempFileNameA', 'DWORD',[
1815
1815
  ["PCHAR","lpPathName","in"],
1816
1816
  ["PCHAR","lpPrefixString","in"],
1817
1817
  ["DWORD","uUnique","in"],
1818
1818
  ["PCHAR","lpTempFileName","out"],
1819
1819
  ])
1820
1820
 
1821
- railgun.add_function('kernel32', 'GetTempFileNameW', 'DWORD',[
1821
+ dll.add_function( 'GetTempFileNameW', 'DWORD',[
1822
1822
  ["PWCHAR","lpPathName","in"],
1823
1823
  ["PWCHAR","lpPrefixString","in"],
1824
1824
  ["DWORD","uUnique","in"],
1825
1825
  ["PWCHAR","lpTempFileName","out"],
1826
1826
  ])
1827
1827
 
1828
- railgun.add_function('kernel32', 'GetTempPathA', 'DWORD',[
1828
+ dll.add_function( 'GetTempPathA', 'DWORD',[
1829
1829
  ["DWORD","nBufferLength","in"],
1830
1830
  ["PCHAR","lpBuffer","out"],
1831
1831
  ])
1832
1832
 
1833
- railgun.add_function('kernel32', 'GetTempPathW', 'DWORD',[
1833
+ dll.add_function( 'GetTempPathW', 'DWORD',[
1834
1834
  ["DWORD","nBufferLength","in"],
1835
1835
  ["PWCHAR","lpBuffer","out"],
1836
1836
  ])
1837
1837
 
1838
- railgun.add_function('kernel32', 'GetThreadContext', 'BOOL',[
1838
+ dll.add_function( 'GetThreadContext', 'BOOL',[
1839
1839
  ["HANDLE","hThread","in"],
1840
1840
  ["PBLOB","lpContext","inout"],
1841
1841
  ])
1842
1842
 
1843
- railgun.add_function('kernel32', 'GetThreadIOPendingFlag', 'BOOL',[
1843
+ dll.add_function( 'GetThreadIOPendingFlag', 'BOOL',[
1844
1844
  ["HANDLE","hThread","in"],
1845
1845
  ["PBLOB","lpIOIsPending","out"],
1846
1846
  ])
1847
1847
 
1848
- railgun.add_function('kernel32', 'GetThreadId', 'DWORD',[
1848
+ dll.add_function( 'GetThreadId', 'DWORD',[
1849
1849
  ["DWORD","Thread","in"],
1850
1850
  ])
1851
1851
 
1852
- railgun.add_function('kernel32', 'GetThreadPriority', 'DWORD',[
1852
+ dll.add_function( 'GetThreadPriority', 'DWORD',[
1853
1853
  ["HANDLE","hThread","in"],
1854
1854
  ])
1855
1855
 
1856
- railgun.add_function('kernel32', 'GetThreadPriorityBoost', 'BOOL',[
1856
+ dll.add_function( 'GetThreadPriorityBoost', 'BOOL',[
1857
1857
  ["HANDLE","hThread","in"],
1858
1858
  ["PBLOB","pDisablePriorityBoost","out"],
1859
1859
  ])
1860
1860
 
1861
- railgun.add_function('kernel32', 'GetThreadSelectorEntry', 'BOOL',[
1861
+ dll.add_function( 'GetThreadSelectorEntry', 'BOOL',[
1862
1862
  ["HANDLE","hThread","in"],
1863
1863
  ["DWORD","dwSelector","in"],
1864
1864
  ["PBLOB","lpSelectorEntry","out"],
1865
1865
  ])
1866
1866
 
1867
- railgun.add_function('kernel32', 'GetThreadTimes', 'BOOL',[
1867
+ dll.add_function( 'GetThreadTimes', 'BOOL',[
1868
1868
  ["HANDLE","hThread","in"],
1869
1869
  ["PBLOB","lpCreationTime","out"],
1870
1870
  ["PBLOB","lpExitTime","out"],
@@ -1872,25 +1872,25 @@ class Def_kernel32
1872
1872
  ["PBLOB","lpUserTime","out"],
1873
1873
  ])
1874
1874
 
1875
- railgun.add_function('kernel32', 'GetTickCount', 'DWORD',[
1875
+ dll.add_function( 'GetTickCount', 'DWORD',[
1876
1876
  ])
1877
1877
 
1878
- railgun.add_function('kernel32', 'GetTimeZoneInformation', 'DWORD',[
1878
+ dll.add_function( 'GetTimeZoneInformation', 'DWORD',[
1879
1879
  ["PBLOB","lpTimeZoneInformation","out"],
1880
1880
  ])
1881
1881
 
1882
- railgun.add_function('kernel32', 'GetVersion', 'DWORD',[
1882
+ dll.add_function( 'GetVersion', 'DWORD',[
1883
1883
  ])
1884
1884
 
1885
- railgun.add_function('kernel32', 'GetVersionExA', 'BOOL',[
1885
+ dll.add_function( 'GetVersionExA', 'BOOL',[
1886
1886
  ["PBLOB","lpVersionInformation","inout"],
1887
1887
  ])
1888
1888
 
1889
- railgun.add_function('kernel32', 'GetVersionExW', 'BOOL',[
1889
+ dll.add_function( 'GetVersionExW', 'BOOL',[
1890
1890
  ["PBLOB","lpVersionInformation","inout"],
1891
1891
  ])
1892
1892
 
1893
- railgun.add_function('kernel32', 'GetVolumeInformationA', 'BOOL',[
1893
+ dll.add_function( 'GetVolumeInformationA', 'BOOL',[
1894
1894
  ["PCHAR","lpRootPathName","in"],
1895
1895
  ["PCHAR","lpVolumeNameBuffer","out"],
1896
1896
  ["DWORD","nVolumeNameSize","in"],
@@ -1901,7 +1901,7 @@ class Def_kernel32
1901
1901
  ["DWORD","nFileSystemNameSize","in"],
1902
1902
  ])
1903
1903
 
1904
- railgun.add_function('kernel32', 'GetVolumeInformationW', 'BOOL',[
1904
+ dll.add_function( 'GetVolumeInformationW', 'BOOL',[
1905
1905
  ["PWCHAR","lpRootPathName","in"],
1906
1906
  ["PWCHAR","lpVolumeNameBuffer","out"],
1907
1907
  ["DWORD","nVolumeNameSize","in"],
@@ -1912,55 +1912,55 @@ class Def_kernel32
1912
1912
  ["DWORD","nFileSystemNameSize","in"],
1913
1913
  ])
1914
1914
 
1915
- railgun.add_function('kernel32', 'GetVolumeNameForVolumeMountPointA', 'BOOL',[
1915
+ dll.add_function( 'GetVolumeNameForVolumeMountPointA', 'BOOL',[
1916
1916
  ["PCHAR","lpszVolumeMountPoint","in"],
1917
1917
  ["PCHAR","lpszVolumeName","out"],
1918
1918
  ["DWORD","cchBufferLength","in"],
1919
1919
  ])
1920
1920
 
1921
- railgun.add_function('kernel32', 'GetVolumeNameForVolumeMountPointW', 'BOOL',[
1921
+ dll.add_function( 'GetVolumeNameForVolumeMountPointW', 'BOOL',[
1922
1922
  ["PWCHAR","lpszVolumeMountPoint","in"],
1923
1923
  ["PWCHAR","lpszVolumeName","out"],
1924
1924
  ["DWORD","cchBufferLength","in"],
1925
1925
  ])
1926
1926
 
1927
- railgun.add_function('kernel32', 'GetVolumePathNameA', 'BOOL',[
1927
+ dll.add_function( 'GetVolumePathNameA', 'BOOL',[
1928
1928
  ["PCHAR","lpszFileName","in"],
1929
1929
  ["PCHAR","lpszVolumePathName","out"],
1930
1930
  ["DWORD","cchBufferLength","in"],
1931
1931
  ])
1932
1932
 
1933
- railgun.add_function('kernel32', 'GetVolumePathNameW', 'BOOL',[
1933
+ dll.add_function( 'GetVolumePathNameW', 'BOOL',[
1934
1934
  ["PWCHAR","lpszFileName","in"],
1935
1935
  ["PWCHAR","lpszVolumePathName","out"],
1936
1936
  ["DWORD","cchBufferLength","in"],
1937
1937
  ])
1938
1938
 
1939
- railgun.add_function('kernel32', 'GetVolumePathNamesForVolumeNameA', 'BOOL',[
1939
+ dll.add_function( 'GetVolumePathNamesForVolumeNameA', 'BOOL',[
1940
1940
  ["PCHAR","lpszVolumeName","in"],
1941
1941
  ["PBLOB","lpszVolumePathNames","out"],
1942
1942
  ["DWORD","cchBufferLength","in"],
1943
1943
  ["PDWORD","lpcchReturnLength","out"],
1944
1944
  ])
1945
1945
 
1946
- railgun.add_function('kernel32', 'GetVolumePathNamesForVolumeNameW', 'BOOL',[
1946
+ dll.add_function( 'GetVolumePathNamesForVolumeNameW', 'BOOL',[
1947
1947
  ["PWCHAR","lpszVolumeName","in"],
1948
1948
  ["PBLOB","lpszVolumePathNames","out"],
1949
1949
  ["DWORD","cchBufferLength","in"],
1950
1950
  ["PDWORD","lpcchReturnLength","out"],
1951
1951
  ])
1952
1952
 
1953
- railgun.add_function('kernel32', 'GetWindowsDirectoryA', 'DWORD',[
1953
+ dll.add_function( 'GetWindowsDirectoryA', 'DWORD',[
1954
1954
  ["PCHAR","lpBuffer","out"],
1955
1955
  ["DWORD","uSize","in"],
1956
1956
  ])
1957
1957
 
1958
- railgun.add_function('kernel32', 'GetWindowsDirectoryW', 'DWORD',[
1958
+ dll.add_function( 'GetWindowsDirectoryW', 'DWORD',[
1959
1959
  ["PWCHAR","lpBuffer","out"],
1960
1960
  ["DWORD","uSize","in"],
1961
1961
  ])
1962
1962
 
1963
- railgun.add_function('kernel32', 'GetWriteWatch', 'DWORD',[
1963
+ dll.add_function( 'GetWriteWatch', 'DWORD',[
1964
1964
  ["DWORD","dwFlags","in"],
1965
1965
  ["PBLOB","lpBaseAddress","in"],
1966
1966
  ["DWORD","dwRegionSize","in"],
@@ -1969,133 +1969,133 @@ class Def_kernel32
1969
1969
  ["PDWORD","lpdwGranularity","out"],
1970
1970
  ])
1971
1971
 
1972
- railgun.add_function('kernel32', 'GlobalAddAtomA', 'WORD',[
1972
+ dll.add_function( 'GlobalAddAtomA', 'WORD',[
1973
1973
  ["PCHAR","lpString","in"],
1974
1974
  ])
1975
1975
 
1976
- railgun.add_function('kernel32', 'GlobalAddAtomW', 'WORD',[
1976
+ dll.add_function( 'GlobalAddAtomW', 'WORD',[
1977
1977
  ["PWCHAR","lpString","in"],
1978
1978
  ])
1979
1979
 
1980
- railgun.add_function('kernel32', 'GlobalAlloc', 'DWORD',[
1980
+ dll.add_function( 'GlobalAlloc', 'DWORD',[
1981
1981
  ["DWORD","uFlags","in"],
1982
1982
  ["DWORD","dwBytes","in"],
1983
1983
  ])
1984
1984
 
1985
- railgun.add_function('kernel32', 'GlobalCompact', 'DWORD',[
1985
+ dll.add_function( 'GlobalCompact', 'DWORD',[
1986
1986
  ["DWORD","dwMinFree","in"],
1987
1987
  ])
1988
1988
 
1989
- railgun.add_function('kernel32', 'GlobalDeleteAtom', 'WORD',[
1989
+ dll.add_function( 'GlobalDeleteAtom', 'WORD',[
1990
1990
  ["WORD","nAtom","in"],
1991
1991
  ])
1992
1992
 
1993
- railgun.add_function('kernel32', 'GlobalFindAtomA', 'WORD',[
1993
+ dll.add_function( 'GlobalFindAtomA', 'WORD',[
1994
1994
  ["PCHAR","lpString","in"],
1995
1995
  ])
1996
1996
 
1997
- railgun.add_function('kernel32', 'GlobalFindAtomW', 'WORD',[
1997
+ dll.add_function( 'GlobalFindAtomW', 'WORD',[
1998
1998
  ["PWCHAR","lpString","in"],
1999
1999
  ])
2000
2000
 
2001
- railgun.add_function('kernel32', 'GlobalFix', 'VOID',[
2001
+ dll.add_function( 'GlobalFix', 'VOID',[
2002
2002
  ["HANDLE","hMem","in"],
2003
2003
  ])
2004
2004
 
2005
- railgun.add_function('kernel32', 'GlobalFlags', 'DWORD',[
2005
+ dll.add_function( 'GlobalFlags', 'DWORD',[
2006
2006
  ["HANDLE","hMem","in"],
2007
2007
  ])
2008
2008
 
2009
- railgun.add_function('kernel32', 'GlobalFree', 'DWORD',[
2009
+ dll.add_function( 'GlobalFree', 'DWORD',[
2010
2010
  ["HANDLE","hMem","in"],
2011
2011
  ])
2012
2012
 
2013
- railgun.add_function('kernel32', 'GlobalGetAtomNameA', 'DWORD',[
2013
+ dll.add_function( 'GlobalGetAtomNameA', 'DWORD',[
2014
2014
  ["WORD","nAtom","in"],
2015
2015
  ["PCHAR","lpBuffer","out"],
2016
2016
  ["DWORD","nSize","in"],
2017
2017
  ])
2018
2018
 
2019
- railgun.add_function('kernel32', 'GlobalGetAtomNameW', 'DWORD',[
2019
+ dll.add_function( 'GlobalGetAtomNameW', 'DWORD',[
2020
2020
  ["WORD","nAtom","in"],
2021
2021
  ["PWCHAR","lpBuffer","out"],
2022
2022
  ["DWORD","nSize","in"],
2023
2023
  ])
2024
2024
 
2025
- railgun.add_function('kernel32', 'GlobalHandle', 'DWORD',[
2025
+ dll.add_function( 'GlobalHandle', 'DWORD',[
2026
2026
  ["PBLOB","pMem","in"],
2027
2027
  ])
2028
2028
 
2029
- railgun.add_function('kernel32', 'GlobalLock', 'LPVOID',[
2029
+ dll.add_function( 'GlobalLock', 'LPVOID',[
2030
2030
  ["HANDLE","hMem","in"],
2031
2031
  ])
2032
2032
 
2033
- railgun.add_function('kernel32', 'GlobalMemoryStatus', 'VOID',[
2033
+ dll.add_function( 'GlobalMemoryStatus', 'VOID',[
2034
2034
  ["PBLOB","lpBuffer","out"],
2035
2035
  ])
2036
2036
 
2037
- railgun.add_function('kernel32', 'GlobalMemoryStatusEx', 'BOOL',[
2037
+ dll.add_function( 'GlobalMemoryStatusEx', 'BOOL',[
2038
2038
  ["PBLOB","lpBuffer","out"],
2039
2039
  ])
2040
2040
 
2041
- railgun.add_function('kernel32', 'GlobalReAlloc', 'DWORD',[
2041
+ dll.add_function( 'GlobalReAlloc', 'DWORD',[
2042
2042
  ["HANDLE","hMem","in"],
2043
2043
  ["DWORD","dwBytes","in"],
2044
2044
  ["DWORD","uFlags","in"],
2045
2045
  ])
2046
2046
 
2047
- railgun.add_function('kernel32', 'GlobalSize', 'DWORD',[
2047
+ dll.add_function( 'GlobalSize', 'DWORD',[
2048
2048
  ["HANDLE","hMem","in"],
2049
2049
  ])
2050
2050
 
2051
- railgun.add_function('kernel32', 'GlobalUnWire', 'BOOL',[
2051
+ dll.add_function( 'GlobalUnWire', 'BOOL',[
2052
2052
  ["HANDLE","hMem","in"],
2053
2053
  ])
2054
2054
 
2055
- railgun.add_function('kernel32', 'GlobalUnfix', 'VOID',[
2055
+ dll.add_function( 'GlobalUnfix', 'VOID',[
2056
2056
  ["HANDLE","hMem","in"],
2057
2057
  ])
2058
2058
 
2059
- railgun.add_function('kernel32', 'GlobalUnlock', 'BOOL',[
2059
+ dll.add_function( 'GlobalUnlock', 'BOOL',[
2060
2060
  ["HANDLE","hMem","in"],
2061
2061
  ])
2062
2062
 
2063
- railgun.add_function('kernel32', 'GlobalWire', 'LPVOID',[
2063
+ dll.add_function( 'GlobalWire', 'LPVOID',[
2064
2064
  ["HANDLE","hMem","in"],
2065
2065
  ])
2066
2066
 
2067
- railgun.add_function('kernel32', 'HeapAlloc', 'LPVOID',[
2067
+ dll.add_function( 'HeapAlloc', 'LPVOID',[
2068
2068
  ["HANDLE","hHeap","in"],
2069
2069
  ["DWORD","dwFlags","in"],
2070
2070
  ["DWORD","dwBytes","in"],
2071
2071
  ])
2072
2072
 
2073
- railgun.add_function('kernel32', 'HeapCompact', 'DWORD',[
2073
+ dll.add_function( 'HeapCompact', 'DWORD',[
2074
2074
  ["HANDLE","hHeap","in"],
2075
2075
  ["DWORD","dwFlags","in"],
2076
2076
  ])
2077
2077
 
2078
- railgun.add_function('kernel32', 'HeapCreate', 'DWORD',[
2078
+ dll.add_function( 'HeapCreate', 'DWORD',[
2079
2079
  ["DWORD","flOptions","in"],
2080
2080
  ["DWORD","dwInitialSize","in"],
2081
2081
  ["DWORD","dwMaximumSize","in"],
2082
2082
  ])
2083
2083
 
2084
- railgun.add_function('kernel32', 'HeapDestroy', 'BOOL',[
2084
+ dll.add_function( 'HeapDestroy', 'BOOL',[
2085
2085
  ["HANDLE","hHeap","in"],
2086
2086
  ])
2087
2087
 
2088
- railgun.add_function('kernel32', 'HeapFree', 'BOOL',[
2088
+ dll.add_function( 'HeapFree', 'BOOL',[
2089
2089
  ["HANDLE","hHeap","inout"],
2090
2090
  ["DWORD","dwFlags","in"],
2091
2091
  ["LPVOID","lpMem","in"],
2092
2092
  ])
2093
2093
 
2094
- railgun.add_function('kernel32', 'HeapLock', 'BOOL',[
2094
+ dll.add_function( 'HeapLock', 'BOOL',[
2095
2095
  ["HANDLE","hHeap","in"],
2096
2096
  ])
2097
2097
 
2098
- railgun.add_function('kernel32', 'HeapQueryInformation', 'BOOL',[
2098
+ dll.add_function( 'HeapQueryInformation', 'BOOL',[
2099
2099
  ["HANDLE","heapHandle","in"],
2100
2100
  ["PDWORD","HeapInformationClass","in"],
2101
2101
  ["PBLOB","HeapInformation","out"],
@@ -2103,238 +2103,238 @@ class Def_kernel32
2103
2103
  ["PDWORD","ReturnLength","out"],
2104
2104
  ])
2105
2105
 
2106
- railgun.add_function('kernel32', 'HeapReAlloc', 'LPVOID',[
2106
+ dll.add_function( 'HeapReAlloc', 'LPVOID',[
2107
2107
  ["HANDLE","hHeap","inout"],
2108
2108
  ["DWORD","dwFlags","in"],
2109
2109
  ["LPVOID","lpMem","in"],
2110
2110
  ["DWORD","dwBytes","in"],
2111
2111
  ])
2112
2112
 
2113
- railgun.add_function('kernel32', 'HeapSetInformation', 'BOOL',[
2113
+ dll.add_function( 'HeapSetInformation', 'BOOL',[
2114
2114
  ["HANDLE","heapHandle","in"],
2115
2115
  ["PDWORD","HeapInformationClass","in"],
2116
2116
  ["PBLOB","HeapInformation","in"],
2117
2117
  ["HANDLE","heapInformationLength","in"],
2118
2118
  ])
2119
2119
 
2120
- railgun.add_function('kernel32', 'HeapSize', 'DWORD',[
2120
+ dll.add_function( 'HeapSize', 'DWORD',[
2121
2121
  ["HANDLE","hHeap","in"],
2122
2122
  ["DWORD","dwFlags","in"],
2123
2123
  ["LPVOID","lpMem","in"],
2124
2124
  ])
2125
2125
 
2126
- railgun.add_function('kernel32', 'HeapUnlock', 'BOOL',[
2126
+ dll.add_function( 'HeapUnlock', 'BOOL',[
2127
2127
  ["HANDLE","hHeap","in"],
2128
2128
  ])
2129
2129
 
2130
- railgun.add_function('kernel32', 'HeapValidate', 'BOOL',[
2130
+ dll.add_function( 'HeapValidate', 'BOOL',[
2131
2131
  ["HANDLE","hHeap","in"],
2132
2132
  ["DWORD","dwFlags","in"],
2133
2133
  ["LPVOID","lpMem","in"],
2134
2134
  ])
2135
2135
 
2136
- railgun.add_function('kernel32', 'HeapWalk', 'BOOL',[
2136
+ dll.add_function( 'HeapWalk', 'BOOL',[
2137
2137
  ["HANDLE","hHeap","in"],
2138
2138
  ["PBLOB","lpEntry","inout"],
2139
2139
  ])
2140
2140
 
2141
- railgun.add_function('kernel32', 'InitAtomTable', 'BOOL',[
2141
+ dll.add_function( 'InitAtomTable', 'BOOL',[
2142
2142
  ["DWORD","nSize","in"],
2143
2143
  ])
2144
2144
 
2145
- railgun.add_function('kernel32', 'InitializeCriticalSection', 'VOID',[
2145
+ dll.add_function( 'InitializeCriticalSection', 'VOID',[
2146
2146
  ["PBLOB","lpCriticalSection","out"],
2147
2147
  ])
2148
2148
 
2149
- railgun.add_function('kernel32', 'InitializeCriticalSectionAndSpinCount', 'BOOL',[
2149
+ dll.add_function( 'InitializeCriticalSectionAndSpinCount', 'BOOL',[
2150
2150
  ["PBLOB","lpCriticalSection","out"],
2151
2151
  ["DWORD","dwSpinCount","in"],
2152
2152
  ])
2153
2153
 
2154
- railgun.add_function('kernel32', 'InitializeSListHead', 'VOID',[
2154
+ dll.add_function( 'InitializeSListHead', 'VOID',[
2155
2155
  ["PBLOB","ListHead","inout"],
2156
2156
  ])
2157
2157
 
2158
- railgun.add_function('kernel32', 'InterlockedCompareExchange', 'DWORD',[
2158
+ dll.add_function( 'InterlockedCompareExchange', 'DWORD',[
2159
2159
  ["PDWORD","Destination","inout"],
2160
2160
  ["DWORD","ExChange","in"],
2161
2161
  ["DWORD","Comperand","in"],
2162
2162
  ])
2163
2163
 
2164
- railgun.add_function('kernel32', 'InterlockedCompareExchange64', 'LPVOID',[
2164
+ dll.add_function( 'InterlockedCompareExchange64', 'LPVOID',[
2165
2165
  ["PBLOB","Destination","inout"],
2166
2166
  ["PBLOB","ExChange","in"],
2167
2167
  ["PBLOB","Comperand","in"],
2168
2168
  ])
2169
2169
 
2170
- railgun.add_function('kernel32', 'InterlockedDecrement', 'DWORD',[
2170
+ dll.add_function( 'InterlockedDecrement', 'DWORD',[
2171
2171
  ["PDWORD","lpAddend","inout"],
2172
2172
  ])
2173
2173
 
2174
- railgun.add_function('kernel32', 'InterlockedExchange', 'DWORD',[
2174
+ dll.add_function( 'InterlockedExchange', 'DWORD',[
2175
2175
  ["PDWORD","Target","inout"],
2176
2176
  ["DWORD","Value","in"],
2177
2177
  ])
2178
2178
 
2179
- railgun.add_function('kernel32', 'InterlockedExchangeAdd', 'DWORD',[
2179
+ dll.add_function( 'InterlockedExchangeAdd', 'DWORD',[
2180
2180
  ["PDWORD","Addend","inout"],
2181
2181
  ["DWORD","Value","in"],
2182
2182
  ])
2183
2183
 
2184
- railgun.add_function('kernel32', 'InterlockedFlushSList', 'LPVOID',[
2184
+ dll.add_function( 'InterlockedFlushSList', 'LPVOID',[
2185
2185
  ["PBLOB","ListHead","inout"],
2186
2186
  ])
2187
2187
 
2188
- railgun.add_function('kernel32', 'InterlockedIncrement', 'DWORD',[
2188
+ dll.add_function( 'InterlockedIncrement', 'DWORD',[
2189
2189
  ["PDWORD","lpAddend","inout"],
2190
2190
  ])
2191
2191
 
2192
- railgun.add_function('kernel32', 'InterlockedPopEntrySList', 'LPVOID',[
2192
+ dll.add_function( 'InterlockedPopEntrySList', 'LPVOID',[
2193
2193
  ["PBLOB","ListHead","inout"],
2194
2194
  ])
2195
2195
 
2196
- railgun.add_function('kernel32', 'InterlockedPushEntrySList', 'LPVOID',[
2196
+ dll.add_function( 'InterlockedPushEntrySList', 'LPVOID',[
2197
2197
  ["PBLOB","ListHead","inout"],
2198
2198
  ["PBLOB","ListEntry","inout"],
2199
2199
  ])
2200
2200
 
2201
- railgun.add_function('kernel32', 'IsBadCodePtr', 'BOOL',[
2201
+ dll.add_function( 'IsBadCodePtr', 'BOOL',[
2202
2202
  ["PBLOB","lpfn","in"],
2203
2203
  ])
2204
2204
 
2205
- railgun.add_function('kernel32', 'IsBadHugeReadPtr', 'BOOL',[
2205
+ dll.add_function( 'IsBadHugeReadPtr', 'BOOL',[
2206
2206
  ["DWORD","ucb","in"],
2207
2207
  ])
2208
2208
 
2209
- railgun.add_function('kernel32', 'IsBadHugeWritePtr', 'BOOL',[
2209
+ dll.add_function( 'IsBadHugeWritePtr', 'BOOL',[
2210
2210
  ["PBLOB","lp","in"],
2211
2211
  ["DWORD","ucb","in"],
2212
2212
  ])
2213
2213
 
2214
- railgun.add_function('kernel32', 'IsBadReadPtr', 'BOOL',[
2214
+ dll.add_function( 'IsBadReadPtr', 'BOOL',[
2215
2215
  ["DWORD","ucb","in"],
2216
2216
  ])
2217
2217
 
2218
- railgun.add_function('kernel32', 'IsBadStringPtrA', 'BOOL',[
2218
+ dll.add_function( 'IsBadStringPtrA', 'BOOL',[
2219
2219
  ["PCHAR","lpsz","in"],
2220
2220
  ["DWORD","ucchMax","in"],
2221
2221
  ])
2222
2222
 
2223
- railgun.add_function('kernel32', 'IsBadStringPtrW', 'BOOL',[
2223
+ dll.add_function( 'IsBadStringPtrW', 'BOOL',[
2224
2224
  ["PWCHAR","lpsz","in"],
2225
2225
  ["DWORD","ucchMax","in"],
2226
2226
  ])
2227
2227
 
2228
- railgun.add_function('kernel32', 'IsBadWritePtr', 'BOOL',[
2228
+ dll.add_function( 'IsBadWritePtr', 'BOOL',[
2229
2229
  ["PBLOB","lp","in"],
2230
2230
  ["DWORD","ucb","in"],
2231
2231
  ])
2232
2232
 
2233
- railgun.add_function('kernel32', 'IsDebuggerPresent', 'BOOL',[
2233
+ dll.add_function( 'IsDebuggerPresent', 'BOOL',[
2234
2234
  ])
2235
2235
 
2236
- railgun.add_function('kernel32', 'IsProcessInJob', 'BOOL',[
2236
+ dll.add_function( 'IsProcessInJob', 'BOOL',[
2237
2237
  ["DWORD","ProcessHandle","in"],
2238
2238
  ["DWORD","JobHandle","in"],
2239
2239
  ["PBLOB","Result","out"],
2240
2240
  ])
2241
2241
 
2242
- railgun.add_function('kernel32', 'IsProcessorFeaturePresent', 'BOOL',[
2242
+ dll.add_function( 'IsProcessorFeaturePresent', 'BOOL',[
2243
2243
  ["DWORD","ProcessorFeature","in"],
2244
2244
  ])
2245
2245
 
2246
- railgun.add_function('kernel32', 'IsSystemResumeAutomatic', 'BOOL',[
2246
+ dll.add_function( 'IsSystemResumeAutomatic', 'BOOL',[
2247
2247
  ])
2248
2248
 
2249
- railgun.add_function('kernel32', 'IsWow64Process', 'BOOL',[
2249
+ dll.add_function( 'IsWow64Process', 'BOOL',[
2250
2250
  ["HANDLE","hProcess","in"],
2251
2251
  ["PBLOB","Wow64Process","out"],
2252
2252
  ])
2253
2253
 
2254
- railgun.add_function('kernel32', 'LeaveCriticalSection', 'VOID',[
2254
+ dll.add_function( 'LeaveCriticalSection', 'VOID',[
2255
2255
  ["PBLOB","lpCriticalSection","inout"],
2256
2256
  ])
2257
2257
 
2258
- railgun.add_function('kernel32', 'LoadLibraryA', 'DWORD',[
2258
+ dll.add_function( 'LoadLibraryA', 'DWORD',[
2259
2259
  ["PCHAR","lpLibFileName","in"],
2260
2260
  ])
2261
2261
 
2262
- railgun.add_function('kernel32', 'LoadLibraryExA', 'DWORD',[
2262
+ dll.add_function( 'LoadLibraryExA', 'DWORD',[
2263
2263
  ["PCHAR","lpLibFileName","in"],
2264
2264
  ["HANDLE","hFile","inout"],
2265
2265
  ["DWORD","dwFlags","in"],
2266
2266
  ])
2267
2267
 
2268
- railgun.add_function('kernel32', 'LoadLibraryExW', 'DWORD',[
2268
+ dll.add_function( 'LoadLibraryExW', 'DWORD',[
2269
2269
  ["PWCHAR","lpLibFileName","in"],
2270
2270
  ["HANDLE","hFile","inout"],
2271
2271
  ["DWORD","dwFlags","in"],
2272
2272
  ])
2273
2273
 
2274
- railgun.add_function('kernel32', 'LoadLibraryW', 'DWORD',[
2274
+ dll.add_function( 'LoadLibraryW', 'DWORD',[
2275
2275
  ["PWCHAR","lpLibFileName","in"],
2276
2276
  ])
2277
2277
 
2278
- railgun.add_function('kernel32', 'LoadModule', 'DWORD',[
2278
+ dll.add_function( 'LoadModule', 'DWORD',[
2279
2279
  ["PCHAR","lpModuleName","in"],
2280
2280
  ["PBLOB","lpParameterBlock","in"],
2281
2281
  ])
2282
2282
 
2283
- railgun.add_function('kernel32', 'LoadResource', 'DWORD',[
2283
+ dll.add_function( 'LoadResource', 'DWORD',[
2284
2284
  ["HANDLE","hModule","in"],
2285
2285
  ["HANDLE","hResInfo","in"],
2286
2286
  ])
2287
2287
 
2288
- railgun.add_function('kernel32', 'LocalAlloc', 'DWORD',[
2288
+ dll.add_function( 'LocalAlloc', 'DWORD',[
2289
2289
  ["DWORD","uFlags","in"],
2290
2290
  ["DWORD","uBytes","in"],
2291
2291
  ])
2292
2292
 
2293
- railgun.add_function('kernel32', 'LocalCompact', 'DWORD',[
2293
+ dll.add_function( 'LocalCompact', 'DWORD',[
2294
2294
  ["DWORD","uMinFree","in"],
2295
2295
  ])
2296
2296
 
2297
- railgun.add_function('kernel32', 'LocalFileTimeToFileTime', 'BOOL',[
2297
+ dll.add_function( 'LocalFileTimeToFileTime', 'BOOL',[
2298
2298
  ["PBLOB","lpLocalFileTime","in"],
2299
2299
  ["PBLOB","lpFileTime","out"],
2300
2300
  ])
2301
2301
 
2302
- railgun.add_function('kernel32', 'LocalFlags', 'DWORD',[
2302
+ dll.add_function( 'LocalFlags', 'DWORD',[
2303
2303
  ["HANDLE","hMem","in"],
2304
2304
  ])
2305
2305
 
2306
- railgun.add_function('kernel32', 'LocalFree', 'DWORD',[
2306
+ dll.add_function( 'LocalFree', 'DWORD',[
2307
2307
  ["HANDLE","hMem","in"],
2308
2308
  ])
2309
2309
 
2310
- railgun.add_function('kernel32', 'LocalHandle', 'DWORD',[
2310
+ dll.add_function( 'LocalHandle', 'DWORD',[
2311
2311
  ["PBLOB","pMem","in"],
2312
2312
  ])
2313
2313
 
2314
- railgun.add_function('kernel32', 'LocalLock', 'LPVOID',[
2314
+ dll.add_function( 'LocalLock', 'LPVOID',[
2315
2315
  ["HANDLE","hMem","in"],
2316
2316
  ])
2317
2317
 
2318
- railgun.add_function('kernel32', 'LocalReAlloc', 'DWORD',[
2318
+ dll.add_function( 'LocalReAlloc', 'DWORD',[
2319
2319
  ["HANDLE","hMem","in"],
2320
2320
  ["DWORD","uBytes","in"],
2321
2321
  ["DWORD","uFlags","in"],
2322
2322
  ])
2323
2323
 
2324
- railgun.add_function('kernel32', 'LocalShrink', 'DWORD',[
2324
+ dll.add_function( 'LocalShrink', 'DWORD',[
2325
2325
  ["HANDLE","hMem","in"],
2326
2326
  ["DWORD","cbNewSize","in"],
2327
2327
  ])
2328
2328
 
2329
- railgun.add_function('kernel32', 'LocalSize', 'DWORD',[
2329
+ dll.add_function( 'LocalSize', 'DWORD',[
2330
2330
  ["HANDLE","hMem","in"],
2331
2331
  ])
2332
2332
 
2333
- railgun.add_function('kernel32', 'LocalUnlock', 'BOOL',[
2333
+ dll.add_function( 'LocalUnlock', 'BOOL',[
2334
2334
  ["HANDLE","hMem","in"],
2335
2335
  ])
2336
2336
 
2337
- railgun.add_function('kernel32', 'LockFile', 'BOOL',[
2337
+ dll.add_function( 'LockFile', 'BOOL',[
2338
2338
  ["HANDLE","hFile","in"],
2339
2339
  ["DWORD","dwFileOffsetLow","in"],
2340
2340
  ["DWORD","dwFileOffsetHigh","in"],
@@ -2342,7 +2342,7 @@ class Def_kernel32
2342
2342
  ["DWORD","nNumberOfBytesToLockHigh","in"],
2343
2343
  ])
2344
2344
 
2345
- railgun.add_function('kernel32', 'LockFileEx', 'BOOL',[
2345
+ dll.add_function( 'LockFileEx', 'BOOL',[
2346
2346
  ["HANDLE","hFile","in"],
2347
2347
  ["DWORD","dwFlags","in"],
2348
2348
  ["DWORD","dwReserved","inout"],
@@ -2351,23 +2351,23 @@ class Def_kernel32
2351
2351
  ["PBLOB","lpOverlapped","inout"],
2352
2352
  ])
2353
2353
 
2354
- railgun.add_function('kernel32', 'LockResource', 'LPVOID',[
2354
+ dll.add_function( 'LockResource', 'LPVOID',[
2355
2355
  ["HANDLE","hResData","in"],
2356
2356
  ])
2357
2357
 
2358
- railgun.add_function('kernel32', 'MapUserPhysicalPages', 'BOOL',[
2358
+ dll.add_function( 'MapUserPhysicalPages', 'BOOL',[
2359
2359
  ["PBLOB","VirtualAddress","in"],
2360
2360
  ["PDWORD","NumberOfPages","in"],
2361
2361
  ["PBLOB","PageArray","in"],
2362
2362
  ])
2363
2363
 
2364
- railgun.add_function('kernel32', 'MapUserPhysicalPagesScatter', 'BOOL',[
2364
+ dll.add_function( 'MapUserPhysicalPagesScatter', 'BOOL',[
2365
2365
  ["PBLOB","VirtualAddresses","in"],
2366
2366
  ["PDWORD","NumberOfPages","in"],
2367
2367
  ["PBLOB","PageArray","in"],
2368
2368
  ])
2369
2369
 
2370
- railgun.add_function('kernel32', 'MapViewOfFile', 'LPVOID',[
2370
+ dll.add_function( 'MapViewOfFile', 'LPVOID',[
2371
2371
  ["HANDLE","hFileMappingObject","in"],
2372
2372
  ["DWORD","dwDesiredAccess","in"],
2373
2373
  ["DWORD","dwFileOffsetHigh","in"],
@@ -2375,7 +2375,7 @@ class Def_kernel32
2375
2375
  ["DWORD","dwNumberOfBytesToMap","in"],
2376
2376
  ])
2377
2377
 
2378
- railgun.add_function('kernel32', 'MapViewOfFileEx', 'LPVOID',[
2378
+ dll.add_function( 'MapViewOfFileEx', 'LPVOID',[
2379
2379
  ["HANDLE","hFileMappingObject","in"],
2380
2380
  ["DWORD","dwDesiredAccess","in"],
2381
2381
  ["DWORD","dwFileOffsetHigh","in"],
@@ -2384,29 +2384,29 @@ class Def_kernel32
2384
2384
  ["PBLOB","lpBaseAddress","in"],
2385
2385
  ])
2386
2386
 
2387
- railgun.add_function('kernel32', 'MoveFileA', 'BOOL',[
2387
+ dll.add_function( 'MoveFileA', 'BOOL',[
2388
2388
  ["PCHAR","lpExistingFileName","in"],
2389
2389
  ["PCHAR","lpNewFileName","in"],
2390
2390
  ])
2391
2391
 
2392
- railgun.add_function('kernel32', 'MoveFileExA', 'BOOL',[
2392
+ dll.add_function( 'MoveFileExA', 'BOOL',[
2393
2393
  ["PCHAR","lpExistingFileName","in"],
2394
2394
  ["PCHAR","lpNewFileName","in"],
2395
2395
  ["DWORD","dwFlags","in"],
2396
2396
  ])
2397
2397
 
2398
- railgun.add_function('kernel32', 'MoveFileExW', 'BOOL',[
2398
+ dll.add_function( 'MoveFileExW', 'BOOL',[
2399
2399
  ["PWCHAR","lpExistingFileName","in"],
2400
2400
  ["PWCHAR","lpNewFileName","in"],
2401
2401
  ["DWORD","dwFlags","in"],
2402
2402
  ])
2403
2403
 
2404
- railgun.add_function('kernel32', 'MoveFileW', 'BOOL',[
2404
+ dll.add_function( 'MoveFileW', 'BOOL',[
2405
2405
  ["PWCHAR","lpExistingFileName","in"],
2406
2406
  ["PWCHAR","lpNewFileName","in"],
2407
2407
  ])
2408
2408
 
2409
- railgun.add_function('kernel32', 'MoveFileWithProgressA', 'BOOL',[
2409
+ dll.add_function( 'MoveFileWithProgressA', 'BOOL',[
2410
2410
  ["PCHAR","lpExistingFileName","in"],
2411
2411
  ["PCHAR","lpNewFileName","in"],
2412
2412
  ["PBLOB","lpProgressRoutine","in"],
@@ -2414,7 +2414,7 @@ class Def_kernel32
2414
2414
  ["DWORD","dwFlags","in"],
2415
2415
  ])
2416
2416
 
2417
- railgun.add_function('kernel32', 'MoveFileWithProgressW', 'BOOL',[
2417
+ dll.add_function( 'MoveFileWithProgressW', 'BOOL',[
2418
2418
  ["PWCHAR","lpExistingFileName","in"],
2419
2419
  ["PWCHAR","lpNewFileName","in"],
2420
2420
  ["PBLOB","lpProgressRoutine","in"],
@@ -2422,119 +2422,119 @@ class Def_kernel32
2422
2422
  ["DWORD","dwFlags","in"],
2423
2423
  ])
2424
2424
 
2425
- railgun.add_function('kernel32', 'MulDiv', 'DWORD',[
2425
+ dll.add_function( 'MulDiv', 'DWORD',[
2426
2426
  ["DWORD","nNumber","in"],
2427
2427
  ["DWORD","nNumerator","in"],
2428
2428
  ["DWORD","nDenominator","in"],
2429
2429
  ])
2430
2430
 
2431
- railgun.add_function('kernel32', 'NeedCurrentDirectoryForExePathA', 'BOOL',[
2431
+ dll.add_function( 'NeedCurrentDirectoryForExePathA', 'BOOL',[
2432
2432
  ["PCHAR","ExeName","in"],
2433
2433
  ])
2434
2434
 
2435
- railgun.add_function('kernel32', 'NeedCurrentDirectoryForExePathW', 'BOOL',[
2435
+ dll.add_function( 'NeedCurrentDirectoryForExePathW', 'BOOL',[
2436
2436
  ["PWCHAR","ExeName","in"],
2437
2437
  ])
2438
2438
 
2439
- railgun.add_function('kernel32', 'OpenEventA', 'DWORD',[
2439
+ dll.add_function( 'OpenEventA', 'DWORD',[
2440
2440
  ["DWORD","dwDesiredAccess","in"],
2441
2441
  ["BOOL","bInheritHandle","in"],
2442
2442
  ["PCHAR","lpName","in"],
2443
2443
  ])
2444
2444
 
2445
- railgun.add_function('kernel32', 'OpenEventW', 'DWORD',[
2445
+ dll.add_function( 'OpenEventW', 'DWORD',[
2446
2446
  ["DWORD","dwDesiredAccess","in"],
2447
2447
  ["BOOL","bInheritHandle","in"],
2448
2448
  ["PWCHAR","lpName","in"],
2449
2449
  ])
2450
2450
 
2451
- railgun.add_function('kernel32', 'OpenFile', 'DWORD',[
2451
+ dll.add_function( 'OpenFile', 'DWORD',[
2452
2452
  ["PCHAR","lpFileName","in"],
2453
2453
  ["PBLOB","lpReOpenBuff","inout"],
2454
2454
  ["DWORD","uStyle","in"],
2455
2455
  ])
2456
2456
 
2457
- railgun.add_function('kernel32', 'OpenFileMappingA', 'DWORD',[
2457
+ dll.add_function( 'OpenFileMappingA', 'DWORD',[
2458
2458
  ["DWORD","dwDesiredAccess","in"],
2459
2459
  ["BOOL","bInheritHandle","in"],
2460
2460
  ["PCHAR","lpName","in"],
2461
2461
  ])
2462
2462
 
2463
- railgun.add_function('kernel32', 'OpenFileMappingW', 'DWORD',[
2463
+ dll.add_function( 'OpenFileMappingW', 'DWORD',[
2464
2464
  ["DWORD","dwDesiredAccess","in"],
2465
2465
  ["BOOL","bInheritHandle","in"],
2466
2466
  ["PWCHAR","lpName","in"],
2467
2467
  ])
2468
2468
 
2469
- railgun.add_function('kernel32', 'OpenJobObjectA', 'DWORD',[
2469
+ dll.add_function( 'OpenJobObjectA', 'DWORD',[
2470
2470
  ["DWORD","dwDesiredAccess","in"],
2471
2471
  ["BOOL","bInheritHandle","in"],
2472
2472
  ["PCHAR","lpName","in"],
2473
2473
  ])
2474
2474
 
2475
- railgun.add_function('kernel32', 'OpenJobObjectW', 'DWORD',[
2475
+ dll.add_function( 'OpenJobObjectW', 'DWORD',[
2476
2476
  ["DWORD","dwDesiredAccess","in"],
2477
2477
  ["BOOL","bInheritHandle","in"],
2478
2478
  ["PWCHAR","lpName","in"],
2479
2479
  ])
2480
2480
 
2481
- railgun.add_function('kernel32', 'OpenMutexA', 'DWORD',[
2481
+ dll.add_function( 'OpenMutexA', 'DWORD',[
2482
2482
  ["DWORD","dwDesiredAccess","in"],
2483
2483
  ["BOOL","bInheritHandle","in"],
2484
2484
  ["PCHAR","lpName","in"],
2485
2485
  ])
2486
2486
 
2487
- railgun.add_function('kernel32', 'OpenMutexW', 'DWORD',[
2487
+ dll.add_function( 'OpenMutexW', 'DWORD',[
2488
2488
  ["DWORD","dwDesiredAccess","in"],
2489
2489
  ["BOOL","bInheritHandle","in"],
2490
2490
  ["PWCHAR","lpName","in"],
2491
2491
  ])
2492
2492
 
2493
- railgun.add_function('kernel32', 'OpenProcess', 'DWORD',[
2493
+ dll.add_function( 'OpenProcess', 'DWORD',[
2494
2494
  ["DWORD","dwDesiredAccess","in"],
2495
2495
  ["BOOL","bInheritHandle","in"],
2496
2496
  ["DWORD","dwProcessId","in"],
2497
2497
  ])
2498
2498
 
2499
- railgun.add_function('kernel32', 'OpenSemaphoreA', 'DWORD',[
2499
+ dll.add_function( 'OpenSemaphoreA', 'DWORD',[
2500
2500
  ["DWORD","dwDesiredAccess","in"],
2501
2501
  ["BOOL","bInheritHandle","in"],
2502
2502
  ["PCHAR","lpName","in"],
2503
2503
  ])
2504
2504
 
2505
- railgun.add_function('kernel32', 'OpenSemaphoreW', 'DWORD',[
2505
+ dll.add_function( 'OpenSemaphoreW', 'DWORD',[
2506
2506
  ["DWORD","dwDesiredAccess","in"],
2507
2507
  ["BOOL","bInheritHandle","in"],
2508
2508
  ["PWCHAR","lpName","in"],
2509
2509
  ])
2510
2510
 
2511
- railgun.add_function('kernel32', 'OpenThread', 'DWORD',[
2511
+ dll.add_function( 'OpenThread', 'DWORD',[
2512
2512
  ["DWORD","dwDesiredAccess","in"],
2513
2513
  ["BOOL","bInheritHandle","in"],
2514
2514
  ["DWORD","dwThreadId","in"],
2515
2515
  ])
2516
2516
 
2517
- railgun.add_function('kernel32', 'OpenWaitableTimerA', 'DWORD',[
2517
+ dll.add_function( 'OpenWaitableTimerA', 'DWORD',[
2518
2518
  ["DWORD","dwDesiredAccess","in"],
2519
2519
  ["BOOL","bInheritHandle","in"],
2520
2520
  ["PCHAR","lpTimerName","in"],
2521
2521
  ])
2522
2522
 
2523
- railgun.add_function('kernel32', 'OpenWaitableTimerW', 'DWORD',[
2523
+ dll.add_function( 'OpenWaitableTimerW', 'DWORD',[
2524
2524
  ["DWORD","dwDesiredAccess","in"],
2525
2525
  ["BOOL","bInheritHandle","in"],
2526
2526
  ["PWCHAR","lpTimerName","in"],
2527
2527
  ])
2528
2528
 
2529
- railgun.add_function('kernel32', 'OutputDebugStringA', 'VOID',[
2529
+ dll.add_function( 'OutputDebugStringA', 'VOID',[
2530
2530
  ["PCHAR","lpOutputString","in"],
2531
2531
  ])
2532
2532
 
2533
- railgun.add_function('kernel32', 'OutputDebugStringW', 'VOID',[
2533
+ dll.add_function( 'OutputDebugStringW', 'VOID',[
2534
2534
  ["PWCHAR","lpOutputString","in"],
2535
2535
  ])
2536
2536
 
2537
- railgun.add_function('kernel32', 'PeekNamedPipe', 'BOOL',[
2537
+ dll.add_function( 'PeekNamedPipe', 'BOOL',[
2538
2538
  ["HANDLE","hNamedPipe","in"],
2539
2539
  ["PBLOB","lpBuffer","out"],
2540
2540
  ["DWORD","nBufferSize","in"],
@@ -2543,34 +2543,34 @@ class Def_kernel32
2543
2543
  ["PDWORD","lpBytesLeftThisMessage","out"],
2544
2544
  ])
2545
2545
 
2546
- railgun.add_function('kernel32', 'PostQueuedCompletionStatus', 'BOOL',[
2546
+ dll.add_function( 'PostQueuedCompletionStatus', 'BOOL',[
2547
2547
  ["DWORD","CompletionPort","in"],
2548
2548
  ["DWORD","dwNumberOfBytesTransferred","in"],
2549
2549
  ["PDWORD","dwCompletionKey","in"],
2550
2550
  ["PBLOB","lpOverlapped","in"],
2551
2551
  ])
2552
2552
 
2553
- railgun.add_function('kernel32', 'PrepareTape', 'DWORD',[
2553
+ dll.add_function( 'PrepareTape', 'DWORD',[
2554
2554
  ["HANDLE","hDevice","in"],
2555
2555
  ["DWORD","dwOperation","in"],
2556
2556
  ["BOOL","bImmediate","in"],
2557
2557
  ])
2558
2558
 
2559
- railgun.add_function('kernel32', 'ProcessIdToSessionId', 'BOOL',[
2559
+ dll.add_function( 'ProcessIdToSessionId', 'BOOL',[
2560
2560
  ["DWORD","dwProcessId","in"],
2561
2561
  ["PDWORD","pSessionId","out"],
2562
2562
  ])
2563
2563
 
2564
- railgun.add_function('kernel32', 'PulseEvent', 'BOOL',[
2564
+ dll.add_function( 'PulseEvent', 'BOOL',[
2565
2565
  ["HANDLE","hEvent","in"],
2566
2566
  ])
2567
2567
 
2568
- railgun.add_function('kernel32', 'PurgeComm', 'BOOL',[
2568
+ dll.add_function( 'PurgeComm', 'BOOL',[
2569
2569
  ["HANDLE","hFile","in"],
2570
2570
  ["DWORD","dwFlags","in"],
2571
2571
  ])
2572
2572
 
2573
- railgun.add_function('kernel32', 'QueryActCtxW', 'BOOL',[
2573
+ dll.add_function( 'QueryActCtxW', 'BOOL',[
2574
2574
  ["DWORD","dwFlags","in"],
2575
2575
  ["HANDLE","hActCtx","in"],
2576
2576
  ["PBLOB","pvSubInstance","in"],
@@ -2580,23 +2580,23 @@ class Def_kernel32
2580
2580
  ["PDWORD","pcbWrittenOrRequired","out"],
2581
2581
  ])
2582
2582
 
2583
- railgun.add_function('kernel32', 'QueryDepthSList', 'WORD',[
2583
+ dll.add_function( 'QueryDepthSList', 'WORD',[
2584
2584
  ["PBLOB","ListHead","in"],
2585
2585
  ])
2586
2586
 
2587
- railgun.add_function('kernel32', 'QueryDosDeviceA', 'DWORD',[
2587
+ dll.add_function( 'QueryDosDeviceA', 'DWORD',[
2588
2588
  ["PCHAR","lpDeviceName","in"],
2589
2589
  ["PCHAR","lpTargetPath","out"],
2590
2590
  ["DWORD","ucchMax","in"],
2591
2591
  ])
2592
2592
 
2593
- railgun.add_function('kernel32', 'QueryDosDeviceW', 'DWORD',[
2593
+ dll.add_function( 'QueryDosDeviceW', 'DWORD',[
2594
2594
  ["PWCHAR","lpDeviceName","in"],
2595
2595
  ["PWCHAR","lpTargetPath","out"],
2596
2596
  ["DWORD","ucchMax","in"],
2597
2597
  ])
2598
2598
 
2599
- railgun.add_function('kernel32', 'QueryInformationJobObject', 'BOOL',[
2599
+ dll.add_function( 'QueryInformationJobObject', 'BOOL',[
2600
2600
  ["HANDLE","hJob","in"],
2601
2601
  ["PBLOB","JobObjectInformationClass","in"],
2602
2602
  ["PBLOB","lpJobObjectInformation","out"],
@@ -2604,46 +2604,46 @@ class Def_kernel32
2604
2604
  ["PDWORD","lpReturnLength","out"],
2605
2605
  ])
2606
2606
 
2607
- railgun.add_function('kernel32', 'QueryMemoryResourceNotification', 'BOOL',[
2607
+ dll.add_function( 'QueryMemoryResourceNotification', 'BOOL',[
2608
2608
  ["DWORD","ResourceNotificationHandle","in"],
2609
2609
  ["PBLOB","ResourceState","out"],
2610
2610
  ])
2611
2611
 
2612
- railgun.add_function('kernel32', 'QueryPerformanceCounter', 'BOOL',[
2612
+ dll.add_function( 'QueryPerformanceCounter', 'BOOL',[
2613
2613
  ["PBLOB","lpPerformanceCount","out"],
2614
2614
  ])
2615
2615
 
2616
- railgun.add_function('kernel32', 'QueryPerformanceFrequency', 'BOOL',[
2616
+ dll.add_function( 'QueryPerformanceFrequency', 'BOOL',[
2617
2617
  ["PBLOB","lpFrequency","out"],
2618
2618
  ])
2619
2619
 
2620
- railgun.add_function('kernel32', 'QueueUserAPC', 'DWORD',[
2620
+ dll.add_function( 'QueueUserAPC', 'DWORD',[
2621
2621
  ["PBLOB","pfnAPC","in"],
2622
2622
  ["HANDLE","hThread","in"],
2623
2623
  ["PDWORD","dwData","in"],
2624
2624
  ])
2625
2625
 
2626
- railgun.add_function('kernel32', 'QueueUserWorkItem', 'BOOL',[
2626
+ dll.add_function( 'QueueUserWorkItem', 'BOOL',[
2627
2627
  ["PBLOB","Function","in"],
2628
2628
  ["PBLOB","Context","in"],
2629
2629
  ["DWORD","Flags","in"],
2630
2630
  ])
2631
2631
 
2632
- railgun.add_function('kernel32', 'RaiseException', 'VOID',[
2632
+ dll.add_function( 'RaiseException', 'VOID',[
2633
2633
  ["DWORD","dwExceptionCode","in"],
2634
2634
  ["DWORD","dwExceptionFlags","in"],
2635
2635
  ["DWORD","nNumberOfArguments","in"],
2636
2636
  ["PBLOB","lpArguments","in"],
2637
2637
  ])
2638
2638
 
2639
- railgun.add_function('kernel32', 'ReOpenFile', 'DWORD',[
2639
+ dll.add_function( 'ReOpenFile', 'DWORD',[
2640
2640
  ["HANDLE","hOriginalFile","in"],
2641
2641
  ["DWORD","dwDesiredAccess","in"],
2642
2642
  ["DWORD","dwShareMode","in"],
2643
2643
  ["DWORD","dwFlagsAndAttributes","in"],
2644
2644
  ])
2645
2645
 
2646
- railgun.add_function('kernel32', 'ReadDirectoryChangesW', 'BOOL',[
2646
+ dll.add_function( 'ReadDirectoryChangesW', 'BOOL',[
2647
2647
  ["HANDLE","hDirectory","in"],
2648
2648
  ["PBLOB","lpBuffer","out"],
2649
2649
  ["DWORD","nBufferLength","in"],
@@ -2654,7 +2654,7 @@ class Def_kernel32
2654
2654
  ["PBLOB","lpCompletionRoutine","in"],
2655
2655
  ])
2656
2656
 
2657
- railgun.add_function('kernel32', 'ReadFile', 'BOOL',[
2657
+ dll.add_function( 'ReadFile', 'BOOL',[
2658
2658
  ["HANDLE","hFile","in"],
2659
2659
  ["PBLOB","lpBuffer","out"],
2660
2660
  ["DWORD","nNumberOfBytesToRead","in"],
@@ -2662,7 +2662,7 @@ class Def_kernel32
2662
2662
  ["PBLOB","lpOverlapped","inout"],
2663
2663
  ])
2664
2664
 
2665
- railgun.add_function('kernel32', 'ReadFileEx', 'BOOL',[
2665
+ dll.add_function( 'ReadFileEx', 'BOOL',[
2666
2666
  ["HANDLE","hFile","in"],
2667
2667
  ["PBLOB","lpBuffer","out"],
2668
2668
  ["DWORD","nNumberOfBytesToRead","in"],
@@ -2670,7 +2670,7 @@ class Def_kernel32
2670
2670
  ["PBLOB","lpCompletionRoutine","in"],
2671
2671
  ])
2672
2672
 
2673
- railgun.add_function('kernel32', 'ReadFileScatter', 'BOOL',[
2673
+ dll.add_function( 'ReadFileScatter', 'BOOL',[
2674
2674
  ["HANDLE","hFile","in"],
2675
2675
  ["PBLOB","aSegmentArray[]","in"],
2676
2676
  ["DWORD","nNumberOfBytesToRead","in"],
@@ -2678,7 +2678,7 @@ class Def_kernel32
2678
2678
  ["PBLOB","lpOverlapped","inout"],
2679
2679
  ])
2680
2680
 
2681
- railgun.add_function('kernel32', 'ReadProcessMemory', 'BOOL',[
2681
+ dll.add_function( 'ReadProcessMemory', 'BOOL',[
2682
2682
  ["HANDLE","hProcess","in"],
2683
2683
  ["PBLOB","lpBaseAddress","in"],
2684
2684
  ["PBLOB","lpBuffer","out"],
@@ -2686,7 +2686,7 @@ class Def_kernel32
2686
2686
  ["PDWORD","lpNumberOfBytesRead","out"],
2687
2687
  ])
2688
2688
 
2689
- railgun.add_function('kernel32', 'RegisterWaitForSingleObject', 'BOOL',[
2689
+ dll.add_function( 'RegisterWaitForSingleObject', 'BOOL',[
2690
2690
  ["PDWORD","phNewWaitObject","out"],
2691
2691
  ["HANDLE","hObject","in"],
2692
2692
  ["PBLOB","Callback","in"],
@@ -2695,7 +2695,7 @@ class Def_kernel32
2695
2695
  ["DWORD","dwFlags","in"],
2696
2696
  ])
2697
2697
 
2698
- railgun.add_function('kernel32', 'RegisterWaitForSingleObjectEx', 'DWORD',[
2698
+ dll.add_function( 'RegisterWaitForSingleObjectEx', 'DWORD',[
2699
2699
  ["HANDLE","hObject","in"],
2700
2700
  ["PBLOB","Callback","in"],
2701
2701
  ["PBLOB","Context","in"],
@@ -2703,37 +2703,37 @@ class Def_kernel32
2703
2703
  ["DWORD","dwFlags","in"],
2704
2704
  ])
2705
2705
 
2706
- railgun.add_function('kernel32', 'ReleaseActCtx', 'VOID',[
2706
+ dll.add_function( 'ReleaseActCtx', 'VOID',[
2707
2707
  ["HANDLE","hActCtx","inout"],
2708
2708
  ])
2709
2709
 
2710
- railgun.add_function('kernel32', 'ReleaseMutex', 'BOOL',[
2710
+ dll.add_function( 'ReleaseMutex', 'BOOL',[
2711
2711
  ["HANDLE","hMutex","in"],
2712
2712
  ])
2713
2713
 
2714
- railgun.add_function('kernel32', 'ReleaseSemaphore', 'BOOL',[
2714
+ dll.add_function( 'ReleaseSemaphore', 'BOOL',[
2715
2715
  ["HANDLE","hSemaphore","in"],
2716
2716
  ["DWORD","lReleaseCount","in"],
2717
2717
  ["PBLOB","lpPreviousCount","out"],
2718
2718
  ])
2719
2719
 
2720
- railgun.add_function('kernel32', 'RemoveDirectoryA', 'BOOL',[
2720
+ dll.add_function( 'RemoveDirectoryA', 'BOOL',[
2721
2721
  ["PCHAR","lpPathName","in"],
2722
2722
  ])
2723
2723
 
2724
- railgun.add_function('kernel32', 'RemoveDirectoryW', 'BOOL',[
2724
+ dll.add_function( 'RemoveDirectoryW', 'BOOL',[
2725
2725
  ["PWCHAR","lpPathName","in"],
2726
2726
  ])
2727
2727
 
2728
- railgun.add_function('kernel32', 'RemoveVectoredContinueHandler', 'DWORD',[
2728
+ dll.add_function( 'RemoveVectoredContinueHandler', 'DWORD',[
2729
2729
  ["PBLOB","Handle","in"],
2730
2730
  ])
2731
2731
 
2732
- railgun.add_function('kernel32', 'RemoveVectoredExceptionHandler', 'DWORD',[
2732
+ dll.add_function( 'RemoveVectoredExceptionHandler', 'DWORD',[
2733
2733
  ["PBLOB","Handle","in"],
2734
2734
  ])
2735
2735
 
2736
- railgun.add_function('kernel32', 'ReplaceFileA', 'BOOL',[
2736
+ dll.add_function( 'ReplaceFileA', 'BOOL',[
2737
2737
  ["PCHAR","lpReplacedFileName","in"],
2738
2738
  ["PCHAR","lpReplacementFileName","in"],
2739
2739
  ["PCHAR","lpBackupFileName","in"],
@@ -2742,7 +2742,7 @@ class Def_kernel32
2742
2742
  ["PBLOB","lpReserved","inout"],
2743
2743
  ])
2744
2744
 
2745
- railgun.add_function('kernel32', 'ReplaceFileW', 'BOOL',[
2745
+ dll.add_function( 'ReplaceFileW', 'BOOL',[
2746
2746
  ["PWCHAR","lpReplacedFileName","in"],
2747
2747
  ["PWCHAR","lpReplacementFileName","in"],
2748
2748
  ["PWCHAR","lpBackupFileName","in"],
@@ -2751,32 +2751,32 @@ class Def_kernel32
2751
2751
  ["PBLOB","lpReserved","inout"],
2752
2752
  ])
2753
2753
 
2754
- railgun.add_function('kernel32', 'RequestDeviceWakeup', 'BOOL',[
2754
+ dll.add_function( 'RequestDeviceWakeup', 'BOOL',[
2755
2755
  ["HANDLE","hDevice","in"],
2756
2756
  ])
2757
2757
 
2758
- railgun.add_function('kernel32', 'RequestWakeupLatency', 'BOOL',[
2758
+ dll.add_function( 'RequestWakeupLatency', 'BOOL',[
2759
2759
  ["PBLOB","latency","in"],
2760
2760
  ])
2761
2761
 
2762
- railgun.add_function('kernel32', 'ResetEvent', 'BOOL',[
2762
+ dll.add_function( 'ResetEvent', 'BOOL',[
2763
2763
  ["HANDLE","hEvent","in"],
2764
2764
  ])
2765
2765
 
2766
- railgun.add_function('kernel32', 'ResetWriteWatch', 'DWORD',[
2766
+ dll.add_function( 'ResetWriteWatch', 'DWORD',[
2767
2767
  ["PBLOB","lpBaseAddress","in"],
2768
2768
  ["DWORD","dwRegionSize","in"],
2769
2769
  ])
2770
2770
 
2771
- railgun.add_function('kernel32', 'RestoreLastError', 'VOID',[
2771
+ dll.add_function( 'RestoreLastError', 'VOID',[
2772
2772
  ["DWORD","dwErrCode","in"],
2773
2773
  ])
2774
2774
 
2775
- railgun.add_function('kernel32', 'ResumeThread', 'DWORD',[
2775
+ dll.add_function( 'ResumeThread', 'DWORD',[
2776
2776
  ["HANDLE","hThread","in"],
2777
2777
  ])
2778
2778
 
2779
- railgun.add_function('kernel32', 'SearchPathA', 'DWORD',[
2779
+ dll.add_function( 'SearchPathA', 'DWORD',[
2780
2780
  ["PCHAR","lpPath","in"],
2781
2781
  ["PCHAR","lpFileName","in"],
2782
2782
  ["PCHAR","lpExtension","in"],
@@ -2785,7 +2785,7 @@ class Def_kernel32
2785
2785
  ["PBLOB","lpFilePart","out"],
2786
2786
  ])
2787
2787
 
2788
- railgun.add_function('kernel32', 'SearchPathW', 'DWORD',[
2788
+ dll.add_function( 'SearchPathW', 'DWORD',[
2789
2789
  ["PWCHAR","lpPath","in"],
2790
2790
  ["PWCHAR","lpFileName","in"],
2791
2791
  ["PWCHAR","lpExtension","in"],
@@ -2794,285 +2794,285 @@ class Def_kernel32
2794
2794
  ["PBLOB","lpFilePart","out"],
2795
2795
  ])
2796
2796
 
2797
- railgun.add_function('kernel32', 'SetCommBreak', 'BOOL',[
2797
+ dll.add_function( 'SetCommBreak', 'BOOL',[
2798
2798
  ["HANDLE","hFile","in"],
2799
2799
  ])
2800
2800
 
2801
- railgun.add_function('kernel32', 'SetCommConfig', 'BOOL',[
2801
+ dll.add_function( 'SetCommConfig', 'BOOL',[
2802
2802
  ["HANDLE","hCommDev","in"],
2803
2803
  ["PBLOB","lpCC","in"],
2804
2804
  ["DWORD","dwSize","in"],
2805
2805
  ])
2806
2806
 
2807
- railgun.add_function('kernel32', 'SetCommMask', 'BOOL',[
2807
+ dll.add_function( 'SetCommMask', 'BOOL',[
2808
2808
  ["HANDLE","hFile","in"],
2809
2809
  ["DWORD","dwEvtMask","in"],
2810
2810
  ])
2811
2811
 
2812
- railgun.add_function('kernel32', 'SetCommState', 'BOOL',[
2812
+ dll.add_function( 'SetCommState', 'BOOL',[
2813
2813
  ["HANDLE","hFile","in"],
2814
2814
  ["PBLOB","lpDCB","in"],
2815
2815
  ])
2816
2816
 
2817
- railgun.add_function('kernel32', 'SetCommTimeouts', 'BOOL',[
2817
+ dll.add_function( 'SetCommTimeouts', 'BOOL',[
2818
2818
  ["HANDLE","hFile","in"],
2819
2819
  ["PBLOB","lpCommTimeouts","in"],
2820
2820
  ])
2821
2821
 
2822
- railgun.add_function('kernel32', 'SetComputerNameA', 'BOOL',[
2822
+ dll.add_function( 'SetComputerNameA', 'BOOL',[
2823
2823
  ["PCHAR","lpComputerName","in"],
2824
2824
  ])
2825
2825
 
2826
- railgun.add_function('kernel32', 'SetComputerNameExA', 'BOOL',[
2826
+ dll.add_function( 'SetComputerNameExA', 'BOOL',[
2827
2827
  ["DWORD","NameType","in"],
2828
2828
  ["PCHAR","lpBuffer","in"],
2829
2829
  ])
2830
2830
 
2831
- railgun.add_function('kernel32', 'SetComputerNameExW', 'BOOL',[
2831
+ dll.add_function( 'SetComputerNameExW', 'BOOL',[
2832
2832
  ["DWORD","NameType","in"],
2833
2833
  ["PWCHAR","lpBuffer","in"],
2834
2834
  ])
2835
2835
 
2836
- railgun.add_function('kernel32', 'SetComputerNameW', 'BOOL',[
2836
+ dll.add_function( 'SetComputerNameW', 'BOOL',[
2837
2837
  ["PWCHAR","lpComputerName","in"],
2838
2838
  ])
2839
2839
 
2840
- railgun.add_function('kernel32', 'SetCriticalSectionSpinCount', 'DWORD',[
2840
+ dll.add_function( 'SetCriticalSectionSpinCount', 'DWORD',[
2841
2841
  ["PBLOB","lpCriticalSection","inout"],
2842
2842
  ["DWORD","dwSpinCount","in"],
2843
2843
  ])
2844
2844
 
2845
- railgun.add_function('kernel32', 'SetCurrentDirectoryA', 'BOOL',[
2845
+ dll.add_function( 'SetCurrentDirectoryA', 'BOOL',[
2846
2846
  ["PCHAR","lpPathName","in"],
2847
2847
  ])
2848
2848
 
2849
- railgun.add_function('kernel32', 'SetCurrentDirectoryW', 'BOOL',[
2849
+ dll.add_function( 'SetCurrentDirectoryW', 'BOOL',[
2850
2850
  ["PWCHAR","lpPathName","in"],
2851
2851
  ])
2852
2852
 
2853
- railgun.add_function('kernel32', 'SetDefaultCommConfigA', 'BOOL',[
2853
+ dll.add_function( 'SetDefaultCommConfigA', 'BOOL',[
2854
2854
  ["PCHAR","lpszName","in"],
2855
2855
  ["PBLOB","lpCC","in"],
2856
2856
  ["DWORD","dwSize","in"],
2857
2857
  ])
2858
2858
 
2859
- railgun.add_function('kernel32', 'SetDefaultCommConfigW', 'BOOL',[
2859
+ dll.add_function( 'SetDefaultCommConfigW', 'BOOL',[
2860
2860
  ["PWCHAR","lpszName","in"],
2861
2861
  ["PBLOB","lpCC","in"],
2862
2862
  ["DWORD","dwSize","in"],
2863
2863
  ])
2864
2864
 
2865
- railgun.add_function('kernel32', 'SetDllDirectoryA', 'BOOL',[
2865
+ dll.add_function( 'SetDllDirectoryA', 'BOOL',[
2866
2866
  ["PCHAR","lpPathName","in"],
2867
2867
  ])
2868
2868
 
2869
- railgun.add_function('kernel32', 'SetDllDirectoryW', 'BOOL',[
2869
+ dll.add_function( 'SetDllDirectoryW', 'BOOL',[
2870
2870
  ["PWCHAR","lpPathName","in"],
2871
2871
  ])
2872
2872
 
2873
- railgun.add_function('kernel32', 'SetEndOfFile', 'BOOL',[
2873
+ dll.add_function( 'SetEndOfFile', 'BOOL',[
2874
2874
  ["HANDLE","hFile","in"],
2875
2875
  ])
2876
2876
 
2877
- railgun.add_function('kernel32', 'SetEnvironmentStringsA', 'BOOL',[
2877
+ dll.add_function( 'SetEnvironmentStringsA', 'BOOL',[
2878
2878
  ["PBLOB","NewEnvironment","in"],
2879
2879
  ])
2880
2880
 
2881
- railgun.add_function('kernel32', 'SetEnvironmentStringsW', 'BOOL',[
2881
+ dll.add_function( 'SetEnvironmentStringsW', 'BOOL',[
2882
2882
  ["PBLOB","NewEnvironment","in"],
2883
2883
  ])
2884
2884
 
2885
- railgun.add_function('kernel32', 'SetEnvironmentVariableA', 'BOOL',[
2885
+ dll.add_function( 'SetEnvironmentVariableA', 'BOOL',[
2886
2886
  ["PCHAR","lpName","in"],
2887
2887
  ["PCHAR","lpValue","in"],
2888
2888
  ])
2889
2889
 
2890
- railgun.add_function('kernel32', 'SetEnvironmentVariableW', 'BOOL',[
2890
+ dll.add_function( 'SetEnvironmentVariableW', 'BOOL',[
2891
2891
  ["PWCHAR","lpName","in"],
2892
2892
  ["PWCHAR","lpValue","in"],
2893
2893
  ])
2894
2894
 
2895
- railgun.add_function('kernel32', 'SetErrorMode', 'DWORD',[
2895
+ dll.add_function( 'SetErrorMode', 'DWORD',[
2896
2896
  ["DWORD","uMode","in"],
2897
2897
  ])
2898
2898
 
2899
- railgun.add_function('kernel32', 'SetEvent', 'BOOL',[
2899
+ dll.add_function( 'SetEvent', 'BOOL',[
2900
2900
  ["HANDLE","hEvent","in"],
2901
2901
  ])
2902
2902
 
2903
- railgun.add_function('kernel32', 'SetFileApisToANSI', 'VOID',[
2903
+ dll.add_function( 'SetFileApisToANSI', 'VOID',[
2904
2904
  ])
2905
2905
 
2906
- railgun.add_function('kernel32', 'SetFileApisToOEM', 'VOID',[
2906
+ dll.add_function( 'SetFileApisToOEM', 'VOID',[
2907
2907
  ])
2908
2908
 
2909
- railgun.add_function('kernel32', 'SetFileAttributesA', 'BOOL',[
2909
+ dll.add_function( 'SetFileAttributesA', 'BOOL',[
2910
2910
  ["PCHAR","lpFileName","in"],
2911
2911
  ["DWORD","dwFileAttributes","in"],
2912
2912
  ])
2913
2913
 
2914
- railgun.add_function('kernel32', 'SetFileAttributesW', 'BOOL',[
2914
+ dll.add_function( 'SetFileAttributesW', 'BOOL',[
2915
2915
  ["PWCHAR","lpFileName","in"],
2916
2916
  ["DWORD","dwFileAttributes","in"],
2917
2917
  ])
2918
2918
 
2919
- railgun.add_function('kernel32', 'SetFilePointer', 'DWORD',[
2919
+ dll.add_function( 'SetFilePointer', 'DWORD',[
2920
2920
  ["HANDLE","hFile","in"],
2921
2921
  ["DWORD","lDistanceToMove","in"],
2922
2922
  ["PDWORD","lpDistanceToMoveHigh","in"],
2923
2923
  ["DWORD","dwMoveMethod","in"],
2924
2924
  ])
2925
2925
 
2926
- railgun.add_function('kernel32', 'SetFilePointerEx', 'BOOL',[
2926
+ dll.add_function( 'SetFilePointerEx', 'BOOL',[
2927
2927
  ["HANDLE","hFile","in"],
2928
2928
  ["PBLOB","liDistanceToMove","in"],
2929
2929
  ["PBLOB","lpNewFilePointer","out"],
2930
2930
  ["DWORD","dwMoveMethod","in"],
2931
2931
  ])
2932
2932
 
2933
- railgun.add_function('kernel32', 'SetFileShortNameA', 'BOOL',[
2933
+ dll.add_function( 'SetFileShortNameA', 'BOOL',[
2934
2934
  ["HANDLE","hFile","in"],
2935
2935
  ["PCHAR","lpShortName","in"],
2936
2936
  ])
2937
2937
 
2938
- railgun.add_function('kernel32', 'SetFileShortNameW', 'BOOL',[
2938
+ dll.add_function( 'SetFileShortNameW', 'BOOL',[
2939
2939
  ["HANDLE","hFile","in"],
2940
2940
  ["PWCHAR","lpShortName","in"],
2941
2941
  ])
2942
2942
 
2943
- railgun.add_function('kernel32', 'SetFileTime', 'BOOL',[
2943
+ dll.add_function( 'SetFileTime', 'BOOL',[
2944
2944
  ["HANDLE","hFile","in"],
2945
2945
  ["PBLOB","lpCreationTime","in"],
2946
2946
  ["PBLOB","lpLastAccessTime","in"],
2947
2947
  ["PBLOB","lpLastWriteTime","in"],
2948
2948
  ])
2949
2949
 
2950
- railgun.add_function('kernel32', 'SetFileValidData', 'BOOL',[
2950
+ dll.add_function( 'SetFileValidData', 'BOOL',[
2951
2951
  ["HANDLE","hFile","in"],
2952
2952
  ["PBLOB","ValidDataLength","in"],
2953
2953
  ])
2954
2954
 
2955
- railgun.add_function('kernel32', 'SetFirmwareEnvironmentVariableA', 'BOOL',[
2955
+ dll.add_function( 'SetFirmwareEnvironmentVariableA', 'BOOL',[
2956
2956
  ["PCHAR","lpName","in"],
2957
2957
  ["PCHAR","lpGuid","in"],
2958
2958
  ["PBLOB","pValue","in"],
2959
2959
  ["DWORD","nSize","in"],
2960
2960
  ])
2961
2961
 
2962
- railgun.add_function('kernel32', 'SetFirmwareEnvironmentVariableW', 'BOOL',[
2962
+ dll.add_function( 'SetFirmwareEnvironmentVariableW', 'BOOL',[
2963
2963
  ["PWCHAR","lpName","in"],
2964
2964
  ["PWCHAR","lpGuid","in"],
2965
2965
  ["PBLOB","pValue","in"],
2966
2966
  ["DWORD","nSize","in"],
2967
2967
  ])
2968
2968
 
2969
- railgun.add_function('kernel32', 'SetHandleCount', 'DWORD',[
2969
+ dll.add_function( 'SetHandleCount', 'DWORD',[
2970
2970
  ["DWORD","uNumber","in"],
2971
2971
  ])
2972
2972
 
2973
- railgun.add_function('kernel32', 'SetHandleInformation', 'BOOL',[
2973
+ dll.add_function( 'SetHandleInformation', 'BOOL',[
2974
2974
  ["HANDLE","hObject","in"],
2975
2975
  ["DWORD","dwMask","in"],
2976
2976
  ["DWORD","dwFlags","in"],
2977
2977
  ])
2978
2978
 
2979
- railgun.add_function('kernel32', 'SetInformationJobObject', 'BOOL',[
2979
+ dll.add_function( 'SetInformationJobObject', 'BOOL',[
2980
2980
  ["HANDLE","hJob","in"],
2981
2981
  ["PBLOB","JobObjectInformationClass","in"],
2982
2982
  ["PBLOB","lpJobObjectInformation","in"],
2983
2983
  ["DWORD","cbJobObjectInformationLength","in"],
2984
2984
  ])
2985
2985
 
2986
- railgun.add_function('kernel32', 'SetLastError', 'VOID',[
2986
+ dll.add_function( 'SetLastError', 'VOID',[
2987
2987
  ["DWORD","dwErrCode","in"],
2988
2988
  ])
2989
2989
 
2990
- railgun.add_function('kernel32', 'SetLocalTime', 'BOOL',[
2990
+ dll.add_function( 'SetLocalTime', 'BOOL',[
2991
2991
  ["PBLOB","lpSystemTime","in"],
2992
2992
  ])
2993
2993
 
2994
- railgun.add_function('kernel32', 'SetMailslotInfo', 'BOOL',[
2994
+ dll.add_function( 'SetMailslotInfo', 'BOOL',[
2995
2995
  ["HANDLE","hMailslot","in"],
2996
2996
  ["DWORD","lReadTimeout","in"],
2997
2997
  ])
2998
2998
 
2999
- railgun.add_function('kernel32', 'SetMessageWaitingIndicator', 'BOOL',[
2999
+ dll.add_function( 'SetMessageWaitingIndicator', 'BOOL',[
3000
3000
  ["HANDLE","hMsgIndicator","in"],
3001
3001
  ["DWORD","ulMsgCount","in"],
3002
3002
  ])
3003
3003
 
3004
- railgun.add_function('kernel32', 'SetNamedPipeHandleState', 'BOOL',[
3004
+ dll.add_function( 'SetNamedPipeHandleState', 'BOOL',[
3005
3005
  ["HANDLE","hNamedPipe","in"],
3006
3006
  ["PDWORD","lpMode","in"],
3007
3007
  ["PDWORD","lpMaxCollectionCount","in"],
3008
3008
  ["PDWORD","lpCollectDataTimeout","in"],
3009
3009
  ])
3010
3010
 
3011
- railgun.add_function('kernel32', 'SetPriorityClass', 'BOOL',[
3011
+ dll.add_function( 'SetPriorityClass', 'BOOL',[
3012
3012
  ["HANDLE","hProcess","in"],
3013
3013
  ["DWORD","dwPriorityClass","in"],
3014
3014
  ])
3015
3015
 
3016
- railgun.add_function('kernel32', 'SetProcessAffinityMask', 'BOOL',[
3016
+ dll.add_function( 'SetProcessAffinityMask', 'BOOL',[
3017
3017
  ["HANDLE","hProcess","in"],
3018
3018
  ["PDWORD","dwProcessAffinityMask","in"],
3019
3019
  ])
3020
3020
 
3021
- railgun.add_function('kernel32', 'SetProcessPriorityBoost', 'BOOL',[
3021
+ dll.add_function( 'SetProcessPriorityBoost', 'BOOL',[
3022
3022
  ["HANDLE","hProcess","in"],
3023
3023
  ["BOOL","bDisablePriorityBoost","in"],
3024
3024
  ])
3025
3025
 
3026
- railgun.add_function('kernel32', 'SetProcessShutdownParameters', 'BOOL',[
3026
+ dll.add_function( 'SetProcessShutdownParameters', 'BOOL',[
3027
3027
  ["DWORD","dwLevel","in"],
3028
3028
  ["DWORD","dwFlags","in"],
3029
3029
  ])
3030
3030
 
3031
- railgun.add_function('kernel32', 'SetProcessWorkingSetSize', 'BOOL',[
3031
+ dll.add_function( 'SetProcessWorkingSetSize', 'BOOL',[
3032
3032
  ["HANDLE","hProcess","in"],
3033
3033
  ["DWORD","dwMinimumWorkingSetSize","in"],
3034
3034
  ["DWORD","dwMaximumWorkingSetSize","in"],
3035
3035
  ])
3036
3036
 
3037
- railgun.add_function('kernel32', 'SetProcessWorkingSetSizeEx', 'BOOL',[
3037
+ dll.add_function( 'SetProcessWorkingSetSizeEx', 'BOOL',[
3038
3038
  ["HANDLE","hProcess","in"],
3039
3039
  ["DWORD","dwMinimumWorkingSetSize","in"],
3040
3040
  ["DWORD","dwMaximumWorkingSetSize","in"],
3041
3041
  ["DWORD","Flags","in"],
3042
3042
  ])
3043
3043
 
3044
- railgun.add_function('kernel32', 'SetStdHandle', 'BOOL',[
3044
+ dll.add_function( 'SetStdHandle', 'BOOL',[
3045
3045
  ["DWORD","nStdHandle","in"],
3046
3046
  ["HANDLE","hHandle","in"],
3047
3047
  ])
3048
3048
 
3049
- railgun.add_function('kernel32', 'SetSystemFileCacheSize', 'BOOL',[
3049
+ dll.add_function( 'SetSystemFileCacheSize', 'BOOL',[
3050
3050
  ["DWORD","MinimumFileCacheSize","in"],
3051
3051
  ["DWORD","MaximumFileCacheSize","in"],
3052
3052
  ["DWORD","Flags","in"],
3053
3053
  ])
3054
3054
 
3055
- railgun.add_function('kernel32', 'SetSystemPowerState', 'BOOL',[
3055
+ dll.add_function( 'SetSystemPowerState', 'BOOL',[
3056
3056
  ["BOOL","fSuspend","in"],
3057
3057
  ["BOOL","fForce","in"],
3058
3058
  ])
3059
3059
 
3060
- railgun.add_function('kernel32', 'SetSystemTime', 'BOOL',[
3060
+ dll.add_function( 'SetSystemTime', 'BOOL',[
3061
3061
  ["PBLOB","lpSystemTime","in"],
3062
3062
  ])
3063
3063
 
3064
- railgun.add_function('kernel32', 'SetSystemTimeAdjustment', 'BOOL',[
3064
+ dll.add_function( 'SetSystemTimeAdjustment', 'BOOL',[
3065
3065
  ["DWORD","dwTimeAdjustment","in"],
3066
3066
  ["BOOL","bTimeAdjustmentDisabled","in"],
3067
3067
  ])
3068
3068
 
3069
- railgun.add_function('kernel32', 'SetTapeParameters', 'DWORD',[
3069
+ dll.add_function( 'SetTapeParameters', 'DWORD',[
3070
3070
  ["HANDLE","hDevice","in"],
3071
3071
  ["DWORD","dwOperation","in"],
3072
3072
  ["PBLOB","lpTapeInformation","in"],
3073
3073
  ])
3074
3074
 
3075
- railgun.add_function('kernel32', 'SetTapePosition', 'DWORD',[
3075
+ dll.add_function( 'SetTapePosition', 'DWORD',[
3076
3076
  ["HANDLE","hDevice","in"],
3077
3077
  ["DWORD","dwPositionMethod","in"],
3078
3078
  ["DWORD","dwPartition","in"],
@@ -3081,44 +3081,44 @@ class Def_kernel32
3081
3081
  ["BOOL","bImmediate","in"],
3082
3082
  ])
3083
3083
 
3084
- #railgun.add_function('kernel32', 'SetThreadAffinityMask', 'PDWORD',[
3084
+ #dll.add_function( 'SetThreadAffinityMask', 'PDWORD',[
3085
3085
  # ["HANDLE","hThread","in"],
3086
3086
  # ["PDWORD","dwThreadAffinityMask","in"],
3087
3087
  # ])
3088
3088
 
3089
- railgun.add_function('kernel32', 'SetThreadContext', 'BOOL',[
3089
+ dll.add_function( 'SetThreadContext', 'BOOL',[
3090
3090
  ["HANDLE","hThread","in"],
3091
3091
  ["PBLOB","lpContext","in"],
3092
3092
  ])
3093
3093
 
3094
- railgun.add_function('kernel32', 'SetThreadExecutionState', 'DWORD',[
3094
+ dll.add_function( 'SetThreadExecutionState', 'DWORD',[
3095
3095
  ["DWORD","esFlags","in"],
3096
3096
  ])
3097
3097
 
3098
- railgun.add_function('kernel32', 'SetThreadIdealProcessor', 'DWORD',[
3098
+ dll.add_function( 'SetThreadIdealProcessor', 'DWORD',[
3099
3099
  ["HANDLE","hThread","in"],
3100
3100
  ["DWORD","dwIdealProcessor","in"],
3101
3101
  ])
3102
3102
 
3103
- railgun.add_function('kernel32', 'SetThreadPriority', 'BOOL',[
3103
+ dll.add_function( 'SetThreadPriority', 'BOOL',[
3104
3104
  ["HANDLE","hThread","in"],
3105
3105
  ["DWORD","nPriority","in"],
3106
3106
  ])
3107
3107
 
3108
- railgun.add_function('kernel32', 'SetThreadPriorityBoost', 'BOOL',[
3108
+ dll.add_function( 'SetThreadPriorityBoost', 'BOOL',[
3109
3109
  ["HANDLE","hThread","in"],
3110
3110
  ["BOOL","bDisablePriorityBoost","in"],
3111
3111
  ])
3112
3112
 
3113
- railgun.add_function('kernel32', 'SetThreadStackGuarantee', 'BOOL',[
3113
+ dll.add_function( 'SetThreadStackGuarantee', 'BOOL',[
3114
3114
  ["PDWORD","StackSizeInBytes","inout"],
3115
3115
  ])
3116
3116
 
3117
- railgun.add_function('kernel32', 'SetTimeZoneInformation', 'BOOL',[
3117
+ dll.add_function( 'SetTimeZoneInformation', 'BOOL',[
3118
3118
  ["PBLOB","lpTimeZoneInformation","in"],
3119
3119
  ])
3120
3120
 
3121
- railgun.add_function('kernel32', 'SetTimerQueueTimer', 'DWORD',[
3121
+ dll.add_function( 'SetTimerQueueTimer', 'DWORD',[
3122
3122
  ["DWORD","TimerQueue","in"],
3123
3123
  ["PBLOB","Callback","in"],
3124
3124
  ["PBLOB","Parameter","in"],
@@ -3127,31 +3127,31 @@ class Def_kernel32
3127
3127
  ["BOOL","PreferIo","in"],
3128
3128
  ])
3129
3129
 
3130
- railgun.add_function('kernel32', 'SetUnhandledExceptionFilter', 'LPVOID',[
3130
+ dll.add_function( 'SetUnhandledExceptionFilter', 'LPVOID',[
3131
3131
  ["PBLOB","lpTopLevelExceptionFilter","in"],
3132
3132
  ])
3133
3133
 
3134
- railgun.add_function('kernel32', 'SetVolumeLabelA', 'BOOL',[
3134
+ dll.add_function( 'SetVolumeLabelA', 'BOOL',[
3135
3135
  ["PCHAR","lpRootPathName","in"],
3136
3136
  ["PCHAR","lpVolumeName","in"],
3137
3137
  ])
3138
3138
 
3139
- railgun.add_function('kernel32', 'SetVolumeLabelW', 'BOOL',[
3139
+ dll.add_function( 'SetVolumeLabelW', 'BOOL',[
3140
3140
  ["PWCHAR","lpRootPathName","in"],
3141
3141
  ["PWCHAR","lpVolumeName","in"],
3142
3142
  ])
3143
3143
 
3144
- railgun.add_function('kernel32', 'SetVolumeMountPointA', 'BOOL',[
3144
+ dll.add_function( 'SetVolumeMountPointA', 'BOOL',[
3145
3145
  ["PCHAR","lpszVolumeMountPoint","in"],
3146
3146
  ["PCHAR","lpszVolumeName","in"],
3147
3147
  ])
3148
3148
 
3149
- railgun.add_function('kernel32', 'SetVolumeMountPointW', 'BOOL',[
3149
+ dll.add_function( 'SetVolumeMountPointW', 'BOOL',[
3150
3150
  ["PWCHAR","lpszVolumeMountPoint","in"],
3151
3151
  ["PWCHAR","lpszVolumeName","in"],
3152
3152
  ])
3153
3153
 
3154
- railgun.add_function('kernel32', 'SetWaitableTimer', 'BOOL',[
3154
+ dll.add_function( 'SetWaitableTimer', 'BOOL',[
3155
3155
  ["HANDLE","hTimer","in"],
3156
3156
  ["PBLOB","lpDueTime","in"],
3157
3157
  ["DWORD","lPeriod","in"],
@@ -3160,87 +3160,87 @@ class Def_kernel32
3160
3160
  ["BOOL","fResume","in"],
3161
3161
  ])
3162
3162
 
3163
- railgun.add_function('kernel32', 'SetupComm', 'BOOL',[
3163
+ dll.add_function( 'SetupComm', 'BOOL',[
3164
3164
  ["HANDLE","hFile","in"],
3165
3165
  ["DWORD","dwInQueue","in"],
3166
3166
  ["DWORD","dwOutQueue","in"],
3167
3167
  ])
3168
3168
 
3169
- railgun.add_function('kernel32', 'SignalObjectAndWait', 'DWORD',[
3169
+ dll.add_function( 'SignalObjectAndWait', 'DWORD',[
3170
3170
  ["HANDLE","hObjectToSignal","in"],
3171
3171
  ["HANDLE","hObjectToWaitOn","in"],
3172
3172
  ["DWORD","dwMilliseconds","in"],
3173
3173
  ["BOOL","bAlertable","in"],
3174
3174
  ])
3175
3175
 
3176
- railgun.add_function('kernel32', 'SizeofResource', 'DWORD',[
3176
+ dll.add_function( 'SizeofResource', 'DWORD',[
3177
3177
  ["HANDLE","hModule","in"],
3178
3178
  ["HANDLE","hResInfo","in"],
3179
3179
  ])
3180
3180
 
3181
- railgun.add_function('kernel32', 'Sleep', 'VOID',[
3181
+ dll.add_function( 'Sleep', 'VOID',[
3182
3182
  ["DWORD","dwMilliseconds","in"],
3183
3183
  ])
3184
3184
 
3185
- railgun.add_function('kernel32', 'SleepEx', 'DWORD',[
3185
+ dll.add_function( 'SleepEx', 'DWORD',[
3186
3186
  ["DWORD","dwMilliseconds","in"],
3187
3187
  ["BOOL","bAlertable","in"],
3188
3188
  ])
3189
3189
 
3190
- railgun.add_function('kernel32', 'SuspendThread', 'DWORD',[
3190
+ dll.add_function( 'SuspendThread', 'DWORD',[
3191
3191
  ["HANDLE","hThread","in"],
3192
3192
  ])
3193
3193
 
3194
- railgun.add_function('kernel32', 'SwitchToFiber', 'VOID',[
3194
+ dll.add_function( 'SwitchToFiber', 'VOID',[
3195
3195
  ["PBLOB","lpFiber","in"],
3196
3196
  ])
3197
3197
 
3198
- railgun.add_function('kernel32', 'SwitchToThread', 'BOOL',[
3198
+ dll.add_function( 'SwitchToThread', 'BOOL',[
3199
3199
  ])
3200
3200
 
3201
- railgun.add_function('kernel32', 'SystemTimeToFileTime', 'BOOL',[
3201
+ dll.add_function( 'SystemTimeToFileTime', 'BOOL',[
3202
3202
  ["PBLOB","lpSystemTime","in"],
3203
3203
  ["PBLOB","lpFileTime","out"],
3204
3204
  ])
3205
3205
 
3206
- railgun.add_function('kernel32', 'SystemTimeToTzSpecificLocalTime', 'BOOL',[
3206
+ dll.add_function( 'SystemTimeToTzSpecificLocalTime', 'BOOL',[
3207
3207
  ["PBLOB","lpTimeZoneInformation","in"],
3208
3208
  ["PBLOB","lpUniversalTime","in"],
3209
3209
  ["PBLOB","lpLocalTime","out"],
3210
3210
  ])
3211
3211
 
3212
- railgun.add_function('kernel32', 'TerminateJobObject', 'BOOL',[
3212
+ dll.add_function( 'TerminateJobObject', 'BOOL',[
3213
3213
  ["HANDLE","hJob","in"],
3214
3214
  ["DWORD","uExitCode","in"],
3215
3215
  ])
3216
3216
 
3217
- railgun.add_function('kernel32', 'TerminateProcess', 'BOOL',[
3217
+ dll.add_function( 'TerminateProcess', 'BOOL',[
3218
3218
  ["HANDLE","hProcess","in"],
3219
3219
  ["DWORD","uExitCode","in"],
3220
3220
  ])
3221
3221
 
3222
- railgun.add_function('kernel32', 'TerminateThread', 'BOOL',[
3222
+ dll.add_function( 'TerminateThread', 'BOOL',[
3223
3223
  ["HANDLE","hThread","in"],
3224
3224
  ["DWORD","dwExitCode","in"],
3225
3225
  ])
3226
3226
 
3227
- railgun.add_function('kernel32', 'TlsAlloc', 'DWORD',[
3227
+ dll.add_function( 'TlsAlloc', 'DWORD',[
3228
3228
  ])
3229
3229
 
3230
- railgun.add_function('kernel32', 'TlsFree', 'BOOL',[
3230
+ dll.add_function( 'TlsFree', 'BOOL',[
3231
3231
  ["DWORD","dwTlsIndex","in"],
3232
3232
  ])
3233
3233
 
3234
- railgun.add_function('kernel32', 'TlsGetValue', 'LPVOID',[
3234
+ dll.add_function( 'TlsGetValue', 'LPVOID',[
3235
3235
  ["DWORD","dwTlsIndex","in"],
3236
3236
  ])
3237
3237
 
3238
- railgun.add_function('kernel32', 'TlsSetValue', 'BOOL',[
3238
+ dll.add_function( 'TlsSetValue', 'BOOL',[
3239
3239
  ["DWORD","dwTlsIndex","in"],
3240
3240
  ["PBLOB","lpTlsValue","in"],
3241
3241
  ])
3242
3242
 
3243
- railgun.add_function('kernel32', 'TransactNamedPipe', 'BOOL',[
3243
+ dll.add_function( 'TransactNamedPipe', 'BOOL',[
3244
3244
  ["HANDLE","hNamedPipe","in"],
3245
3245
  ["PBLOB","lpInBuffer","in"],
3246
3246
  ["DWORD","nInBufferSize","in"],
@@ -3250,26 +3250,26 @@ class Def_kernel32
3250
3250
  ["PBLOB","lpOverlapped","inout"],
3251
3251
  ])
3252
3252
 
3253
- railgun.add_function('kernel32', 'TransmitCommChar', 'BOOL',[
3253
+ dll.add_function( 'TransmitCommChar', 'BOOL',[
3254
3254
  ["HANDLE","hFile","in"],
3255
3255
  ["BYTE","cChar","in"],
3256
3256
  ])
3257
3257
 
3258
- railgun.add_function('kernel32', 'TryEnterCriticalSection', 'BOOL',[
3258
+ dll.add_function( 'TryEnterCriticalSection', 'BOOL',[
3259
3259
  ["PBLOB","lpCriticalSection","inout"],
3260
3260
  ])
3261
3261
 
3262
- railgun.add_function('kernel32', 'TzSpecificLocalTimeToSystemTime', 'BOOL',[
3262
+ dll.add_function( 'TzSpecificLocalTimeToSystemTime', 'BOOL',[
3263
3263
  ["PBLOB","lpTimeZoneInformation","in"],
3264
3264
  ["PBLOB","lpLocalTime","in"],
3265
3265
  ["PBLOB","lpUniversalTime","out"],
3266
3266
  ])
3267
3267
 
3268
- railgun.add_function('kernel32', 'UnhandledExceptionFilter', 'DWORD',[
3268
+ dll.add_function( 'UnhandledExceptionFilter', 'DWORD',[
3269
3269
  ["PBLOB","ExceptionInfo","in"],
3270
3270
  ])
3271
3271
 
3272
- railgun.add_function('kernel32', 'UnlockFile', 'BOOL',[
3272
+ dll.add_function( 'UnlockFile', 'BOOL',[
3273
3273
  ["HANDLE","hFile","in"],
3274
3274
  ["DWORD","dwFileOffsetLow","in"],
3275
3275
  ["DWORD","dwFileOffsetHigh","in"],
@@ -3277,7 +3277,7 @@ class Def_kernel32
3277
3277
  ["DWORD","nNumberOfBytesToUnlockHigh","in"],
3278
3278
  ])
3279
3279
 
3280
- railgun.add_function('kernel32', 'UnlockFileEx', 'BOOL',[
3280
+ dll.add_function( 'UnlockFileEx', 'BOOL',[
3281
3281
  ["HANDLE","hFile","in"],
3282
3282
  ["DWORD","dwReserved","inout"],
3283
3283
  ["DWORD","nNumberOfBytesToUnlockLow","in"],
@@ -3285,20 +3285,20 @@ class Def_kernel32
3285
3285
  ["PBLOB","lpOverlapped","inout"],
3286
3286
  ])
3287
3287
 
3288
- railgun.add_function('kernel32', 'UnmapViewOfFile', 'BOOL',[
3288
+ dll.add_function( 'UnmapViewOfFile', 'BOOL',[
3289
3289
  ["PBLOB","lpBaseAddress","in"],
3290
3290
  ])
3291
3291
 
3292
- railgun.add_function('kernel32', 'UnregisterWait', 'BOOL',[
3292
+ dll.add_function( 'UnregisterWait', 'BOOL',[
3293
3293
  ["DWORD","WaitHandle","in"],
3294
3294
  ])
3295
3295
 
3296
- railgun.add_function('kernel32', 'UnregisterWaitEx', 'BOOL',[
3296
+ dll.add_function( 'UnregisterWaitEx', 'BOOL',[
3297
3297
  ["DWORD","WaitHandle","in"],
3298
3298
  ["DWORD","CompletionEvent","in"],
3299
3299
  ])
3300
3300
 
3301
- railgun.add_function('kernel32', 'UpdateResourceA', 'BOOL',[
3301
+ dll.add_function( 'UpdateResourceA', 'BOOL',[
3302
3302
  ["HANDLE","hUpdate","in"],
3303
3303
  ["PCHAR","lpType","in"],
3304
3304
  ["PCHAR","lpName","in"],
@@ -3307,7 +3307,7 @@ class Def_kernel32
3307
3307
  ["DWORD","cb","in"],
3308
3308
  ])
3309
3309
 
3310
- railgun.add_function('kernel32', 'UpdateResourceW', 'BOOL',[
3310
+ dll.add_function( 'UpdateResourceW', 'BOOL',[
3311
3311
  ["HANDLE","hUpdate","in"],
3312
3312
  ["PWCHAR","lpType","in"],
3313
3313
  ["PWCHAR","lpName","in"],
@@ -3316,26 +3316,26 @@ class Def_kernel32
3316
3316
  ["DWORD","cb","in"],
3317
3317
  ])
3318
3318
 
3319
- railgun.add_function('kernel32', 'VerifyVersionInfoA', 'BOOL',[
3319
+ dll.add_function( 'VerifyVersionInfoA', 'BOOL',[
3320
3320
  ["PBLOB","lpVersionInformation","inout"],
3321
3321
  ["DWORD","dwTypeMask","in"],
3322
3322
  ["PBLOB","dwlConditionMask","in"],
3323
3323
  ])
3324
3324
 
3325
- railgun.add_function('kernel32', 'VerifyVersionInfoW', 'BOOL',[
3325
+ dll.add_function( 'VerifyVersionInfoW', 'BOOL',[
3326
3326
  ["PBLOB","lpVersionInformation","inout"],
3327
3327
  ["DWORD","dwTypeMask","in"],
3328
3328
  ["PBLOB","dwlConditionMask","in"],
3329
3329
  ])
3330
3330
 
3331
- railgun.add_function('kernel32', 'VirtualAlloc', 'LPVOID',[
3331
+ dll.add_function( 'VirtualAlloc', 'LPVOID',[
3332
3332
  ["LPVOID","lpAddress","in"],
3333
3333
  ["DWORD","dwSize","in"],
3334
3334
  ["DWORD","flAllocationType","in"],
3335
3335
  ["DWORD","flProtect","in"],
3336
3336
  ])
3337
3337
 
3338
- railgun.add_function('kernel32', 'VirtualAllocEx', 'LPVOID',[
3338
+ dll.add_function( 'VirtualAllocEx', 'LPVOID',[
3339
3339
  ["HANDLE","hProcess","in"],
3340
3340
  ["LPVOID","lpAddress","in"],
3341
3341
  ["DWORD","dwSize","in"],
@@ -3343,32 +3343,32 @@ class Def_kernel32
3343
3343
  ["DWORD","flProtect","in"],
3344
3344
  ])
3345
3345
 
3346
- railgun.add_function('kernel32', 'VirtualFree', 'BOOL',[
3346
+ dll.add_function( 'VirtualFree', 'BOOL',[
3347
3347
  ["LPVOID","lpAddress","in"],
3348
3348
  ["DWORD","dwSize","in"],
3349
3349
  ["DWORD","dwFreeType","in"],
3350
3350
  ])
3351
3351
 
3352
- railgun.add_function('kernel32', 'VirtualFreeEx', 'BOOL',[
3352
+ dll.add_function( 'VirtualFreeEx', 'BOOL',[
3353
3353
  ["HANDLE","hProcess","in"],
3354
3354
  ["LPVOID","lpAddress","in"],
3355
3355
  ["DWORD","dwSize","in"],
3356
3356
  ["DWORD","dwFreeType","in"],
3357
3357
  ])
3358
3358
 
3359
- railgun.add_function('kernel32', 'VirtualLock', 'BOOL',[
3359
+ dll.add_function( 'VirtualLock', 'BOOL',[
3360
3360
  ["LPVOID","lpAddress","in"],
3361
3361
  ["DWORD","dwSize","in"],
3362
3362
  ])
3363
3363
 
3364
- railgun.add_function('kernel32', 'VirtualProtect', 'BOOL',[
3364
+ dll.add_function( 'VirtualProtect', 'BOOL',[
3365
3365
  ["LPVOID","lpAddress","in"],
3366
3366
  ["DWORD","dwSize","in"],
3367
3367
  ["DWORD","flNewProtect","in"],
3368
3368
  ["PDWORD","lpflOldProtect","out"],
3369
3369
  ])
3370
3370
 
3371
- railgun.add_function('kernel32', 'VirtualProtectEx', 'BOOL',[
3371
+ dll.add_function( 'VirtualProtectEx', 'BOOL',[
3372
3372
  ["HANDLE","hProcess","in"],
3373
3373
  ["LPVOID","lpAddress","in"],
3374
3374
  ["DWORD","dwSize","in"],
@@ -3376,46 +3376,46 @@ class Def_kernel32
3376
3376
  ["PDWORD","lpflOldProtect","out"],
3377
3377
  ])
3378
3378
 
3379
- railgun.add_function('kernel32', 'VirtualQuery', 'DWORD',[
3379
+ dll.add_function( 'VirtualQuery', 'DWORD',[
3380
3380
  ["LPVOID","lpAddress","in"],
3381
3381
  ["PBLOB","lpBuffer","out"],
3382
3382
  ["DWORD","dwLength","in"],
3383
3383
  ])
3384
3384
 
3385
- railgun.add_function('kernel32', 'VirtualQueryEx', 'DWORD',[
3385
+ dll.add_function( 'VirtualQueryEx', 'DWORD',[
3386
3386
  ["HANDLE","hProcess","in"],
3387
3387
  ["LPVOID","lpAddress","in"],
3388
3388
  ["PBLOB","lpBuffer","out"],
3389
3389
  ["DWORD","dwLength","in"],
3390
3390
  ])
3391
3391
 
3392
- railgun.add_function('kernel32', 'VirtualUnlock', 'BOOL',[
3392
+ dll.add_function( 'VirtualUnlock', 'BOOL',[
3393
3393
  ["LPVOID","lpAddress","in"],
3394
3394
  ["DWORD","dwSize","in"],
3395
3395
  ])
3396
3396
 
3397
- railgun.add_function('kernel32', 'WTSGetActiveConsoleSessionId', 'DWORD',[
3397
+ dll.add_function( 'WTSGetActiveConsoleSessionId', 'DWORD',[
3398
3398
  ])
3399
3399
 
3400
- railgun.add_function('kernel32', 'WaitCommEvent', 'BOOL',[
3400
+ dll.add_function( 'WaitCommEvent', 'BOOL',[
3401
3401
  ["HANDLE","hFile","in"],
3402
3402
  ["PDWORD","lpEvtMask","inout"],
3403
3403
  ["PBLOB","lpOverlapped","inout"],
3404
3404
  ])
3405
3405
 
3406
- railgun.add_function('kernel32', 'WaitForDebugEvent', 'BOOL',[
3406
+ dll.add_function( 'WaitForDebugEvent', 'BOOL',[
3407
3407
  ["PBLOB","lpDebugEvent","in"],
3408
3408
  ["DWORD","dwMilliseconds","in"],
3409
3409
  ])
3410
3410
 
3411
- railgun.add_function('kernel32', 'WaitForMultipleObjects', 'DWORD',[
3411
+ dll.add_function( 'WaitForMultipleObjects', 'DWORD',[
3412
3412
  ["DWORD","nCount","in"],
3413
3413
  ["PDWORD","lpHandles","in"],
3414
3414
  ["BOOL","bWaitAll","in"],
3415
3415
  ["DWORD","dwMilliseconds","in"],
3416
3416
  ])
3417
3417
 
3418
- railgun.add_function('kernel32', 'WaitForMultipleObjectsEx', 'DWORD',[
3418
+ dll.add_function( 'WaitForMultipleObjectsEx', 'DWORD',[
3419
3419
  ["DWORD","nCount","in"],
3420
3420
  ["PDWORD","lpHandles","in"],
3421
3421
  ["BOOL","bWaitAll","in"],
@@ -3423,45 +3423,45 @@ class Def_kernel32
3423
3423
  ["BOOL","bAlertable","in"],
3424
3424
  ])
3425
3425
 
3426
- railgun.add_function('kernel32', 'WaitForSingleObject', 'DWORD',[
3426
+ dll.add_function( 'WaitForSingleObject', 'DWORD',[
3427
3427
  ["HANDLE","hHandle","in"],
3428
3428
  ["DWORD","dwMilliseconds","in"],
3429
3429
  ])
3430
3430
 
3431
- railgun.add_function('kernel32', 'WaitForSingleObjectEx', 'DWORD',[
3431
+ dll.add_function( 'WaitForSingleObjectEx', 'DWORD',[
3432
3432
  ["HANDLE","hHandle","in"],
3433
3433
  ["DWORD","dwMilliseconds","in"],
3434
3434
  ["BOOL","bAlertable","in"],
3435
3435
  ])
3436
3436
 
3437
- railgun.add_function('kernel32', 'WaitNamedPipeA', 'BOOL',[
3437
+ dll.add_function( 'WaitNamedPipeA', 'BOOL',[
3438
3438
  ["PCHAR","lpNamedPipeName","in"],
3439
3439
  ["DWORD","nTimeOut","in"],
3440
3440
  ])
3441
3441
 
3442
- railgun.add_function('kernel32', 'WaitNamedPipeW', 'BOOL',[
3442
+ dll.add_function( 'WaitNamedPipeW', 'BOOL',[
3443
3443
  ["PWCHAR","lpNamedPipeName","in"],
3444
3444
  ["DWORD","nTimeOut","in"],
3445
3445
  ])
3446
3446
 
3447
- railgun.add_function('kernel32', 'WinExec', 'DWORD',[
3447
+ dll.add_function( 'WinExec', 'DWORD',[
3448
3448
  ["PCHAR","lpCmdLine","in"],
3449
3449
  ["DWORD","uCmdShow","in"],
3450
3450
  ])
3451
3451
 
3452
- railgun.add_function('kernel32', 'Wow64DisableWow64FsRedirection', 'BOOL',[
3452
+ dll.add_function( 'Wow64DisableWow64FsRedirection', 'BOOL',[
3453
3453
  ["PBLOB","OldValue","out"],
3454
3454
  ])
3455
3455
 
3456
- railgun.add_function('kernel32', 'Wow64EnableWow64FsRedirection', 'BOOL',[
3456
+ dll.add_function( 'Wow64EnableWow64FsRedirection', 'BOOL',[
3457
3457
  ["BOOL","Wow64FsEnableRedirection","in"],
3458
3458
  ])
3459
3459
 
3460
- railgun.add_function('kernel32', 'Wow64RevertWow64FsRedirection', 'BOOL',[
3460
+ dll.add_function( 'Wow64RevertWow64FsRedirection', 'BOOL',[
3461
3461
  ["PBLOB","OlValue","in"],
3462
3462
  ])
3463
3463
 
3464
- railgun.add_function('kernel32', 'WriteFile', 'BOOL',[
3464
+ dll.add_function( 'WriteFile', 'BOOL',[
3465
3465
  ["HANDLE","hFile","in"],
3466
3466
  ["PBLOB","lpBuffer","in"],
3467
3467
  ["DWORD","nNumberOfBytesToWrite","in"],
@@ -3469,7 +3469,7 @@ class Def_kernel32
3469
3469
  ["PBLOB","lpOverlapped","inout"],
3470
3470
  ])
3471
3471
 
3472
- railgun.add_function('kernel32', 'WriteFileEx', 'BOOL',[
3472
+ dll.add_function( 'WriteFileEx', 'BOOL',[
3473
3473
  ["HANDLE","hFile","in"],
3474
3474
  ["PBLOB","lpBuffer","in"],
3475
3475
  ["DWORD","nNumberOfBytesToWrite","in"],
@@ -3477,7 +3477,7 @@ class Def_kernel32
3477
3477
  ["PBLOB","lpCompletionRoutine","in"],
3478
3478
  ])
3479
3479
 
3480
- railgun.add_function('kernel32', 'WriteFileGather', 'BOOL',[
3480
+ dll.add_function( 'WriteFileGather', 'BOOL',[
3481
3481
  ["HANDLE","hFile","in"],
3482
3482
  ["PBLOB","aSegmentArray[]","in"],
3483
3483
  ["DWORD","nNumberOfBytesToWrite","in"],
@@ -3485,33 +3485,33 @@ class Def_kernel32
3485
3485
  ["PBLOB","lpOverlapped","inout"],
3486
3486
  ])
3487
3487
 
3488
- railgun.add_function('kernel32', 'WritePrivateProfileSectionA', 'BOOL',[
3488
+ dll.add_function( 'WritePrivateProfileSectionA', 'BOOL',[
3489
3489
  ["PCHAR","lpAppName","in"],
3490
3490
  ["PCHAR","lpString","in"],
3491
3491
  ["PCHAR","lpFileName","in"],
3492
3492
  ])
3493
3493
 
3494
- railgun.add_function('kernel32', 'WritePrivateProfileSectionW', 'BOOL',[
3494
+ dll.add_function( 'WritePrivateProfileSectionW', 'BOOL',[
3495
3495
  ["PWCHAR","lpAppName","in"],
3496
3496
  ["PWCHAR","lpString","in"],
3497
3497
  ["PWCHAR","lpFileName","in"],
3498
3498
  ])
3499
3499
 
3500
- railgun.add_function('kernel32', 'WritePrivateProfileStringA', 'BOOL',[
3500
+ dll.add_function( 'WritePrivateProfileStringA', 'BOOL',[
3501
3501
  ["PCHAR","lpAppName","in"],
3502
3502
  ["PCHAR","lpKeyName","in"],
3503
3503
  ["PCHAR","lpString","in"],
3504
3504
  ["PCHAR","lpFileName","in"],
3505
3505
  ])
3506
3506
 
3507
- railgun.add_function('kernel32', 'WritePrivateProfileStringW', 'BOOL',[
3507
+ dll.add_function( 'WritePrivateProfileStringW', 'BOOL',[
3508
3508
  ["PWCHAR","lpAppName","in"],
3509
3509
  ["PWCHAR","lpKeyName","in"],
3510
3510
  ["PWCHAR","lpString","in"],
3511
3511
  ["PWCHAR","lpFileName","in"],
3512
3512
  ])
3513
3513
 
3514
- railgun.add_function('kernel32', 'WritePrivateProfileStructA', 'BOOL',[
3514
+ dll.add_function( 'WritePrivateProfileStructA', 'BOOL',[
3515
3515
  ["PCHAR","lpszSection","in"],
3516
3516
  ["PCHAR","lpszKey","in"],
3517
3517
  ["PBLOB","lpStruct","in"],
@@ -3519,7 +3519,7 @@ class Def_kernel32
3519
3519
  ["PCHAR","szFile","in"],
3520
3520
  ])
3521
3521
 
3522
- railgun.add_function('kernel32', 'WritePrivateProfileStructW', 'BOOL',[
3522
+ dll.add_function( 'WritePrivateProfileStructW', 'BOOL',[
3523
3523
  ["PWCHAR","lpszSection","in"],
3524
3524
  ["PWCHAR","lpszKey","in"],
3525
3525
  ["PBLOB","lpStruct","in"],
@@ -3527,7 +3527,7 @@ class Def_kernel32
3527
3527
  ["PWCHAR","szFile","in"],
3528
3528
  ])
3529
3529
 
3530
- railgun.add_function('kernel32', 'WriteProcessMemory', 'BOOL',[
3530
+ dll.add_function( 'WriteProcessMemory', 'BOOL',[
3531
3531
  ["HANDLE","hProcess","in"],
3532
3532
  ["PBLOB","lpBaseAddress","in"],
3533
3533
  ["PBLOB","lpBuffer","in"],
@@ -3535,220 +3535,220 @@ class Def_kernel32
3535
3535
  ["PDWORD","lpNumberOfBytesWritten","out"],
3536
3536
  ])
3537
3537
 
3538
- railgun.add_function('kernel32', 'WriteProfileSectionA', 'BOOL',[
3538
+ dll.add_function( 'WriteProfileSectionA', 'BOOL',[
3539
3539
  ["PCHAR","lpAppName","in"],
3540
3540
  ["PCHAR","lpString","in"],
3541
3541
  ])
3542
3542
 
3543
- railgun.add_function('kernel32', 'WriteProfileSectionW', 'BOOL',[
3543
+ dll.add_function( 'WriteProfileSectionW', 'BOOL',[
3544
3544
  ["PWCHAR","lpAppName","in"],
3545
3545
  ["PWCHAR","lpString","in"],
3546
3546
  ])
3547
3547
 
3548
- railgun.add_function('kernel32', 'WriteProfileStringA', 'BOOL',[
3548
+ dll.add_function( 'WriteProfileStringA', 'BOOL',[
3549
3549
  ["PCHAR","lpAppName","in"],
3550
3550
  ["PCHAR","lpKeyName","in"],
3551
3551
  ["PCHAR","lpString","in"],
3552
3552
  ])
3553
3553
 
3554
- railgun.add_function('kernel32', 'WriteProfileStringW', 'BOOL',[
3554
+ dll.add_function( 'WriteProfileStringW', 'BOOL',[
3555
3555
  ["PWCHAR","lpAppName","in"],
3556
3556
  ["PWCHAR","lpKeyName","in"],
3557
3557
  ["PWCHAR","lpString","in"],
3558
3558
  ])
3559
3559
 
3560
- railgun.add_function('kernel32', 'WriteTapemark', 'DWORD',[
3560
+ dll.add_function( 'WriteTapemark', 'DWORD',[
3561
3561
  ["HANDLE","hDevice","in"],
3562
3562
  ["DWORD","dwTapemarkType","in"],
3563
3563
  ["DWORD","dwTapemarkCount","in"],
3564
3564
  ["BOOL","bImmediate","in"],
3565
3565
  ])
3566
3566
 
3567
- railgun.add_function('kernel32', 'ZombifyActCtx', 'BOOL',[
3567
+ dll.add_function( 'ZombifyActCtx', 'BOOL',[
3568
3568
  ["HANDLE","hActCtx","inout"],
3569
3569
  ])
3570
3570
 
3571
- railgun.add_function('kernel32', '_hread', 'DWORD',[
3571
+ dll.add_function( '_hread', 'DWORD',[
3572
3572
  ["HANDLE","hFile","in"],
3573
3573
  ["PBLOB","lpBuffer","out"],
3574
3574
  ["DWORD","lBytes","in"],
3575
3575
  ])
3576
3576
 
3577
- railgun.add_function('kernel32', '_hwrite', 'DWORD',[
3577
+ dll.add_function( '_hwrite', 'DWORD',[
3578
3578
  ["HANDLE","hFile","in"],
3579
3579
  ["PBLOB","lpBuffer","in"],
3580
3580
  ["DWORD","lBytes","in"],
3581
3581
  ])
3582
3582
 
3583
- railgun.add_function('kernel32', '_lclose', 'DWORD',[
3583
+ dll.add_function( '_lclose', 'DWORD',[
3584
3584
  ["HANDLE","hFile","in"],
3585
3585
  ])
3586
3586
 
3587
- railgun.add_function('kernel32', '_lcreat', 'DWORD',[
3587
+ dll.add_function( '_lcreat', 'DWORD',[
3588
3588
  ["PCHAR","lpPathName","in"],
3589
3589
  ["DWORD","iAttribute","in"],
3590
3590
  ])
3591
3591
 
3592
- railgun.add_function('kernel32', '_llseek', 'DWORD',[
3592
+ dll.add_function( '_llseek', 'DWORD',[
3593
3593
  ["HANDLE","hFile","in"],
3594
3594
  ["DWORD","lOffset","in"],
3595
3595
  ["DWORD","iOrigin","in"],
3596
3596
  ])
3597
3597
 
3598
- railgun.add_function('kernel32', '_lopen', 'DWORD',[
3598
+ dll.add_function( '_lopen', 'DWORD',[
3599
3599
  ["PCHAR","lpPathName","in"],
3600
3600
  ["DWORD","iReadWrite","in"],
3601
3601
  ])
3602
3602
 
3603
- railgun.add_function('kernel32', '_lread', 'DWORD',[
3603
+ dll.add_function( '_lread', 'DWORD',[
3604
3604
  ["HANDLE","hFile","in"],
3605
3605
  ["PBLOB","lpBuffer","out"],
3606
3606
  ["DWORD","uBytes","in"],
3607
3607
  ])
3608
3608
 
3609
- railgun.add_function('kernel32', '_lwrite', 'DWORD',[
3609
+ dll.add_function( '_lwrite', 'DWORD',[
3610
3610
  ["HANDLE","hFile","in"],
3611
3611
  ["PBLOB","lpBuffer","in"],
3612
3612
  ["DWORD","uBytes","in"],
3613
3613
  ])
3614
3614
 
3615
- #railgun.add_function('kernel32', 'lstrcatA', 'PCHAR',[
3615
+ #dll.add_function( 'lstrcatA', 'PCHAR',[
3616
3616
  # ["PCHAR","lpString1","inout"],
3617
3617
  # ["PCHAR","lpString2","in"],
3618
3618
  # ])
3619
3619
 
3620
- #railgun.add_function('kernel32', 'lstrcatW', 'PWCHAR',[
3620
+ #dll.add_function( 'lstrcatW', 'PWCHAR',[
3621
3621
  # ["PWCHAR","lpString1","inout"],
3622
3622
  # ["PWCHAR","lpString2","in"],
3623
3623
  # ])
3624
3624
 
3625
- railgun.add_function('kernel32', 'lstrcmpA', 'DWORD',[
3625
+ dll.add_function( 'lstrcmpA', 'DWORD',[
3626
3626
  ["PCHAR","lpString1","in"],
3627
3627
  ["PCHAR","lpString2","in"],
3628
3628
  ])
3629
3629
 
3630
- railgun.add_function('kernel32', 'lstrcmpW', 'DWORD',[
3630
+ dll.add_function( 'lstrcmpW', 'DWORD',[
3631
3631
  ["PWCHAR","lpString1","in"],
3632
3632
  ["PWCHAR","lpString2","in"],
3633
3633
  ])
3634
3634
 
3635
- railgun.add_function('kernel32', 'lstrcmpiA', 'DWORD',[
3635
+ dll.add_function( 'lstrcmpiA', 'DWORD',[
3636
3636
  ["PCHAR","lpString1","in"],
3637
3637
  ["PCHAR","lpString2","in"],
3638
3638
  ])
3639
3639
 
3640
- railgun.add_function('kernel32', 'lstrcmpiW', 'DWORD',[
3640
+ dll.add_function( 'lstrcmpiW', 'DWORD',[
3641
3641
  ["PWCHAR","lpString1","in"],
3642
3642
  ["PWCHAR","lpString2","in"],
3643
3643
  ])
3644
3644
 
3645
- #railgun.add_function('kernel32', 'lstrcpyA', 'PCHAR',[
3645
+ #dll.add_function( 'lstrcpyA', 'PCHAR',[
3646
3646
  # ["PCHAR","lpString1","out"],
3647
3647
  # ["PCHAR","lpString2","in"],
3648
3648
  # ])
3649
3649
 
3650
- #railgun.add_function('kernel32', 'lstrcpyW', 'PWCHAR',[
3650
+ #dll.add_function( 'lstrcpyW', 'PWCHAR',[
3651
3651
  # ["PWCHAR","lpString1","out"],
3652
3652
  # ["PWCHAR","lpString2","in"],
3653
3653
  # ])
3654
3654
 
3655
- #railgun.add_function('kernel32', 'lstrcpynA', 'PCHAR',[
3655
+ #dll.add_function( 'lstrcpynA', 'PCHAR',[
3656
3656
  # ["PCHAR","lpString1","out"],
3657
3657
  # ["PCHAR","lpString2","in"],
3658
3658
  # ["DWORD","iMaxLength","in"],
3659
3659
  # ])
3660
3660
 
3661
- #railgun.add_function('kernel32', 'lstrcpynW', 'PWCHAR',[
3661
+ #dll.add_function( 'lstrcpynW', 'PWCHAR',[
3662
3662
  # ["PWCHAR","lpString1","out"],
3663
3663
  # ["PWCHAR","lpString2","in"],
3664
3664
  # ["DWORD","iMaxLength","in"],
3665
3665
  # ])
3666
3666
 
3667
- railgun.add_function('kernel32', 'lstrlenA', 'DWORD',[
3667
+ dll.add_function( 'lstrlenA', 'DWORD',[
3668
3668
  ["PCHAR","lpString","in"],
3669
3669
  ])
3670
3670
 
3671
- railgun.add_function('kernel32', 'lstrlenW', 'DWORD',[
3671
+ dll.add_function( 'lstrlenW', 'DWORD',[
3672
3672
  ["PWCHAR","lpString","in"],
3673
3673
  ])
3674
3674
 
3675
3675
 
3676
- railgun.add_function( 'kernel32', 'CreateToolhelp32Snapshot', 'DWORD',[
3676
+ dll.add_function('CreateToolhelp32Snapshot', 'DWORD',[
3677
3677
  ["DWORD","dwFlags","in"],
3678
3678
  ["DWORD","th32ProcessID","in"],
3679
3679
  ])
3680
3680
 
3681
- railgun.add_function( 'kernel32', 'Heap32First', 'BOOL',[
3681
+ dll.add_function('Heap32First', 'BOOL',[
3682
3682
  ["PBLOB","lphe","inout"],
3683
3683
  ["DWORD","th32ProcessID","in"],
3684
3684
  ["PDWORD","th32HeapID","inout"],
3685
3685
  ])
3686
3686
 
3687
- railgun.add_function( 'kernel32', 'Heap32ListFirst', 'BOOL',[
3687
+ dll.add_function('Heap32ListFirst', 'BOOL',[
3688
3688
  ["DWORD","hSnapshot","in"],
3689
3689
  ["PBLOB","lphl","inout"],
3690
3690
  ])
3691
3691
 
3692
- railgun.add_function( 'kernel32', 'Heap32ListNext', 'BOOL',[
3692
+ dll.add_function('Heap32ListNext', 'BOOL',[
3693
3693
  ["DWORD","hSnapshot","in"],
3694
3694
  ["PBLOB","lphl","inout"],
3695
3695
  ])
3696
3696
 
3697
- railgun.add_function( 'kernel32', 'Heap32Next', 'BOOL',[
3697
+ dll.add_function('Heap32Next', 'BOOL',[
3698
3698
  ["PBLOB","lphe","inout"],
3699
3699
  ])
3700
3700
 
3701
- railgun.add_function( 'kernel32', 'Module32First', 'BOOL',[
3701
+ dll.add_function('Module32First', 'BOOL',[
3702
3702
  ["DWORD","hSnapshot","in"],
3703
3703
  ["PBLOB","lpme","inout"],
3704
3704
  ])
3705
3705
 
3706
- railgun.add_function( 'kernel32', 'Module32FirstW', 'BOOL',[
3706
+ dll.add_function('Module32FirstW', 'BOOL',[
3707
3707
  ["DWORD","hSnapshot","in"],
3708
3708
  ["PBLOB","lpme","inout"],
3709
3709
  ])
3710
3710
 
3711
- railgun.add_function( 'kernel32', 'Module32Next', 'BOOL',[
3711
+ dll.add_function('Module32Next', 'BOOL',[
3712
3712
  ["DWORD","hSnapshot","in"],
3713
3713
  ["PBLOB","lpme","inout"],
3714
3714
  ])
3715
3715
 
3716
- railgun.add_function( 'kernel32', 'Module32NextW', 'BOOL',[
3716
+ dll.add_function('Module32NextW', 'BOOL',[
3717
3717
  ["DWORD","hSnapshot","in"],
3718
3718
  ["PBLOB","lpme","inout"],
3719
3719
  ])
3720
3720
 
3721
- railgun.add_function( 'kernel32', 'Process32First', 'BOOL',[
3721
+ dll.add_function('Process32First', 'BOOL',[
3722
3722
  ["DWORD","hSnapshot","in"],
3723
3723
  ["PBLOB","lppe","inout"],
3724
3724
  ])
3725
3725
 
3726
- railgun.add_function( 'kernel32', 'Process32FirstW', 'BOOL',[
3726
+ dll.add_function('Process32FirstW', 'BOOL',[
3727
3727
  ["DWORD","hSnapshot","in"],
3728
3728
  ["PBLOB","lppe","inout"],
3729
3729
  ])
3730
3730
 
3731
- railgun.add_function( 'kernel32', 'Process32Next', 'BOOL',[
3731
+ dll.add_function('Process32Next', 'BOOL',[
3732
3732
  ["DWORD","hSnapshot","in"],
3733
3733
  ["PBLOB","lppe","inout"],
3734
3734
  ])
3735
3735
 
3736
- railgun.add_function( 'kernel32', 'Process32NextW', 'BOOL',[
3736
+ dll.add_function('Process32NextW', 'BOOL',[
3737
3737
  ["DWORD","hSnapshot","in"],
3738
3738
  ["PBLOB","lppe","inout"],
3739
3739
  ])
3740
3740
 
3741
- railgun.add_function( 'kernel32', 'Thread32First', 'BOOL',[
3741
+ dll.add_function('Thread32First', 'BOOL',[
3742
3742
  ["DWORD","hSnapshot","in"],
3743
3743
  ["PBLOB","lpte","inout"],
3744
3744
  ])
3745
3745
 
3746
- railgun.add_function( 'kernel32', 'Thread32Next', 'BOOL',[
3746
+ dll.add_function('Thread32Next', 'BOOL',[
3747
3747
  ["DWORD","hSnapshot","in"],
3748
3748
  ["PBLOB","lpte","inout"],
3749
3749
  ])
3750
3750
 
3751
- railgun.add_function( 'kernel32', 'Toolhelp32ReadProcessMemory', 'BOOL',[
3751
+ dll.add_function('Toolhelp32ReadProcessMemory', 'BOOL',[
3752
3752
  ["DWORD","th32ProcessID","in"],
3753
3753
  ["PBLOB","lpBaseAddress","inout"],
3754
3754
  ["PBLOB","lpBuffer","inout"],
@@ -3756,82 +3756,82 @@ class Def_kernel32
3756
3756
  ["PDWORD","lpNumberOfBytesRead","in"],
3757
3757
  ])
3758
3758
 
3759
- railgun.add_function( 'kernel32', 'CreateToolhelp32Snapshot', 'DWORD',[
3759
+ dll.add_function('CreateToolhelp32Snapshot', 'DWORD',[
3760
3760
  ["DWORD","dwFlags","in"],
3761
3761
  ["DWORD","th32ProcessID","in"],
3762
3762
  ])
3763
3763
 
3764
- railgun.add_function( 'kernel32', 'Heap32First', 'BOOL',[
3764
+ dll.add_function('Heap32First', 'BOOL',[
3765
3765
  ["PBLOB","lphe","inout"],
3766
3766
  ["DWORD","th32ProcessID","in"],
3767
3767
  ["PDWORD","th32HeapID","inout"],
3768
3768
  ])
3769
3769
 
3770
- railgun.add_function( 'kernel32', 'Heap32ListFirst', 'BOOL',[
3770
+ dll.add_function('Heap32ListFirst', 'BOOL',[
3771
3771
  ["DWORD","hSnapshot","in"],
3772
3772
  ["PBLOB","lphl","inout"],
3773
3773
  ])
3774
3774
 
3775
- railgun.add_function( 'kernel32', 'Heap32ListNext', 'BOOL',[
3775
+ dll.add_function('Heap32ListNext', 'BOOL',[
3776
3776
  ["DWORD","hSnapshot","in"],
3777
3777
  ["PBLOB","lphl","inout"],
3778
3778
  ])
3779
3779
 
3780
- railgun.add_function( 'kernel32', 'Heap32Next', 'BOOL',[
3780
+ dll.add_function('Heap32Next', 'BOOL',[
3781
3781
  ["PBLOB","lphe","inout"],
3782
3782
  ])
3783
3783
 
3784
- railgun.add_function( 'kernel32', 'Module32First', 'BOOL',[
3784
+ dll.add_function('Module32First', 'BOOL',[
3785
3785
  ["DWORD","hSnapshot","in"],
3786
3786
  ["PBLOB","lpme","inout"],
3787
3787
  ])
3788
3788
 
3789
- railgun.add_function( 'kernel32', 'Module32FirstW', 'BOOL',[
3789
+ dll.add_function('Module32FirstW', 'BOOL',[
3790
3790
  ["DWORD","hSnapshot","in"],
3791
3791
  ["PBLOB","lpme","inout"],
3792
3792
  ])
3793
3793
 
3794
- railgun.add_function( 'kernel32', 'Module32Next', 'BOOL',[
3794
+ dll.add_function('Module32Next', 'BOOL',[
3795
3795
  ["DWORD","hSnapshot","in"],
3796
3796
  ["PBLOB","lpme","inout"],
3797
3797
  ])
3798
3798
 
3799
- railgun.add_function( 'kernel32', 'Module32NextW', 'BOOL',[
3799
+ dll.add_function('Module32NextW', 'BOOL',[
3800
3800
  ["DWORD","hSnapshot","in"],
3801
3801
  ["PBLOB","lpme","inout"],
3802
3802
  ])
3803
3803
 
3804
- railgun.add_function( 'kernel32', 'Process32First', 'BOOL',[
3804
+ dll.add_function('Process32First', 'BOOL',[
3805
3805
  ["DWORD","hSnapshot","in"],
3806
3806
  ["PBLOB","lppe","inout"],
3807
3807
  ])
3808
3808
 
3809
- railgun.add_function( 'kernel32', 'Process32FirstW', 'BOOL',[
3809
+ dll.add_function('Process32FirstW', 'BOOL',[
3810
3810
  ["DWORD","hSnapshot","in"],
3811
3811
  ["PBLOB","lppe","inout"],
3812
3812
  ])
3813
3813
 
3814
- railgun.add_function( 'kernel32', 'Process32Next', 'BOOL',[
3814
+ dll.add_function('Process32Next', 'BOOL',[
3815
3815
  ["DWORD","hSnapshot","in"],
3816
3816
  ["PBLOB","lppe","inout"],
3817
3817
  ])
3818
3818
 
3819
- railgun.add_function( 'kernel32', 'Process32NextW', 'BOOL',[
3819
+ dll.add_function('Process32NextW', 'BOOL',[
3820
3820
  ["DWORD","hSnapshot","in"],
3821
3821
  ["PBLOB","lppe","inout"],
3822
3822
  ])
3823
3823
 
3824
- railgun.add_function( 'kernel32', 'Thread32First', 'BOOL',[
3824
+ dll.add_function('Thread32First', 'BOOL',[
3825
3825
  ["DWORD","hSnapshot","in"],
3826
3826
  ["PBLOB","lpte","inout"],
3827
3827
  ])
3828
3828
 
3829
- railgun.add_function( 'kernel32', 'Thread32Next', 'BOOL',[
3829
+ dll.add_function('Thread32Next', 'BOOL',[
3830
3830
  ["DWORD","hSnapshot","in"],
3831
3831
  ["PBLOB","lpte","inout"],
3832
3832
  ])
3833
3833
 
3834
- railgun.add_function( 'kernel32', 'Toolhelp32ReadProcessMemory', 'BOOL',[
3834
+ dll.add_function('Toolhelp32ReadProcessMemory', 'BOOL',[
3835
3835
  ["DWORD","th32ProcessID","in"],
3836
3836
  ["PBLOB","lpBaseAddress","inout"],
3837
3837
  ["PBLOB","lpBuffer","inout"],
@@ -3839,6 +3839,7 @@ class Def_kernel32
3839
3839
  ["PDWORD","lpNumberOfBytesRead","in"],
3840
3840
  ])
3841
3841
 
3842
+ return dll
3842
3843
  end
3843
3844
 
3844
3845
  end