summaryrefslogtreecommitdiffstats
path: root/src/net/validator.c
diff options
context:
space:
mode:
authorMichael Brown2015-04-24 16:32:04 +0200
committerMichael Brown2015-04-24 16:32:04 +0200
commit1205721cbd1930d22b7adcb3211040c7152e3171 (patch)
treee3d7a1ff444a4ff0cea8ee38a9f4ef16eb323d31 /src/net/validator.c
parent[base16] Add buffer size parameter to base16_encode() and base16_decode() (diff)
downloadipxe-1205721cbd1930d22b7adcb3211040c7152e3171.tar.gz
ipxe-1205721cbd1930d22b7adcb3211040c7152e3171.tar.xz
ipxe-1205721cbd1930d22b7adcb3211040c7152e3171.zip
[base64] Add buffer size parameter to base64_encode() and base64_decode()
Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/net/validator.c')
-rw-r--r--src/net/validator.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/net/validator.c b/src/net/validator.c
index 4c26cd1b..a01269da 100644
--- a/src/net/validator.c
+++ b/src/net/validator.c
@@ -254,7 +254,8 @@ static int validator_start_download ( struct validator *validator,
/* Generate URI string */
len = snprintf ( uri_string, uri_string_len, "%s/%08x.der?subject=",
crosscert, crc );
- base64_encode ( issuer->data, issuer->len, ( uri_string + len ) );
+ base64_encode ( issuer->data, issuer->len, ( uri_string + len ),
+ ( uri_string_len - len ) );
DBGC ( validator, "VALIDATOR %p downloading cross-signed certificate "
"from %s\n", validator, uri_string );