scala-js/scala-js-dom

def decrypt(algorithm: KeyAlgorithmIdentifier, ...)

bblfish opened this issue · 2 comments

@povder started a discussion on an already committed PR about the method SubtleCrypto.decrypt(algorithm: KeyAlgorithmIdentifier, key: CryptoKey, ...).

In summary either:

  1. algorithm should be extended to type AlgorithmIdentifier
  2. AesGcmParams should extend KeyAlgorithmIdentifier
  1. may be closer to the official spec, but for a newbie like me it's a bit odd that one could decrypt something with a hash algorithm.
  2. would require a cryptographer to verify the logic of what we are doing

Please see PR #190