SDK Crypt API documentation

Version: stable

FUNCTION
dmCrypt::Base64Decode()

Base64 decode a buffer

dmCrypt::Base64Encode()

Base64 encode a buffer

dmCrypt::HashMd5()

Hash buffer using MD5

dmCrypt::HashSha1()

Hash buffer using SHA1

dmCrypt::HashSha256()

Hash buffer using SHA256

dmCrypt::HashSha512()

Hash buffer using SHA512

Functions

dmCrypt::Base64Decode()

dmCrypt::Base64Decode(src,src_len,dst,dst_len[in,out])

PARAMETERS

src
          The source data to encode
src_len
      The length of source data in bytes
dst
          The destination buffer
dst_len[in,out]

In: The length of the destination in bytes. Out: The length of the decoded string.

RETURNS

true

if the decoding went ok


dmCrypt::Base64Encode()

dmCrypt::Base64Encode(src,src_len,dst,dst_len[in,out])

PARAMETERS

src
          The source data to encode
src_len
      The length of source data in bytes
dst
          The destination buffer
dst_len[in,out]

In: The length of the destination in bytes. Out: The length of the encoded string.

RETURNS

true

if the encoding went ok


dmCrypt::HashMd5()

dmCrypt::HashMd5(buf,buflen,digest)

PARAMETERS

buf
  The source data to hash
buflen

The length of source data in bytes

digest

The destination buffer (16 bytes)


dmCrypt::HashSha1()

dmCrypt::HashSha1(buf,buflen,digest)

PARAMETERS

buf
  The source data to hash
buflen

The length of source data in bytes

digest

The destination buffer (20 bytes)


dmCrypt::HashSha256()

dmCrypt::HashSha256(buf,buflen,digest)

PARAMETERS

buf
  The source data to hash
buflen

The length of source data in bytes

digest

The destination buffer (32 bytes)


dmCrypt::HashSha512()

dmCrypt::HashSha512(buf,buflen,digest)

PARAMETERS

buf
  The source data to hash
buflen

The length of source data in bytes

digest

The destination buffer (64 bytes)