Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
B
babeld
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
babeld
Commits
9529941b
Commit
9529941b
authored
Nov 20, 2019
by
Antonin Décimo
Committed by
Juliusz Chroboczek
May 30, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use AUTH_TYPE_NONE consistently.
parent
d922b64a
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
4 deletions
+3
-4
configuration.c
configuration.c
+0
-1
hmac.c
hmac.c
+1
-1
message.c
message.c
+2
-2
No files found.
configuration.c
View file @
9529941b
...
...
@@ -783,7 +783,6 @@ parse_key(int c, gnc_t gnc, void *closure, struct key **key_return)
}
else
if
(
strcmp
(
auth_type
,
"blake2s"
)
==
0
)
{
key
->
type
=
AUTH_TYPE_BLAKE2S
;
}
else
{
key
->
type
=
0
;
free
(
auth_type
);
goto
error
;
}
...
...
hmac.c
View file @
9529941b
...
...
@@ -72,7 +72,7 @@ add_key(char *id, int type, int len, unsigned char *value)
{
struct
key
*
key
;
assert
(
value
!=
NULL
&&
type
!=
0
);
assert
(
value
!=
NULL
&&
type
!=
AUTH_TYPE_NONE
);
key
=
find_key
(
id
);
if
(
key
)
{
...
...
message.c
View file @
9529941b
...
...
@@ -1074,12 +1074,12 @@ flushbuf(struct buffered *buf, struct interface *ifp)
assert
(
buf
->
len
<=
buf
->
size
);
if
(
buf
->
len
>
0
)
{
if
(
ifp
->
key
!=
NULL
&&
ifp
->
key
->
type
!=
0
)
if
(
ifp
->
key
!=
NULL
&&
ifp
->
key
->
type
!=
AUTH_TYPE_NONE
)
send_crypto_seqno
(
buf
,
ifp
);
debugf
(
" (flushing %d buffered bytes)
\n
"
,
buf
->
len
);
DO_HTONS
(
packet_header
+
2
,
buf
->
len
);
fill_rtt_message
(
buf
,
ifp
);
if
(
ifp
->
key
!=
NULL
&&
ifp
->
key
->
type
!=
0
)
{
if
(
ifp
->
key
!=
NULL
&&
ifp
->
key
->
type
!=
AUTH_TYPE_NONE
)
{
end
=
add_hmac
(
buf
,
ifp
,
packet_header
);
if
(
end
<
0
)
{
fprintf
(
stderr
,
"Couldn't add HMAC.
\n
"
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment