Merge pull request #133 from kaleb-himes/pk-refactor
Refactor PK examples out of crypto and mv non-sig specific to pk dirpull/129/head
commit
6a02f06096
|
@ -21,6 +21,7 @@
|
||||||
*.i*86
|
*.i*86
|
||||||
*.x86_64
|
*.x86_64
|
||||||
*.hex
|
*.hex
|
||||||
|
*app
|
||||||
|
|
||||||
# IDE Temp Files
|
# IDE Temp Files
|
||||||
**/*.swp
|
**/*.swp
|
||||||
|
@ -79,18 +80,12 @@ android/wolfssljni-ndk-sample/proguard-project.txt
|
||||||
crypto/3des/3des-file-encrypt
|
crypto/3des/3des-file-encrypt
|
||||||
crypto/aes/aes-file-encrypt
|
crypto/aes/aes-file-encrypt
|
||||||
crypto/camellia/camellia-encrypt
|
crypto/camellia/camellia-encrypt
|
||||||
crypto/keys/ecc_keys
|
|
||||||
|
|
||||||
*/file-client/start-client
|
*/file-client/start-client
|
||||||
*/file-server/start-server
|
*/file-server/start-server
|
||||||
|
|
||||||
#Example der and x963 files
|
|
||||||
crypto/keys/*.der
|
|
||||||
crypto/keys/*.x963
|
|
||||||
|
|
||||||
signature/signature
|
signature/signature
|
||||||
signature/ED25519/gen_key_files
|
|
||||||
signature/ED25519/sign_and_verify
|
|
||||||
|
|
||||||
#cergen
|
#cergen
|
||||||
certgen/test.o
|
certgen/test.o
|
||||||
|
@ -152,7 +147,15 @@ pkcs11/server-tls-pkcs11
|
||||||
pkcs11/softhsm2.conf
|
pkcs11/softhsm2.conf
|
||||||
pkcs11/softhsm2
|
pkcs11/softhsm2
|
||||||
|
|
||||||
crypto/rsa-pss/rsa-pss
|
pk/rsa-pss/rsa-pss
|
||||||
crypto/rsa-pss/rsa-public.der
|
pk/rsa-pss/rsa-public.der
|
||||||
crypto/rsa-pss/sign.txt
|
pk/rsa-pss/sign.txt
|
||||||
crypto/rsa/rsa-nb
|
pk/rsa/rsa-nb
|
||||||
|
pk/ecc/ecc_keys
|
||||||
|
#Example der and x963 files
|
||||||
|
pk/ecc/*.der
|
||||||
|
pk/ecc/*.x963
|
||||||
|
pk/ED25519/gen_key_files
|
||||||
|
pk/ED25519/sign_and_verify
|
||||||
|
|
||||||
|
wolfCLU/tests/somejunk/*somejunk*.txt
|
||||||
|
|
|
@ -60,7 +60,7 @@ static int load_file_to_buffer(const char* filename, byte** fileBuf, int* fileLe
|
||||||
printf("File %s is %d bytes\n", filename, *fileLen);
|
printf("File %s is %d bytes\n", filename, *fileLen);
|
||||||
|
|
||||||
/* Allocate buffer for image */
|
/* Allocate buffer for image */
|
||||||
*fileBuf = malloc(*fileLen);
|
*fileBuf = malloc((size_t) *fileLen);
|
||||||
if(!*fileBuf) {
|
if(!*fileBuf) {
|
||||||
printf("File buffer malloc failed!\n");
|
printf("File buffer malloc failed!\n");
|
||||||
ret = EXIT_FAILURE;
|
ret = EXIT_FAILURE;
|
||||||
|
@ -68,7 +68,7 @@ static int load_file_to_buffer(const char* filename, byte** fileBuf, int* fileLe
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Load file into buffer */
|
/* Load file into buffer */
|
||||||
ret = (int)fread(*fileBuf, 1, *fileLen, file);
|
ret = (int)fread(*fileBuf, 1, (size_t) *fileLen, file);
|
||||||
if(ret != *fileLen) {
|
if(ret != *fileLen) {
|
||||||
printf("Error reading file! %d", ret);
|
printf("Error reading file! %d", ret);
|
||||||
ret = EXIT_FAILURE;
|
ret = EXIT_FAILURE;
|
Loading…
Reference in New Issue