px5g: Use SHA-256 when generating self-signed certificates

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>

SVN-Revision: 47391
This commit is contained in:
Felix Fietkau 2015-11-06 10:52:52 +00:00
parent aebf73f045
commit 4205078a78

View File

@ -212,7 +212,7 @@ int selfsigned(char **arg)
" and validity %s-%s\n", subject, fstr, tstr); " and validity %s-%s\n", subject, fstr, tstr);
x509write_crt_init(&cert); x509write_crt_init(&cert);
x509write_crt_set_md_alg(&cert, POLARSSL_MD_SHA1); x509write_crt_set_md_alg(&cert, POLARSSL_MD_SHA256);
x509write_crt_set_issuer_key(&cert, &key); x509write_crt_set_issuer_key(&cert, &key);
x509write_crt_set_subject_key(&cert, &key); x509write_crt_set_subject_key(&cert, &key);
x509write_crt_set_subject_name(&cert, subject); x509write_crt_set_subject_name(&cert, subject);