Esempio n. 1
0
def mac(lang: Text, keyset: bytes) -> _primitives.Mac:
    """Returns a MAC primitive, implemented in lang."""
    global _ts
    return _primitives.Mac(lang, _ts.mac_stub(lang), keyset)
Esempio n. 2
0
def mac(lang: Text, keyset_handle: tink.KeysetHandle) -> _primitives.Mac:
  """Returns an AEAD primitive, implemented in lang."""
  global _ts
  return _primitives.Mac(lang, _ts.mac_stub(lang), keyset_handle)