Skip to content

Commit 071f995

Browse files
author
文pig4210
committed
pig4210 updata for blowfish
1 parent 8997012 commit 071f995

13 files changed

+118
-14
lines changed

ExtendLuaForWireshark.v12.suo

9 KB
Binary file not shown.

LuaPlugins/lua.exe

468 KB
Binary file not shown.

LuaPlugins/lua52.dll

1.95 MB
Binary file not shown.

LuaPlugins/lua52.exe

101 KB
Binary file not shown.

Pack.bat

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ echo Lua·
2525
echo 合并xlua文件...
2626

2727
rem 初始化合并脚本、合并注释
28-
set xlua_ver=3.2
28+
set xlua_ver=3.3
2929
echo xlua_ver = %xlua_ver%>%DestLua%
3030
echo xlua版本 %xlua_ver%>%DestCmt%
3131

luadll/luadll.vcxproj

+2
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
<ItemGroup>
1414
<ClCompile Include="..\..\xlualib\laes.cpp" />
1515
<ClCompile Include="..\..\xlualib\lalgorithm.cpp" />
16+
<ClCompile Include="..\..\xlualib\lblowfish.cpp" />
1617
<ClCompile Include="..\..\xlualib\ldes.cpp" />
1718
<ClCompile Include="..\..\xlualib\lhex_str.cpp" />
1819
<ClCompile Include="..\..\xlualib\lmkmem.cpp" />
@@ -63,6 +64,7 @@
6364
<ItemGroup>
6465
<ClInclude Include="..\..\xlualib\laes.h" />
6566
<ClInclude Include="..\..\xlualib\lalgorithm.h" />
67+
<ClInclude Include="..\..\xlualib\lblowfish.h" />
6668
<ClInclude Include="..\..\xlualib\ldes.h" />
6769
<ClInclude Include="..\..\xlualib\lhex_str.h" />
6870
<ClInclude Include="..\..\xlualib\lmkmem.h" />

luadll/luadll.vcxproj.filters

+6
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,9 @@
160160
<ClCompile Include="..\src\lzio.c">
161161
<Filter>lua</Filter>
162162
</ClCompile>
163+
<ClCompile Include="..\..\xlualib\lblowfish.cpp">
164+
<Filter>xlua</Filter>
165+
</ClCompile>
163166
</ItemGroup>
164167
<ItemGroup>
165168
<ClInclude Include="..\..\xlualib\lalgorithm.h">
@@ -285,6 +288,9 @@
285288
<ClInclude Include="resource.h">
286289
<Filter>extend</Filter>
287290
</ClInclude>
291+
<ClInclude Include="..\..\xlualib\lblowfish.h">
292+
<Filter>xlua</Filter>
293+
</ClInclude>
288294
</ItemGroup>
289295
<ItemGroup>
290296
<ResourceCompile Include="luadll.rc">

x64/lua52.dll

15 KB
Binary file not shown.

x64/lua52.lib

0 Bytes
Binary file not shown.

x86/lua52.dll

12 KB
Binary file not shown.

x86/lua52.lib

0 Bytes
Binary file not shown.

xlua.lua

1.92 KB
Binary file not shown.

xlua.txt

+109-13
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
xlua�汾 3.2
1+
xlua�汾 3.3
22

33

44
-------- -------- -------- --------
@@ -17,15 +17,15 @@ AES
1717
string data,
1818
string key
1919
[,
20-
int block_size = 8
20+
int block_size = 16
2121
]
2222
); [-2|3, +1, c|v]
2323
string aes_ecb_pkcs7padding_decrypt
2424
(
2525
string data,
2626
string key
2727
[,
28-
int block_size = 8
28+
int block_size = 16
2929
]
3030
); [-2|3, +1, c|v]
3131
string aes.ecb.p7enc ( ... ); [-2|3, +1, c|v]
@@ -39,7 +39,7 @@ AES
3939
string key
4040
[,
4141
string ivec = "\0\0\0\0\0\0\0\0",
42-
int block_size = 8
42+
int block_size = 16
4343
]
4444
); [-2|3|4, +1, c|v]
4545
string aes_cbc_pkcs7padding_decrypt
@@ -48,7 +48,7 @@ AES
4848
string key
4949
[,
5050
string ivec = "\0\0\0\0\0\0\0\0",
51-
int block_size = 8
51+
int block_size = 16
5252
]
5353
); [-2|3|4, +1, c|v]
5454
string aes.cbc.p7enc ( ... ); [-2|3|4, +1, c|v]
@@ -62,29 +62,29 @@ AES
6262
string data,
6363
string key
6464
[,
65-
int block_size = 8
65+
int block_size = 16
6666
]
6767
); [-2|3, +1, c|v]
6868
string aes_ecb_decrypt
6969
(
7070
string data,
7171
string key
7272
[,
73-
int block_size = 8
73+
int block_size = 16
7474
]
7575
); [-2|3, +1, c|v]
76-
string aes.ecb.enc ( ... ); [-2|3, +1, c|v]
77-
string aes.ecb.enc ( ... ); [-2|3, +1, c|v]
78-
string string:aes_ecb_enc ( ... ); [-1|2, +1, c|v]
79-
string string:aes_ecb_dec ( ... ); [-1|2, +1, c|v]
76+
string aes.ecb.enc ( ... ); [-2|3, +1, c|v]
77+
string aes.ecb.enc ( ... ); [-2|3, +1, c|v]
78+
string string:aes_ecb_enc ( ... ); [-1|2, +1, c|v]
79+
string string:aes_ecb_dec ( ... ); [-1|2, +1, c|v]
8080

8181
string aes_cbc_encrypt
8282
(
8383
string data,
8484
string key
8585
[,
8686
string ivec = "\0\0\0\0\0\0\0\0",
87-
int block_size = 8
87+
int block_size = 16
8888
]
8989
); [-2|3|4, +1, c|v]
9090
string aes_cbc_decrypt
@@ -93,7 +93,7 @@ AES
9393
string key
9494
[,
9595
string ivec = "\0\0\0\0\0\0\0\0",
96-
int block_size = 8
96+
int block_size = 16
9797
]
9898
); [-2|3|4, +1, c|v]
9999
string aes.cbc.enc ( ... ); [-2|3|4, +1, c|v]
@@ -182,6 +182,102 @@ AES
182182

183183

184184

185+
-------- -------- -------- --------
186+
BLOWFISH
187+
-------- -------- -------- --------
188+
BLOWFISH���ܣ�ʹ��paddingʱ���Զ�pkcs7padding�����򲻶��벿�ֲ����ܣ�����֮
189+
BLOWFISH���ܣ������벿�ֲ����ܣ�����֮
190+
��ʹ��paddingʱ��Ĭ�Ͽ��С==8
191+
�ṩ��KEY���Ȳ���8ʱ����0����
192+
193+
194+
195+
��
196+
string blowfish_ecb_pkcs7padding_encrypt
197+
(
198+
string data,
199+
string key
200+
); [-2|3, +1, c|v]
201+
string blowfish_ecb_pkcs7padding_decrypt
202+
(
203+
string data,
204+
string key
205+
); [-2|3, +1, c|v]
206+
string blowfish.ecb.p7enc ( ... ); [-2|3, +1, c|v]
207+
string blowfish.ecb.p7dec ( ... ); [-2|3, +1, c|v]
208+
string string:bf_ecb_p7_enc ( ... ); [-1|2, +1, c|v]
209+
string string:bf_ecb_p7_dec ( ... ); [-1|2, +1, c|v]
210+
211+
string blowfish_cbc_pkcs7padding_encrypt
212+
(
213+
string data,
214+
string key
215+
[,
216+
string ivec = "\0\0\0\0\0\0\0\0"
217+
]
218+
); [-2|3|4, +1, c|v]
219+
string blowfish_cbc_pkcs7padding_decrypt
220+
(
221+
string data,
222+
string key
223+
[,
224+
string ivec = "\0\0\0\0\0\0\0\0",
225+
int block_size = 16
226+
]
227+
); [-2|3|4, +1, c|v]
228+
string blowfish.cbc.p7enc ( ... ); [-2|3|4, +1, c|v]
229+
string blowfish.cbc.p7dec ( ... ); [-2|3|4, +1, c|v]
230+
string string:bf_cbc_p7_enc ( ... ); [-1|2|3, +1, c|v]
231+
string string:bf_cbc_p7_dec ( ... ); [-1|2|3, +1, c|v]
232+
233+
-------- -------- -------- --------
234+
string blowfish_ecb_encrypt
235+
(
236+
string data,
237+
string key
238+
[,
239+
int block_size = 16
240+
]
241+
); [-2|3, +1, c|v]
242+
string blowfish_ecb_decrypt
243+
(
244+
string data,
245+
string key
246+
[,
247+
int block_size = 16
248+
]
249+
); [-2|3, +1, c|v]
250+
string blowfish.ecb.enc ( ... ); [-2|3, +1, c|v]
251+
string blowfish.ecb.enc ( ... ); [-2|3, +1, c|v]
252+
string string:bf_ecb_enc ( ... ); [-1|2, +1, c|v]
253+
string string:bf_ecb_dec ( ... ); [-1|2, +1, c|v]
254+
255+
string blowfish_cbc_encrypt
256+
(
257+
string data,
258+
string key
259+
[,
260+
string ivec = "\0\0\0\0\0\0\0\0",
261+
int block_size = 16
262+
]
263+
); [-2|3|4, +1, c|v]
264+
string blowfish_cbc_decrypt
265+
(
266+
string data,
267+
string key
268+
[,
269+
string ivec = "\0\0\0\0\0\0\0\0",
270+
int block_size = 16
271+
]
272+
); [-2|3|4, +1, c|v]
273+
string blowfish.cbc.enc ( ... ); [-2|3|4, +1, c|v]
274+
string blowfish.cbc.dec ( ... ); [-2|3|4, +1, c|v]
275+
string string:bf_cbc_enc ( ... ); [-1|2|4, +1, c|v]
276+
string string:bf_cbc_dec ( ... ); [-1|2|4, +1, c|v]
277+
278+
279+
280+
185281
-------- -------- -------- --------
186282
DES
187283
-------- -------- -------- --------

0 commit comments

Comments
 (0)