mbed TLS Build

Dependents:   Encrypt_Decrypt1 mbed_blink_tls encrypt encrypt

Committer:
markrad
Date:
Thu Jan 05 00:18:44 2017 +0000
Revision:
0:cdf462088d13
Initial commit

Who changed what in which revision?

UserRevisionLine numberNew contents of line
markrad 0:cdf462088d13 1 Test case mbedtls_base64_encode #1 buffer just right
markrad 0:cdf462088d13 2 mbedtls_base64_encode:"":"":0:0
markrad 0:cdf462088d13 3
markrad 0:cdf462088d13 4 Test case mbedtls_base64_encode #2 buffer just right
markrad 0:cdf462088d13 5 mbedtls_base64_encode:"f":"Zg==":5:0
markrad 0:cdf462088d13 6
markrad 0:cdf462088d13 7 Test case mbedtls_base64_encode #2 buffer too small
markrad 0:cdf462088d13 8 mbedtls_base64_encode:"f":"Zg==":4:MBEDTLS_ERR_BASE64_BUFFER_TOO_SMALL
markrad 0:cdf462088d13 9
markrad 0:cdf462088d13 10 Test case mbedtls_base64_encode #3 buffer just right
markrad 0:cdf462088d13 11 mbedtls_base64_encode:"fo":"Zm8=":5:0
markrad 0:cdf462088d13 12
markrad 0:cdf462088d13 13 Test case mbedtls_base64_encode #3 buffer too small
markrad 0:cdf462088d13 14 mbedtls_base64_encode:"fo":"Zm8=":4:MBEDTLS_ERR_BASE64_BUFFER_TOO_SMALL
markrad 0:cdf462088d13 15
markrad 0:cdf462088d13 16 Test case mbedtls_base64_encode #4 buffer just right
markrad 0:cdf462088d13 17 mbedtls_base64_encode:"foo":"Zm9v":5:0
markrad 0:cdf462088d13 18
markrad 0:cdf462088d13 19 Test case mbedtls_base64_encode #4 buffer too small
markrad 0:cdf462088d13 20 mbedtls_base64_encode:"foo":"Zm9v":4:MBEDTLS_ERR_BASE64_BUFFER_TOO_SMALL
markrad 0:cdf462088d13 21
markrad 0:cdf462088d13 22 Test case mbedtls_base64_encode #5 buffer just right
markrad 0:cdf462088d13 23 mbedtls_base64_encode:"foob":"Zm9vYg==":9:0
markrad 0:cdf462088d13 24
markrad 0:cdf462088d13 25 Test case mbedtls_base64_encode #5 buffer too small
markrad 0:cdf462088d13 26 mbedtls_base64_encode:"foob":"Zm9vYg==":8:MBEDTLS_ERR_BASE64_BUFFER_TOO_SMALL
markrad 0:cdf462088d13 27
markrad 0:cdf462088d13 28 Test case mbedtls_base64_encode #6 buffer just right
markrad 0:cdf462088d13 29 mbedtls_base64_encode:"fooba":"Zm9vYmE=":9:0
markrad 0:cdf462088d13 30
markrad 0:cdf462088d13 31 Test case mbedtls_base64_encode #6 buffer too small
markrad 0:cdf462088d13 32 mbedtls_base64_encode:"fooba":"Zm9vYmE=":8:MBEDTLS_ERR_BASE64_BUFFER_TOO_SMALL
markrad 0:cdf462088d13 33
markrad 0:cdf462088d13 34 Test case mbedtls_base64_encode #7 buffer just right
markrad 0:cdf462088d13 35 mbedtls_base64_encode:"foobar":"Zm9vYmFy":9:0
markrad 0:cdf462088d13 36
markrad 0:cdf462088d13 37 Test case mbedtls_base64_encode #7 buffer too small
markrad 0:cdf462088d13 38 mbedtls_base64_encode:"foobar":"Zm9vYmFy":8:MBEDTLS_ERR_BASE64_BUFFER_TOO_SMALL
markrad 0:cdf462088d13 39
markrad 0:cdf462088d13 40 Test case mbedtls_base64_decode #1
markrad 0:cdf462088d13 41 mbedtls_base64_decode:"":"":0
markrad 0:cdf462088d13 42
markrad 0:cdf462088d13 43 Test case mbedtls_base64_decode #2
markrad 0:cdf462088d13 44 mbedtls_base64_decode:"Zg==":"f":0
markrad 0:cdf462088d13 45
markrad 0:cdf462088d13 46 Test case mbedtls_base64_decode #3
markrad 0:cdf462088d13 47 mbedtls_base64_decode:"Zm8=":"fo":0
markrad 0:cdf462088d13 48
markrad 0:cdf462088d13 49 Test case mbedtls_base64_decode #4
markrad 0:cdf462088d13 50 mbedtls_base64_decode:"Zm9v":"foo":0
markrad 0:cdf462088d13 51
markrad 0:cdf462088d13 52 Test case mbedtls_base64_decode #5
markrad 0:cdf462088d13 53 mbedtls_base64_decode:"Zm9vYg==":"foob":0
markrad 0:cdf462088d13 54
markrad 0:cdf462088d13 55 Test case mbedtls_base64_decode #6
markrad 0:cdf462088d13 56 mbedtls_base64_decode:"Zm9vYmE=":"fooba":0
markrad 0:cdf462088d13 57
markrad 0:cdf462088d13 58 Test case mbedtls_base64_decode #7
markrad 0:cdf462088d13 59 mbedtls_base64_decode:"Zm9vYmFy":"foobar":0
markrad 0:cdf462088d13 60
markrad 0:cdf462088d13 61 Base64 decode (Illegal character)
markrad 0:cdf462088d13 62 mbedtls_base64_decode:"zm#=":"":MBEDTLS_ERR_BASE64_INVALID_CHARACTER
markrad 0:cdf462088d13 63
markrad 0:cdf462088d13 64 Base64 decode (Too much equal signs)
markrad 0:cdf462088d13 65 mbedtls_base64_decode:"zm===":"":MBEDTLS_ERR_BASE64_INVALID_CHARACTER
markrad 0:cdf462088d13 66
markrad 0:cdf462088d13 67 Base64 decode (Invalid char after equal signs)
markrad 0:cdf462088d13 68 mbedtls_base64_decode:"zm=masd":"":MBEDTLS_ERR_BASE64_INVALID_CHARACTER
markrad 0:cdf462088d13 69
markrad 0:cdf462088d13 70 Base64 decode (Space inside string)
markrad 0:cdf462088d13 71 mbedtls_base64_decode:"zm masd":"":MBEDTLS_ERR_BASE64_INVALID_CHARACTER
markrad 0:cdf462088d13 72
markrad 0:cdf462088d13 73 Base64 decode "Zm9vYmFy" (no newline nor '\0' at end)
markrad 0:cdf462088d13 74 base64_decode_hex_src:"5a6d3976596d4679":"foobar":0
markrad 0:cdf462088d13 75
markrad 0:cdf462088d13 76 Base64 decode "Zm9vYmFy\n" (LF at end)
markrad 0:cdf462088d13 77 base64_decode_hex_src:"5a6d3976596d46790a":"foobar":0
markrad 0:cdf462088d13 78
markrad 0:cdf462088d13 79 Base64 decode "Zm9vYmFy\r\n" (CRLF at end)
markrad 0:cdf462088d13 80 base64_decode_hex_src:"5a6d3976596d46790d0a":"foobar":0
markrad 0:cdf462088d13 81
markrad 0:cdf462088d13 82 Base64 decode "Zm9vYmFy\r" (CR at end)
markrad 0:cdf462088d13 83 base64_decode_hex_src:"5a6d3976596d46790d":"":MBEDTLS_ERR_BASE64_INVALID_CHARACTER
markrad 0:cdf462088d13 84
markrad 0:cdf462088d13 85 Base64 decode "Zm9vYmFy " (SP at end)
markrad 0:cdf462088d13 86 base64_decode_hex_src:"5a6d3976596d467920":"foobar":0
markrad 0:cdf462088d13 87
markrad 0:cdf462088d13 88 Base64 decode "Zm9vYmFy \n" (SP+LF at end)
markrad 0:cdf462088d13 89 base64_decode_hex_src:"5a6d3976596d4679200a":"foobar":0
markrad 0:cdf462088d13 90
markrad 0:cdf462088d13 91 Base64 decode "Zm9vYmFy \r\n" (SP+CRLF at end)
markrad 0:cdf462088d13 92 base64_decode_hex_src:"5a6d3976596d4679200d0a":"foobar":0
markrad 0:cdf462088d13 93
markrad 0:cdf462088d13 94 Base64 decode "Zm9vYmFy \r" (SP+CR at end)
markrad 0:cdf462088d13 95 base64_decode_hex_src:"5a6d3976596d4679200d":"":MBEDTLS_ERR_BASE64_INVALID_CHARACTER
markrad 0:cdf462088d13 96
markrad 0:cdf462088d13 97 Base64 decode "Zm9vYmFy " (2SP at end)
markrad 0:cdf462088d13 98 base64_decode_hex_src:"5a6d3976596d46792020":"foobar":0
markrad 0:cdf462088d13 99
markrad 0:cdf462088d13 100 Base64 decode "Zm9vYmFy \n" (2SP+LF at end)
markrad 0:cdf462088d13 101 base64_decode_hex_src:"5a6d3976596d467920200a":"foobar":0
markrad 0:cdf462088d13 102
markrad 0:cdf462088d13 103 Base64 decode "Zm9vYmFy \r\n" (2SP+CRLF at end)
markrad 0:cdf462088d13 104 base64_decode_hex_src:"5a6d3976596d467920200d0a":"foobar":0
markrad 0:cdf462088d13 105
markrad 0:cdf462088d13 106 Base64 decode "Zm9vYmFy \r" (2SP+CR at end)
markrad 0:cdf462088d13 107 base64_decode_hex_src:"5a6d3976596d467920200d":"":MBEDTLS_ERR_BASE64_INVALID_CHARACTER
markrad 0:cdf462088d13 108
markrad 0:cdf462088d13 109 Base64 decode "Zm9vYmF\ny" (LF inside)
markrad 0:cdf462088d13 110 base64_decode_hex_src:"5a6d3976596d460a79":"foobar":0
markrad 0:cdf462088d13 111
markrad 0:cdf462088d13 112 Base64 decode "Zm9vYmF\ry" (CRLF inside)
markrad 0:cdf462088d13 113 base64_decode_hex_src:"5a6d3976596d460d0a79":"foobar":0
markrad 0:cdf462088d13 114
markrad 0:cdf462088d13 115 Base64 decode "Zm9vYmF\ry" (CR inside)
markrad 0:cdf462088d13 116 base64_decode_hex_src:"5a6d3976596d460d79":"":MBEDTLS_ERR_BASE64_INVALID_CHARACTER
markrad 0:cdf462088d13 117
markrad 0:cdf462088d13 118 Base64 decode "Zm9vYmF y" (SP inside)
markrad 0:cdf462088d13 119 base64_decode_hex_src:"5a6d3976596d462079":"":MBEDTLS_ERR_BASE64_INVALID_CHARACTER
markrad 0:cdf462088d13 120
markrad 0:cdf462088d13 121 Base64 decode "Zm9vYmF \ny" (SP+LF inside)
markrad 0:cdf462088d13 122 base64_decode_hex_src:"5a6d3976596d46200a79":"foobar":0
markrad 0:cdf462088d13 123
markrad 0:cdf462088d13 124 Base64 decode "Zm9vYmF \ry" (SP+CRLF inside)
markrad 0:cdf462088d13 125 base64_decode_hex_src:"5a6d3976596d46200d0a79":"foobar":0
markrad 0:cdf462088d13 126
markrad 0:cdf462088d13 127 Base64 decode "Zm9vYmF \ry" (SP+CR inside)
markrad 0:cdf462088d13 128 base64_decode_hex_src:"5a6d3976596d46200d79":"":MBEDTLS_ERR_BASE64_INVALID_CHARACTER
markrad 0:cdf462088d13 129
markrad 0:cdf462088d13 130 Base64 decode "Zm9vYmF y" (2SP inside)
markrad 0:cdf462088d13 131 base64_decode_hex_src:"5a6d3976596d46202079":"":MBEDTLS_ERR_BASE64_INVALID_CHARACTER
markrad 0:cdf462088d13 132
markrad 0:cdf462088d13 133 Base64 decode "Zm9vYmF \ny" (2SP+LF inside)
markrad 0:cdf462088d13 134 base64_decode_hex_src:"5a6d3976596d4620200a79":"foobar":0
markrad 0:cdf462088d13 135
markrad 0:cdf462088d13 136 Base64 decode "Zm9vYmF \ry" (2SP+CRLF inside)
markrad 0:cdf462088d13 137 base64_decode_hex_src:"5a6d3976596d4620200d0a79":"foobar":0
markrad 0:cdf462088d13 138
markrad 0:cdf462088d13 139 Base64 decode "Zm9vYmF \ry" (2SP+CR inside)
markrad 0:cdf462088d13 140 base64_decode_hex_src:"5a6d3976596d4620200d79":"":MBEDTLS_ERR_BASE64_INVALID_CHARACTER
markrad 0:cdf462088d13 141
markrad 0:cdf462088d13 142 Base64 encode hex #1
markrad 0:cdf462088d13 143 base64_encode_hex:"010203040506070809":"AQIDBAUGBwgJ":13:0
markrad 0:cdf462088d13 144
markrad 0:cdf462088d13 145 Base64 encode hex #2 (buffer too small)
markrad 0:cdf462088d13 146 base64_encode_hex:"010203040506070809":"AQIDBAUGBwgJ":12:MBEDTLS_ERR_BASE64_BUFFER_TOO_SMALL
markrad 0:cdf462088d13 147
markrad 0:cdf462088d13 148 Base64 encode hex #3
markrad 0:cdf462088d13 149 base64_encode_hex:"0102030405060708":"AQIDBAUGBwg=":13:0
markrad 0:cdf462088d13 150
markrad 0:cdf462088d13 151 Base64 encode hex #4
markrad 0:cdf462088d13 152 base64_encode_hex:"01020304050607":"AQIDBAUGBw==":13:0
markrad 0:cdf462088d13 153
markrad 0:cdf462088d13 154 Base64 decode hex #1
markrad 0:cdf462088d13 155 base64_decode_hex:"AQIDBAUGBwgJ":"010203040506070809":9:0
markrad 0:cdf462088d13 156
markrad 0:cdf462088d13 157 Base64 decode hex #2 (buffer too small)
markrad 0:cdf462088d13 158 base64_decode_hex:"AQIDBAUGBwgJ":"010203040506070809":8:MBEDTLS_ERR_BASE64_BUFFER_TOO_SMALL
markrad 0:cdf462088d13 159
markrad 0:cdf462088d13 160 Base64 decode hex #3
markrad 0:cdf462088d13 161 base64_decode_hex:"AQIDBAUGBwg=":"0102030405060708":8:0
markrad 0:cdf462088d13 162
markrad 0:cdf462088d13 163 Base64 decode hex #4
markrad 0:cdf462088d13 164 base64_decode_hex:"AQIDBAUGBw==":"01020304050607":7:0
markrad 0:cdf462088d13 165
markrad 0:cdf462088d13 166 Base64 decode hex #5 (buffer too small)
markrad 0:cdf462088d13 167 base64_decode_hex:"AQIDBAUGBw==":"01020304050607":6:MBEDTLS_ERR_BASE64_BUFFER_TOO_SMALL
markrad 0:cdf462088d13 168
markrad 0:cdf462088d13 169 Base64 Selftest
markrad 0:cdf462088d13 170 depends_on:MBEDTLS_SELF_TEST
markrad 0:cdf462088d13 171 base64_selftest:
markrad 0:cdf462088d13 172