mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-11-30 00:44:20 +01:00
psa: programs: Add cipher example
Add `programs/psa/crypto_examples.c`. Update relevant Makefiles, CMakeLists.txt, and .gitignore files.
This commit is contained in:
parent
22e232ec04
commit
a3ff8a6ed5
1
programs/.gitignore
vendored
1
programs/.gitignore
vendored
@ -29,6 +29,7 @@ pkey/rsa_sign
|
|||||||
pkey/rsa_sign_pss
|
pkey/rsa_sign_pss
|
||||||
pkey/rsa_verify
|
pkey/rsa_verify
|
||||||
pkey/rsa_verify_pss
|
pkey/rsa_verify_pss
|
||||||
|
psa/crypto_examples
|
||||||
psa/psa_constant_names
|
psa/psa_constant_names
|
||||||
psa/psa_constant_names_generated.c
|
psa/psa_constant_names_generated.c
|
||||||
psa/key_ladder_demo
|
psa/key_ladder_demo
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
add_subdirectory(aes)
|
add_subdirectory(aes)
|
||||||
add_subdirectory(hash)
|
add_subdirectory(hash)
|
||||||
add_subdirectory(pkey)
|
add_subdirectory(pkey)
|
||||||
|
add_subdirectory(psa)
|
||||||
add_subdirectory(random)
|
add_subdirectory(random)
|
||||||
add_subdirectory(ssl)
|
add_subdirectory(ssl)
|
||||||
add_subdirectory(test)
|
add_subdirectory(test)
|
||||||
|
@ -60,6 +60,7 @@ APPS = aes/aescrypt2$(EXEXT) aes/crypt_and_hash$(EXEXT) \
|
|||||||
pkey/rsa_decrypt$(EXEXT) pkey/rsa_encrypt$(EXEXT) \
|
pkey/rsa_decrypt$(EXEXT) pkey/rsa_encrypt$(EXEXT) \
|
||||||
pkey/rsa_sign$(EXEXT) pkey/rsa_verify$(EXEXT) \
|
pkey/rsa_sign$(EXEXT) pkey/rsa_verify$(EXEXT) \
|
||||||
pkey/rsa_sign_pss$(EXEXT) pkey/rsa_verify_pss$(EXEXT) \
|
pkey/rsa_sign_pss$(EXEXT) pkey/rsa_verify_pss$(EXEXT) \
|
||||||
|
psa/crypto_examples$(EXEXT) \
|
||||||
psa/key_ladder_demo$(EXEXT) psa/psa_constant_names$(EXEXT) \
|
psa/key_ladder_demo$(EXEXT) psa/psa_constant_names$(EXEXT) \
|
||||||
ssl/dtls_client$(EXEXT) ssl/dtls_server$(EXEXT) \
|
ssl/dtls_client$(EXEXT) ssl/dtls_server$(EXEXT) \
|
||||||
ssl/ssl_client1$(EXEXT) ssl/ssl_client2$(EXEXT) \
|
ssl/ssl_client1$(EXEXT) ssl/ssl_client2$(EXEXT) \
|
||||||
@ -308,6 +309,10 @@ x509/req_app$(EXEXT): x509/req_app.c $(DEP)
|
|||||||
echo " CC x509/req_app.c"
|
echo " CC x509/req_app.c"
|
||||||
$(CC) $(LOCAL_CFLAGS) $(CFLAGS) x509/req_app.c $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
|
$(CC) $(LOCAL_CFLAGS) $(CFLAGS) x509/req_app.c $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
|
||||||
|
|
||||||
|
psa/crypto_examples$(EXEXT): psa/crypto_examples.c $(DEP)
|
||||||
|
echo " CC psa/crypto_examples.c"
|
||||||
|
$(CC) $(LOCAL_CFLAGS) $(CFLAGS) psa/crypto_examples.c $(LOCAL_LDFLAGS) $(LDFLAGS) -o $@
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
ifndef WINDOWS
|
ifndef WINDOWS
|
||||||
rm -f $(APPS) $(EXTRA_GENERATED)
|
rm -f $(APPS) $(EXTRA_GENERATED)
|
||||||
|
7
programs/psa/CMakeLists.txt
Normal file
7
programs/psa/CMakeLists.txt
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
add_executable(crypto_examples crypto_examples.c)
|
||||||
|
target_link_libraries(crypto_examples mbedtls)
|
||||||
|
|
||||||
|
install(TARGETS crypto_examples
|
||||||
|
DESTINATION "bin"
|
||||||
|
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE)
|
||||||
|
|
4
programs/psa/crypto_examples.c
Normal file
4
programs/psa/crypto_examples.c
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
int main( void )
|
||||||
|
{
|
||||||
|
return( 0 );
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user