Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
Tor
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Benjamin J. Thompson
Tor
Commits
dca3c9ff
Commit
dca3c9ff
authored
13 years ago
by
Nick Mathewson
Browse files
Options
Downloads
Patches
Plain Diff
Add missing documentation for counter-mode checks
parent
cc5c14b7
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/common/aes.c
+12
-5
12 additions, 5 deletions
src/common/aes.c
with
12 additions
and
5 deletions
src/common/aes.c
+
12
−
5
View file @
dca3c9ff
...
...
@@ -47,8 +47,8 @@
* OpenSSL pre-1.0 (by about 10%!). But OpenSSL 1.0.0 added a counter mode
* implementation faster than the one here (by about 7%). So we pick which
* one to used based on the Openssl version above. (OpenSSL 1.0.0a fixed a
* critical bug in that counter mode implementation, so we
actually require
*
that
on
e
.)
* critical bug in that counter mode implementation, so we
need to test to
*
make sure that we have a fixed versi
on.)
*/
/*======================================================================*/
...
...
@@ -90,12 +90,13 @@ struct aes_cnt_cipher {
uint8_t
using_evp
;
};
/** True if we should prefer the EVP implementation for AES, either because
/** True if
f
we should prefer the EVP implementation for AES, either because
* we're testing it or because we have hardware acceleration configured */
static
int
should_use_EVP
=
0
;
#ifdef CAN_USE_OPENSSL_CTR
/**DOCDOC*/
/** True iff we have tested the counter-mode implementation and found that it
* doesn't have the counter-mode bug from OpenSSL 1.0.0. */
static
int
should_use_openssl_CTR
=
0
;
#endif
...
...
@@ -129,7 +130,13 @@ evaluate_evp_for_aes(int force_val)
return
0
;
}
/**DOCDOC*/
/** Test the OpenSSL counter mode implementation to see whether it has the
* counter-mode bug from OpenSSL 1.0.0. If the implementation works, then
* we will use it for future encryption/decryption operations.
*
* We can't just look at the OpenSSL version, since some distributions update
* their OpenSSL packages without changing the version number.
**/
int
evaluate_ctr_for_aes
(
void
)
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment