-
Notifications
You must be signed in to change notification settings - Fork 63
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
Set of a new hash computing functions (SP1) #141
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll just skip repeating what cppcheck said and idicate, that the fact that it is "green" does not mean it did not find issues ;-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
First look from me, I'll dig into the code tomorrow some more.
This function will be used in different places in the code, so I moved it to a separate file. Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
Prepared a new set of functions for computing digest with error handling. The hash context has been placed into a separate structure. This allows to conveniently pass the calculated digest along with its length and used algorithm. Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
Switched to use new hash functions. The parameter list for the rimage_sign and rimage_verify functions has been simplified. The necessary information is now included in the hash_context structure. In addition, code fragments that may be common to different versions of the manifest have been separated. Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
Removed currently unused functions. Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
Fields related to hash computing have been removed from the image structure. Removed openssl headers from rimage.h, which made it necessary to add some missing includes in several files. Signed-off-by: Adrian Warecki <adrian.warecki@intel.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It slowly starts to look like a program, good job ;-)
I assume you had tested it on both windows and linux yes?
This does not compile, fix submitted in #144 |
It's pretty easy to submit a temporary/draft/throw-away |
Moved byte_swap function to a new misc_utils.c file. This function will be used in different places in the code.
Prepared a set of fa new unctions for computing digest with error handling. The hash context has been placed into a separate structure. This allows to conveniently pass the calculated digest along with its length and used algorithm.
Switched to use new hash functions. The parameter list for the rimage_sign and rimage_verify functions has been simplified. The necessary information is now included in the hash_context structure. In addition, code fragments that may be common to different versions of the manifest have been separated.
Fields related to hash computing have been removed from the image structure. Removed openssl headers from rimage.h, which made it necessary to add some missing includes in several files.