Skip to content
Browse files

[fix] Crypto.Base64: better implementation, not using OCaml Crypto lib

  • Loading branch information...
1 parent c04274b commit 3ec1811913028a7e61b36db0926a78500aa510aa @Aqua-Ye Aqua-Ye committed Dec 4, 2011
Showing with 4 additions and 2 deletions.
  1. +4 −2 plugins/crypto/bslCrypto.ml
View
6 plugins/crypto/bslCrypto.ml
@@ -20,11 +20,13 @@ let md5 = (fun x -> Digest.to_hex (Digest.string x))
##register base64_encode : string -> string
let base64_encode str =
- Cryptokit.transform_string (Cryptokit.Base64.encode_multiline ()) str
+ BaseString.base64encode str
+ (* Cryptokit.transform_string (Cryptokit.Base64.encode_compact ()) str *)
##register base64_decode : string -> string
let base64_decode str =
- Cryptokit.transform_string (Cryptokit.Base64.decode ()) str
+ BaseString.base64decode str
+ (* Cryptokit.transform_string (Cryptokit.Base64.decode ()) str *)
##register hmac_sha1 : string, string -> string
let hmac_sha1 key text =

0 comments on commit 3ec1811

Please sign in to comment.
Something went wrong with that request. Please try again.