Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8245385
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T22:09:39+00:00 2026-06-07T22:09:39+00:00

I am implementing an AES cipher in GCM mode in c#. My question pertains

  • 0

I am implementing an AES cipher in GCM mode in c#. My question pertains to the “additional authenticated data”(AAD). In the following code from

http://blogs.msdn.com/b/shawnfa/archive/2009/03/17/authenticated-symmetric-encryption-in-net.aspx

it is unclear where I should get the AAD from, and how I should retrieve the AAD specific to this encryption during decryption:

// Authenticated data becomes part of the authentication tag that is generated during
// encryption, however it is not part of the ciphertext.  That is, when decrypting the
// ciphertext the authenticated data will not be produced.  However, if the
// authenticated data does not match at encryption and decryption time, the
// authentication tag will not validate.
aes.AuthenticatedData = Encoding.UTF8.GetBytes("Additional authenticated data");

Any clarification on how to use this AAD would be much appreciated.
Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T22:09:40+00:00Added an answer on June 7, 2026 at 10:09 pm

    AAD stands for Additional Authenticated Data or Additional Associated Data. This is data that can be send in the clear together with the cipher text. Both the cipher text and the AAD are validated for integrity when you perform the combined verification and decryption of an AEAD cipher.

    AAD data is not a key, it’s just plain data you can include in your protocol which needs to be protected for integrity, but does not need (or, more logically, would not be useful with) encryption. A good example would be a header of an encrypted IP packet; if you encrypt it you cannot use it for routing, if you don’t protect it’s integrity, an attacker may change the message length or source address without the receiver knowing about it.

    Note that AEAD ciphers already include the IV / nonce in the calculation of the authentication tag. It is therefore unnecessary to include it in the AAD. The AAD is often used to include sender, receiver and possibly message identification number – if that’s present outside of the encrypted part of the message.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

While implementing the code from this question on my project I realized there's 3
When implementing HTTP services in node.js, there is a lot of sample code like
I'm implementing encryption / decryption using Java Cipher and AES. Everything is working well
Implementing equals() and hashCode() for simple data POJOs is cluttering my code and maintaining
I am implementing AES-256 bit encrpytion in my web app: http://www.utoxin.name/2009/07/automatic-db-field-encryption-in-cakephp/ One of the
i am implementing AES algorithm in c from aes encryption program and also we
implementing publishActivity in PHP using the REST API using this code: $activity = array(
When implementing the Strategy Pattern, where does one put the code that determines which
I am implementing a small demo application which encrypts using AES CTR with OpenSSL
I have been implementing AES onto my website for security and I have ran

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.