History log of /openbsd-current/usr.sbin/rpki-client/encoding.c
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
# 1.13 15-May-2022 deraadt

whitespace spotted during read-thru


# 1.12 20-Apr-2022 tb

Fix various annoying whitespace errors.


# 1.11 19-Apr-2022 claudio

Do not use a hidden global for the EVP_ENCODE_CTX to save a calloc() call.
Make this work concurrently by allocating and freeing the EVP_ENCODE_CTX
for every call to base64_decode(). This is not a hot path so the impact
is negligible.
OK tb@


Revision tags: OPENBSD_7_1_BASE
# 1.10 24-Nov-2021 claudio

Move some functions from rrdp.c to rrdp_util.c and hex_decode to encoding.c.
This will make it easier to write a RRDP regress test.
OK job@ deraadt@


# 1.9 31-Oct-2021 claudio

Further improve load_file(). Always set an errno on errors and make sure
the errno is not clobbered in the error path. Check result from load_file()
and issue a warning and skip the file in queue_add_tal().
OK benno@ beck@


# 1.8 28-Oct-2021 claudio

Limit the size of the base64 blob inside the RRDP XML to be less than
MAX_FILE_SIZE after base64 decoding it. This way hostile RRDP servers
do less damage.
OK beck@ tb@


# 1.7 27-Oct-2021 beck

Add limits on size of certain untrusted inputs

ok job@


# 1.6 26-Oct-2021 claudio

Move load_file() to encoding.c so that regress can use the function.


# 1.5 26-Oct-2021 claudio

Refactor the tal parsing code to use the same load_file() and buffer
passing as done for the other parsers.
OK job@ tb@


# 1.4 11-Oct-2021 claudio

base64_encode() should not add any newlines into the output. Because
of this switch from EVP_EncodeUpdate() plus complexity to the much
simpler use of calling EVP_EncodeBlock() directly.
OK job@


Revision tags: OPENBSD_7_0_BASE
# 1.3 01-Sep-2021 claudio

branches: 1.3.4;
Add http_proxy support to rpki-client's http handler.
OK tb@


# 1.2 19-Apr-2021 deraadt

code review results in KNF, and moving local variables into lowest scope
ok claudio


Revision tags: OPENBSD_6_9_BASE
# 1.1 01-Apr-2021 claudio

branches: 1.1.2;
Move base64 and hex encoding functions into their own place.
OK tb@


# 1.12 20-Apr-2022 tb

Fix various annoying whitespace errors.


# 1.11 19-Apr-2022 claudio

Do not use a hidden global for the EVP_ENCODE_CTX to save a calloc() call.
Make this work concurrently by allocating and freeing the EVP_ENCODE_CTX
for every call to base64_decode(). This is not a hot path so the impact
is negligible.
OK tb@


Revision tags: OPENBSD_7_1_BASE
# 1.10 24-Nov-2021 claudio

Move some functions from rrdp.c to rrdp_util.c and hex_decode to encoding.c.
This will make it easier to write a RRDP regress test.
OK job@ deraadt@


# 1.9 31-Oct-2021 claudio

Further improve load_file(). Always set an errno on errors and make sure
the errno is not clobbered in the error path. Check result from load_file()
and issue a warning and skip the file in queue_add_tal().
OK benno@ beck@


# 1.8 28-Oct-2021 claudio

Limit the size of the base64 blob inside the RRDP XML to be less than
MAX_FILE_SIZE after base64 decoding it. This way hostile RRDP servers
do less damage.
OK beck@ tb@


# 1.7 27-Oct-2021 beck

Add limits on size of certain untrusted inputs

ok job@


# 1.6 26-Oct-2021 claudio

Move load_file() to encoding.c so that regress can use the function.


# 1.5 26-Oct-2021 claudio

Refactor the tal parsing code to use the same load_file() and buffer
passing as done for the other parsers.
OK job@ tb@


# 1.4 11-Oct-2021 claudio

base64_encode() should not add any newlines into the output. Because
of this switch from EVP_EncodeUpdate() plus complexity to the much
simpler use of calling EVP_EncodeBlock() directly.
OK job@


Revision tags: OPENBSD_7_0_BASE
# 1.3 01-Sep-2021 claudio

branches: 1.3.4;
Add http_proxy support to rpki-client's http handler.
OK tb@


# 1.2 19-Apr-2021 deraadt

code review results in KNF, and moving local variables into lowest scope
ok claudio


Revision tags: OPENBSD_6_9_BASE
# 1.1 01-Apr-2021 claudio

branches: 1.1.2;
Move base64 and hex encoding functions into their own place.
OK tb@


# 1.11 19-Apr-2022 claudio

Do not use a hidden global for the EVP_ENCODE_CTX to save a calloc() call.
Make this work concurrently by allocating and freeing the EVP_ENCODE_CTX
for every call to base64_decode(). This is not a hot path so the impact
is negligible.
OK tb@


Revision tags: OPENBSD_7_1_BASE
# 1.10 24-Nov-2021 claudio

Move some functions from rrdp.c to rrdp_util.c and hex_decode to encoding.c.
This will make it easier to write a RRDP regress test.
OK job@ deraadt@


# 1.9 31-Oct-2021 claudio

Further improve load_file(). Always set an errno on errors and make sure
the errno is not clobbered in the error path. Check result from load_file()
and issue a warning and skip the file in queue_add_tal().
OK benno@ beck@


# 1.8 28-Oct-2021 claudio

Limit the size of the base64 blob inside the RRDP XML to be less than
MAX_FILE_SIZE after base64 decoding it. This way hostile RRDP servers
do less damage.
OK beck@ tb@


# 1.7 27-Oct-2021 beck

Add limits on size of certain untrusted inputs

ok job@


# 1.6 26-Oct-2021 claudio

Move load_file() to encoding.c so that regress can use the function.


# 1.5 26-Oct-2021 claudio

Refactor the tal parsing code to use the same load_file() and buffer
passing as done for the other parsers.
OK job@ tb@


# 1.4 11-Oct-2021 claudio

base64_encode() should not add any newlines into the output. Because
of this switch from EVP_EncodeUpdate() plus complexity to the much
simpler use of calling EVP_EncodeBlock() directly.
OK job@


Revision tags: OPENBSD_7_0_BASE
# 1.3 01-Sep-2021 claudio

branches: 1.3.4;
Add http_proxy support to rpki-client's http handler.
OK tb@


# 1.2 19-Apr-2021 deraadt

code review results in KNF, and moving local variables into lowest scope
ok claudio


Revision tags: OPENBSD_6_9_BASE
# 1.1 01-Apr-2021 claudio

branches: 1.1.2;
Move base64 and hex encoding functions into their own place.
OK tb@


# 1.10 24-Nov-2021 claudio

Move some functions from rrdp.c to rrdp_util.c and hex_decode to encoding.c.
This will make it easier to write a RRDP regress test.
OK job@ deraadt@


# 1.9 31-Oct-2021 claudio

Further improve load_file(). Always set an errno on errors and make sure
the errno is not clobbered in the error path. Check result from load_file()
and issue a warning and skip the file in queue_add_tal().
OK benno@ beck@


# 1.8 28-Oct-2021 claudio

Limit the size of the base64 blob inside the RRDP XML to be less than
MAX_FILE_SIZE after base64 decoding it. This way hostile RRDP servers
do less damage.
OK beck@ tb@


# 1.7 27-Oct-2021 beck

Add limits on size of certain untrusted inputs

ok job@


# 1.6 26-Oct-2021 claudio

Move load_file() to encoding.c so that regress can use the function.


# 1.5 26-Oct-2021 claudio

Refactor the tal parsing code to use the same load_file() and buffer
passing as done for the other parsers.
OK job@ tb@


# 1.4 11-Oct-2021 claudio

base64_encode() should not add any newlines into the output. Because
of this switch from EVP_EncodeUpdate() plus complexity to the much
simpler use of calling EVP_EncodeBlock() directly.
OK job@


Revision tags: OPENBSD_7_0_BASE
# 1.3 01-Sep-2021 claudio

branches: 1.3.4;
Add http_proxy support to rpki-client's http handler.
OK tb@


# 1.2 19-Apr-2021 deraadt

code review results in KNF, and moving local variables into lowest scope
ok claudio


Revision tags: OPENBSD_6_9_BASE
# 1.1 01-Apr-2021 claudio

branches: 1.1.2;
Move base64 and hex encoding functions into their own place.
OK tb@


# 1.9 31-Oct-2021 claudio

Further improve load_file(). Always set an errno on errors and make sure
the errno is not clobbered in the error path. Check result from load_file()
and issue a warning and skip the file in queue_add_tal().
OK benno@ beck@


# 1.8 28-Oct-2021 claudio

Limit the size of the base64 blob inside the RRDP XML to be less than
MAX_FILE_SIZE after base64 decoding it. This way hostile RRDP servers
do less damage.
OK beck@ tb@


# 1.7 27-Oct-2021 beck

Add limits on size of certain untrusted inputs

ok job@


# 1.6 26-Oct-2021 claudio

Move load_file() to encoding.c so that regress can use the function.


# 1.5 26-Oct-2021 claudio

Refactor the tal parsing code to use the same load_file() and buffer
passing as done for the other parsers.
OK job@ tb@


# 1.4 11-Oct-2021 claudio

base64_encode() should not add any newlines into the output. Because
of this switch from EVP_EncodeUpdate() plus complexity to the much
simpler use of calling EVP_EncodeBlock() directly.
OK job@


Revision tags: OPENBSD_7_0_BASE
# 1.3 01-Sep-2021 claudio

Add http_proxy support to rpki-client's http handler.
OK tb@


# 1.2 19-Apr-2021 deraadt

code review results in KNF, and moving local variables into lowest scope
ok claudio


Revision tags: OPENBSD_6_9_BASE
# 1.1 01-Apr-2021 claudio

Move base64 and hex encoding functions into their own place.
OK tb@


# 1.8 28-Oct-2021 claudio

Limit the size of the base64 blob inside the RRDP XML to be less than
MAX_FILE_SIZE after base64 decoding it. This way hostile RRDP servers
do less damage.
OK beck@ tb@


# 1.7 27-Oct-2021 beck

Add limits on size of certain untrusted inputs

ok job@


# 1.6 26-Oct-2021 claudio

Move load_file() to encoding.c so that regress can use the function.


# 1.5 26-Oct-2021 claudio

Refactor the tal parsing code to use the same load_file() and buffer
passing as done for the other parsers.
OK job@ tb@


# 1.4 11-Oct-2021 claudio

base64_encode() should not add any newlines into the output. Because
of this switch from EVP_EncodeUpdate() plus complexity to the much
simpler use of calling EVP_EncodeBlock() directly.
OK job@


Revision tags: OPENBSD_7_0_BASE
# 1.3 01-Sep-2021 claudio

Add http_proxy support to rpki-client's http handler.
OK tb@


# 1.2 19-Apr-2021 deraadt

code review results in KNF, and moving local variables into lowest scope
ok claudio


Revision tags: OPENBSD_6_9_BASE
# 1.1 01-Apr-2021 claudio

Move base64 and hex encoding functions into their own place.
OK tb@


# 1.8 28-Oct-2021 claudio

Limit the size of the base64 blob inside the RRDP XML to be less than
MAX_FILE_SIZE after base64 decoding it. This way hostile RRDP servers
do less damage.
OK beck@ tb@


# 1.7 27-Oct-2021 beck

Add limits on size of certain untrusted inputs

ok job@


# 1.6 26-Oct-2021 claudio

Move load_file() to encoding.c so that regress can use the function.


# 1.5 26-Oct-2021 claudio

Refactor the tal parsing code to use the same load_file() and buffer
passing as done for the other parsers.
OK job@ tb@


# 1.4 11-Oct-2021 claudio

base64_encode() should not add any newlines into the output. Because
of this switch from EVP_EncodeUpdate() plus complexity to the much
simpler use of calling EVP_EncodeBlock() directly.
OK job@


Revision tags: OPENBSD_7_0_BASE
# 1.3 01-Sep-2021 claudio

Add http_proxy support to rpki-client's http handler.
OK tb@


# 1.2 19-Apr-2021 deraadt

code review results in KNF, and moving local variables into lowest scope
ok claudio


Revision tags: OPENBSD_6_9_BASE
# 1.1 01-Apr-2021 claudio

Move base64 and hex encoding functions into their own place.
OK tb@


# 1.6 26-Oct-2021 claudio

Move load_file() to encoding.c so that regress can use the function.


# 1.5 26-Oct-2021 claudio

Refactor the tal parsing code to use the same load_file() and buffer
passing as done for the other parsers.
OK job@ tb@


# 1.4 11-Oct-2021 claudio

base64_encode() should not add any newlines into the output. Because
of this switch from EVP_EncodeUpdate() plus complexity to the much
simpler use of calling EVP_EncodeBlock() directly.
OK job@


Revision tags: OPENBSD_7_0_BASE
# 1.3 01-Sep-2021 claudio

Add http_proxy support to rpki-client's http handler.
OK tb@


# 1.2 19-Apr-2021 deraadt

code review results in KNF, and moving local variables into lowest scope
ok claudio


Revision tags: OPENBSD_6_9_BASE
# 1.1 01-Apr-2021 claudio

Move base64 and hex encoding functions into their own place.
OK tb@


# 1.4 11-Oct-2021 claudio

base64_encode() should not add any newlines into the output. Because
of this switch from EVP_EncodeUpdate() plus complexity to the much
simpler use of calling EVP_EncodeBlock() directly.
OK job@


Revision tags: OPENBSD_7_0_BASE
# 1.3 01-Sep-2021 claudio

Add http_proxy support to rpki-client's http handler.
OK tb@


# 1.2 19-Apr-2021 deraadt

code review results in KNF, and moving local variables into lowest scope
ok claudio


Revision tags: OPENBSD_6_9_BASE
# 1.1 01-Apr-2021 claudio

Move base64 and hex encoding functions into their own place.
OK tb@


# 1.3 01-Sep-2021 claudio

Add http_proxy support to rpki-client's http handler.
OK tb@


# 1.2 19-Apr-2021 deraadt

code review results in KNF, and moving local variables into lowest scope
ok claudio


Revision tags: OPENBSD_6_9_BASE
# 1.1 01-Apr-2021 claudio

Move base64 and hex encoding functions into their own place.
OK tb@


# 1.2 19-Apr-2021 deraadt

code review results in KNF, and moving local variables into lowest scope
ok claudio


Revision tags: OPENBSD_6_9_BASE
# 1.1 01-Apr-2021 claudio

Move base64 and hex encoding functions into their own place.
OK tb@