Add support for RSA-OAEP-384 and RSA-OAEP-512 #1142
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request would add support for the
RSA-OAEP-384
andRSA-OAEP-512
key encryption algorithms. I think this is just a minor change as the base algorithmsRSA-OAEP
andRSA-OAEP-256
are already implemented. The only difference these new algorithms have is that they use a different hashing algorithmSHA384
andSHA512
respectively instead ofSHA1
orSHA256
.The hashing algorithms
SHA384
andSHA512
are already used in different algorithms, so these are not new. The only thing I wasn't sure about it how the following case should be handled:permalink
In the original code the
'hash'.New()
method was used, so I continued this usage, however when searching where theSHA384
andSHA512
algorithms were used already I found an other method which would result in this diff:I am not sure which one would be preferred (I assumed the method that was already used).
If I missed something or there is a reason these algorithms weren't implemented I would love to hear it.