Skip to content

Commit 9a97432

Browse files
committed
md5和sha转换默认返回hex
1 parent f82f249 commit 9a97432

4 files changed

Lines changed: 13 additions & 7 deletions

File tree

changlog/autoUpdate.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<item>
3-
<version>1.0.4.1</version>
3+
<version>1.0.4.2</version>
44
<url>https://llcom.papapoi.com/llcom.zip</url>
55
<changelog>https://llcom.papapoi.com/changelog.html</changelog>
66
<mandatory mode="1">true</mandatory>

changlog/index.html

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,12 @@
1111

1212
> 欢迎加入交流群:`931546484`
1313

14+
## LLCOM 1.0.4.2
15+
16+
- md5和sha转换默认返回hex
17+
18+
---
19+
1420
## LLCOM 1.0.4.1
1521

1622
- 更正编码转换列表为空时,删除崩溃的bug

llcom/Pages/ConvertPage.xaml.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -88,10 +88,10 @@ private void ConvertButton_Click(object sender, RoutedEventArgs e)
8888
["HTML decode"] = (e) => Encoding.Default.GetBytes(System.Web.HttpUtility.HtmlDecode(Encoding.Default.GetString(e))),
8989
["String to Unicode"] = (e) => Encoding.Default.GetBytes(String2Unicode(Encoding.Default.GetString(e))),
9090
["Unicode to String"] = (e) => Encoding.Default.GetBytes(Unicode2String(Encoding.Default.GetString(e))),
91-
["String to MD5 (bytes)"] = (e) => MD5Encrypt(e),
92-
["String to SHA-1 (bytes)"] = (e) => Sha1Encrypt(e),
93-
["String to SHA-256 (bytes)"] = (e) => Sha256Encrypt(e),
94-
["String to SHA-512 (bytes)"] = (e) => Sha512Encrypt(e),
91+
["String to MD5 (Hex)"] = (e) => Encoding.Default.GetBytes(BitConverter.ToString(MD5Encrypt(e)).Replace("-", "")),
92+
["String to SHA-1 (Hex)"] = (e) => Encoding.Default.GetBytes(BitConverter.ToString(Sha1Encrypt(e)).Replace("-", "")),
93+
["String to SHA-256 (Hex)"] = (e) => Encoding.Default.GetBytes(BitConverter.ToString(Sha256Encrypt(e)).Replace("-", "")),
94+
["String to SHA-512 (Hex)"] = (e) => Encoding.Default.GetBytes(BitConverter.ToString(Sha512Encrypt(e)).Replace("-", "")),
9595
};
9696

9797
public static byte[] Hex2byte(string mHex)

llcom/Properties/AssemblyInfo.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@
5151
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
5252
//通过使用 "*",如下所示:
5353
// [assembly: AssemblyVersion("1.0.*")]
54-
[assembly: AssemblyVersion("1.0.4.1")]
55-
[assembly: AssemblyFileVersion("1.0.4.1")]
54+
[assembly: AssemblyVersion("1.0.4.2")]
55+
[assembly: AssemblyFileVersion("1.0.4.2")]
5656
[assembly: NeutralResourcesLanguage("zh-CN")]
5757

0 commit comments

Comments
 (0)