Hmac working without generics, and test not working yet - #5652
Conversation
9bbb4f6 to
b54f0ca
Compare
|
Running |
|
Will do, I've been procrastinating it for a bit since I'm trying to get passing digestmod functions as arguments working. Hopefully, it should be up and done this weekend. |
|
So I gave up on passing in function for a bit since HmacCore requires strict traits on the class passed into it's generic. Maybe functions can be easily done if we make the function name public and pass in the relevant hash function into it depending on the function name, but that might not be worth it since I'm sure there's reasons not to make pyfunction names public, and also it would only work for the specific hashlib hash functions. I guess the options potentially are an HmacCore rewrite where we don't require as strict compile time checks on the passed hash function, or maybe there is a way to use generics that I'm just not that familiar with rust to see. |
This is a draft PR just to show what I have so far, the things I want to do before pulling in the PR are:
Other than that, playing with what I have vs the cpython version they output the same bytes when digesting.