Skip to content

ensure cipher memory safety #190

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 8, 2013
Merged

ensure cipher memory safety #190

merged 1 commit into from
Dec 8, 2013

Conversation

julienschmidt
Copy link
Member

If no second cipher part is received, the cipher can be overwritten since it is just a slice from the net buffer

}

return cipher, nil
// make a memory safe copy of the cipher slice
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"memory safe" - that's a weird comment.
What does it mean in this context; why copy, how could it be corrupted otherwise?

@arnehormann
Copy link
Member

Doh... sorry, I'm tired. Ignore my comment, LGTM

julienschmidt added a commit that referenced this pull request Dec 8, 2013
@julienschmidt julienschmidt merged commit b1aa46e into master Dec 8, 2013
@julienschmidt julienschmidt deleted the cipher_memsafe branch December 8, 2013 11:46
@julienschmidt julienschmidt added this to the v1.2 milestone Apr 1, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants