Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
N
nettle
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor 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
Brian Smith
nettle
Commits
ef8b4e8e
Commit
ef8b4e8e
authored
21 years ago
by
Niels Möller
Browse files
Options
Downloads
Patches
Plain Diff
(cbc_encrypt, cbc_decrypt): Use a _const_ void *ctx argument.
Rev: src/nettle/cbc.c:1.9 Rev: src/nettle/cbc.h:1.6
parent
688f5b22
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
cbc.c
+9
-9
9 additions, 9 deletions
cbc.c
cbc.h
+6
-6
6 additions, 6 deletions
cbc.h
with
15 additions
and
15 deletions
cbc.c
+
9
−
9
View file @
ef8b4e8e
...
...
@@ -37,9 +37,9 @@
#include
"nettle-internal.h"
void
cbc_encrypt
(
void
*
ctx
,
void
(
*
f
)(
void
*
ctx
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
),
cbc_encrypt
(
const
void
*
ctx
,
void
(
*
f
)(
const
void
*
ctx
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
),
unsigned
block_size
,
uint8_t
*
iv
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
)
...
...
@@ -56,9 +56,9 @@ cbc_encrypt(void *ctx, void (*f)(void *ctx,
/* Reqires that dst != src */
static
void
cbc_decrypt_internal
(
void
*
ctx
,
void
(
*
f
)(
void
*
ctx
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
),
cbc_decrypt_internal
(
const
void
*
ctx
,
void
(
*
f
)(
const
void
*
ctx
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
),
unsigned
block_size
,
uint8_t
*
iv
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
)
...
...
@@ -80,9 +80,9 @@ cbc_decrypt_internal(void *ctx, void (*f)(void *ctx,
#define CBC_BUFFER_LIMIT 4096
void
cbc_decrypt
(
void
*
ctx
,
void
(
*
f
)(
void
*
ctx
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
),
cbc_decrypt
(
const
void
*
ctx
,
void
(
*
f
)(
const
void
*
ctx
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
),
unsigned
block_size
,
uint8_t
*
iv
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
)
...
...
This diff is collapsed.
Click to expand it.
cbc.h
+
6
−
6
View file @
ef8b4e8e
...
...
@@ -35,17 +35,17 @@
/* Uses a void * for cipher contexts. */
void
cbc_encrypt
(
void
*
ctx
,
void
(
*
f
)(
void
*
ctx
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
),
cbc_encrypt
(
const
void
*
ctx
,
void
(
*
f
)(
const
void
*
ctx
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
),
unsigned
block_size
,
uint8_t
*
iv
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
);
void
cbc_decrypt
(
void
*
ctx
,
void
(
*
f
)(
void
*
ctx
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
),
cbc_decrypt
(
const
void
*
ctx
,
void
(
*
f
)(
const
void
*
ctx
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
),
unsigned
block_size
,
uint8_t
*
iv
,
unsigned
length
,
uint8_t
*
dst
,
const
uint8_t
*
src
);
...
...
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