php sodium 加密解密,sodium库(加密)
sodium庫(加密)
Addlargenumbers
Encodetohexadecimal
Comparelargenumbers
Decryptincombinedmodewithprecalculation
Encryptincombinedmodewithprecalculation
Verifiesthatthetagisvalidforthemessage
Computeatagforthemessage
Randomlygenerateasecretkeyandacorrespondingpublickey
Verifyanddecryptaciphertext
Deterministicallyderivethekeypairfromasinglekey
Verifythatthepasswordisavalidpasswordverificationstring
Verifiesthatapasswordmatchesahash
Deriveakeyfromapassword
別名sodium_crypto_box_publickey_from_secretkey()
Computeasharedsecretgivenauser'ssecretkeyandanotheruser'spublickey
Computeafixed-sizefingerprintforthemessage
ConvertanEd25519publickeytoaCurve25519publickey
ConvertanEd25519secretkeytoaCurve25519secretkey
Randomlygenerateasecretkeyandacorrespondingpublickey
Checkthatthesignedmessagehasavalidsignature
Deterministicallyderivethekeypairfromasinglekey
Generateadeterministicsequenceofbytesfromaseed
Decodesahexadecimallyencodedbinarystring
Incrementlargenumber
Testforequalityinconstant-time
Overwritebufwithzeros
Addpaddingdata
Removepaddingdata
mcrypt 在 PHP 7.2 中已經移除,用sodium庫替代
安裝
從PHP 7.2.0開始,這個擴展與PHP捆綁在一起。對于較舊的PHP版本,此擴展可通過PECL獲得。
為了使用這個擴展,您必須使用--with-nadier[=DIR]配置選項編譯PHP。
window上,要使用此擴展,必須將extension=php_nadium.dll添加到php.ini。
總結
以上是生活随笔為你收集整理的php sodium 加密解密,sodium库(加密)的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: MariaDB安装1,2
- 下一篇: php获取本月工作日,ThinkPHP中