Lines Matching refs:s1
213 const unsigned char *s1, *s2, *end; in mbedtls_pem_read_buffer() local
227 s1 = (unsigned char *) strstr( (const char *) data, header ); in mbedtls_pem_read_buffer()
229 if( s1 == NULL ) in mbedtls_pem_read_buffer()
234 if( s2 == NULL || s2 <= s1 ) in mbedtls_pem_read_buffer()
237 s1 += strlen( header ); in mbedtls_pem_read_buffer()
238 if( *s1 == ' ' ) s1++; in mbedtls_pem_read_buffer()
239 if( *s1 == '\r' ) s1++; in mbedtls_pem_read_buffer()
240 if( *s1 == '\n' ) s1++; in mbedtls_pem_read_buffer()
252 if( memcmp( s1, "Proc-Type: 4,ENCRYPTED", 22 ) == 0 ) in mbedtls_pem_read_buffer()
258 s1 += 22; in mbedtls_pem_read_buffer()
259 if( *s1 == '\r' ) s1++; in mbedtls_pem_read_buffer()
260 if( *s1 == '\n' ) s1++; in mbedtls_pem_read_buffer()
265 if( memcmp( s1, "DEK-Info: DES-EDE3-CBC,", 23 ) == 0 ) in mbedtls_pem_read_buffer()
269 s1 += 23; in mbedtls_pem_read_buffer()
270 if( pem_get_iv( s1, pem_iv, 8 ) != 0 ) in mbedtls_pem_read_buffer()
273 s1 += 16; in mbedtls_pem_read_buffer()
275 else if( memcmp( s1, "DEK-Info: DES-CBC,", 18 ) == 0 ) in mbedtls_pem_read_buffer()
279 s1 += 18; in mbedtls_pem_read_buffer()
280 if( pem_get_iv( s1, pem_iv, 8) != 0 ) in mbedtls_pem_read_buffer()
283 s1 += 16; in mbedtls_pem_read_buffer()
288 if( memcmp( s1, "DEK-Info: AES-", 14 ) == 0 ) in mbedtls_pem_read_buffer()
290 if( memcmp( s1, "DEK-Info: AES-128-CBC,", 22 ) == 0 ) in mbedtls_pem_read_buffer()
292 else if( memcmp( s1, "DEK-Info: AES-192-CBC,", 22 ) == 0 ) in mbedtls_pem_read_buffer()
294 else if( memcmp( s1, "DEK-Info: AES-256-CBC,", 22 ) == 0 ) in mbedtls_pem_read_buffer()
299 s1 += 22; in mbedtls_pem_read_buffer()
300 if( pem_get_iv( s1, pem_iv, 16 ) != 0 ) in mbedtls_pem_read_buffer()
303 s1 += 32; in mbedtls_pem_read_buffer()
310 if( *s1 == '\r' ) s1++; in mbedtls_pem_read_buffer()
311 if( *s1 == '\n' ) s1++; in mbedtls_pem_read_buffer()
319 if( s1 == s2 ) in mbedtls_pem_read_buffer()
322 ret = mbedtls_base64_decode( NULL, 0, &len, s1, s2 - s1 ); in mbedtls_pem_read_buffer()
330 if( ( ret = mbedtls_base64_decode( buf, len, &len, s1, s2 - s1 ) ) != 0 ) in mbedtls_pem_read_buffer()