fache 0.1.312

发车工具箱
Documentation
1
2
3
4
5
6
7
8
use md5::compute;
pub trait MiMa {
    // MD5 加密密码 且密码为小写
    fn md5_password(password: String) -> String {
        let digest = compute(password.as_bytes());
        format!("{:x}", digest) // {:x}强制小写
    }
}