-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Fix PrivParams for SNMPv3 USM with AES privacy #2544
Conversation
This is a continuation of #1874. |
I have added the testing label. But as we have code freeze on |
Thank you, @bmk. Clearly, I'm in no great rush. :) |
Hi, First night of testrun, and we have a failure. https://gist.github.com/bmk/0a049cda6fa13cbc0d3daaaa29aff4a6 Another thing was that this test case, just as I have tweaked your test case a bit (to fix this). Another thing is that although you have indicated And here are my changes:
I will, for now, replace your branch with mine (which is based on yours). Regards, |
Unfortunately, I'm unable to see the log. Is that because it's secret? I didn't even realize I could add pre- and post-test functions. Thanks for the clean-up. Oops... I meant to merge to maint, but if the test fails against master, then the mistake was serendipitous. I'll see if I can find the problem, today. |
Stupidly, I never tested that I could access the file. I just assumed it worked. I previously just used to the pre and post fun:s for starting and That it could have something to do with master is just a guess. I have vacation tomorrow, so you have plenty of time :) Regards, |
I've been guilty of stupider. :) I'll see what I can sort out. Have a great vacation! |
* In `snmp_usm:do_decrypt/3`, pass full UsmSecParams to `snmp_usm:try_decrypt/5` as expected by AES clause. * Change `snmpm_usm:aes_encrypt/3` to use EngineBoots and EngineTime as cached by `snmpm_config:get_usm_eboots/1` and `snmpm_config:get_usm_etime/1` instead of `snmpm_config:get_engine_boots/0` and `snmpm_config:get_engine_time/0`. This ensures correct msgPrivacyParameters are sent when AES is used. * Add test `snmp.snmp_manager_SUITE.usm_priv_aes/1` to avoid regression. * Fix counting bug in `snmp_usm` macro `?BLOCK_CIPHER_AES`, introduced by commit 8d942cd.
08a4687
to
c7f575d
Compare
Fixed counting bug in |
Hi, |
I had originally intended to merge against maint, but finding the bug in master, I thought I should merge against that, instead. If you think I should bring it back to maint, though, I certainly will. |
Master it is then :) |
Hi, Merged "my branch" (with my two commits) with your commit (d98b111) Are there any remaining issues? I see that you have merged master into this branch. |
Sorry, I was notified of conflicts, so I resolved them through GitHub. In retrospect, that was a mistake, and I should have performed the usual rebase and merge, myself, rather than use the site. I can see master shows the new commits, so I'll close this now. Thanks so much for all your help! |
Not a problem. Thanks for the contributions. Keep them coming :) |
In
snmp_usm:do_decrypt/3
, pass full UsmSecParams tosnmp_usm:try_decrypt/5
as expected by AES clause.Change
snmpm_usm:aes_encrypt/3
to use EngineBoots andEngineTime as cached by
snmpm_config:get_usm_eboots/1
and
snmpm_config:get_usm_etime/1
instead ofsnmpm_config:get_engine_boots/0
andsnmpm_config:get_engine_time/0
. This ensures correctmsgPrivacyParameters are sent when AES is used.
Add test
snmp.snmp_manager_SUITE.usm_priv_aes/1
toavoid regression.