Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: diafygi/webcrypto-examples
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: master
Choose a base ref
...
head repository: afitzek/webcrypto-examples
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
Can’t automatically merge. Don’t worry, you can still create the pull request.
  • 2 commits
  • 1 file changed
  • 1 contributor

Commits on Jul 17, 2015

  1. description of additionalData for AES-GCM

    added description for additionalData for AES-GCM
    afitzek committed Jul 17, 2015
    Copy the full SHA
    ed5b6fb View commit details
  2. Merge pull request #1 from andi506/additionalData-comment-clarification

    description of additionalData for AES-GCM
    afitzek committed Jul 17, 2015
    Copy the full SHA
    09f8e98 View commit details
Showing with 8 additions and 1 deletion.
  1. +8 −1 README.md
9 changes: 8 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -978,8 +978,15 @@ window.crypto.subtle.encrypt(
//Always generate a new iv every time your encrypt!
iv: window.crypto.getRandomValues(new Uint8Array(16)),

//Additional authentication data (unsure what proper use for this is)
//Additional authenticated data:
//AES-GCM protects the confidentiality and the integrity. The additionalData is not
//encrypted but the integrity is stil protected.
//Decryption will only succeed if the additionalData is the same during
//decryption and encryption.
//This is an optional property.
additionalData: window.crypto.getRandomValues(new Uint8Array(256)),

//Length of the authentication tag
tagLength: 128,
};
},