forked from wolfSSL/wolfssl
Merge branch 'master' into fipsv3
This commit is contained in:
6
.gitignore
vendored
6
.gitignore
vendored
@ -355,6 +355,12 @@ IDE/XCODE/Index
|
|||||||
/IDE/Renesas/e2studio/Projects/test/*.launch
|
/IDE/Renesas/e2studio/Projects/test/*.launch
|
||||||
/IDE/Renesas/e2studio/Projects/test/*.scfg
|
/IDE/Renesas/e2studio/Projects/test/*.scfg
|
||||||
|
|
||||||
|
# QNX CAAM
|
||||||
|
/IDE/QNX/example-server/server-tls
|
||||||
|
/IDE/QNX/example-client/client-tls
|
||||||
|
/IDE/QNX/example-cmac/cmac-test
|
||||||
|
/IDE/QNX/CAAM-DRIVER/wolfCrypt
|
||||||
|
|
||||||
# Emacs
|
# Emacs
|
||||||
*~
|
*~
|
||||||
|
|
||||||
|
@ -1052,7 +1052,19 @@ if (WOLFSSL_TLS13)
|
|||||||
"-DHAVE_SUPPORTED_CURVES")
|
"-DHAVE_SUPPORTED_CURVES")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# TODO: - Session ticket
|
# Session Ticket Extension
|
||||||
|
set(WOLFSSL_SESSION_TICKET_HELP_STRING "Enable Session Ticket (default: disabled)")
|
||||||
|
add_option("WOLFSSL_SESSION_TICKET" ${WOLFSSL_SESSION_TICKET_HELP_STRING} "no" "yes;no")
|
||||||
|
|
||||||
|
if(WOLFSSL_NGINX OR WOLFSSL_WPAS OR WOLFSSL_HAPROXY OR WOLFSSL_LIGHTY)
|
||||||
|
override_cache(WOLFSSL_SESSION_TICKET "yes")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if(WOLFSSL_SESSION_TICKET)
|
||||||
|
list(APPEND WOLFSSL_DEFINITIONS
|
||||||
|
"-DHAVE_TLS_EXTENSIONS"
|
||||||
|
"-DHAVE_SESSION_TICKET")
|
||||||
|
endif()
|
||||||
|
|
||||||
# Extended master secret extension
|
# Extended master secret extension
|
||||||
set(WOLFSSL_EXTENDED_MASTER_HELP_STRING "Enable Extended Master Secret (default: enabled)")
|
set(WOLFSSL_EXTENDED_MASTER_HELP_STRING "Enable Extended Master Secret (default: enabled)")
|
||||||
@ -1345,6 +1357,8 @@ file(APPEND ${OPTION_FILE} "#ifdef __cplusplus\n")
|
|||||||
file(APPEND ${OPTION_FILE} "extern \"C\" {\n")
|
file(APPEND ${OPTION_FILE} "extern \"C\" {\n")
|
||||||
file(APPEND ${OPTION_FILE} "#endif\n\n")
|
file(APPEND ${OPTION_FILE} "#endif\n\n")
|
||||||
|
|
||||||
|
list(REMOVE_DUPLICATES WOLFSSL_DEFINITIONS)
|
||||||
|
|
||||||
foreach(DEF IN LISTS WOLFSSL_DEFINITIONS)
|
foreach(DEF IN LISTS WOLFSSL_DEFINITIONS)
|
||||||
if(DEF MATCHES "^-D")
|
if(DEF MATCHES "^-D")
|
||||||
if(DEF MATCHES "^-D(N)?DEBUG(=.+)?")
|
if(DEF MATCHES "^-D(N)?DEBUG(=.+)?")
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* wolfssl_client.ino
|
/* wolfssl_client.ino
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* wolfssl_server.ino
|
/* wolfssl_server.ino
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* main.c
|
/* main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
@ -18,6 +18,7 @@
|
|||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <wolfssl/wolfcrypt/settings.h>
|
#include <wolfssl/wolfcrypt/settings.h>
|
||||||
#include <wolfcrypt/test/test.h>
|
#include <wolfcrypt/test/test.h>
|
||||||
#include <wolfcrypt/benchmark/benchmark.h>
|
#include <wolfcrypt/benchmark/benchmark.h>
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_settings.h
|
/* user_settings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* deos_malloc.c
|
/* deos_malloc.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* tls_wolfssl.c
|
/* tls_wolfssl.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* tls_wolfssl.h
|
/* tls_wolfssl.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_setting.h
|
/* user_setting.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* client_wolfssl.c
|
/* client_wolfssl.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* client_wolfssl.h
|
/* client_wolfssl.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* server_wolfssl.c
|
/* server_wolfssl.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* server_wolfssl.h
|
/* server_wolfssl.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_setting.h
|
/* user_setting.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* wolfsslRunTests.c
|
/* wolfsslRunTests.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_setting.h
|
/* user_setting.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* wolfsslRunTests.c
|
/* wolfsslRunTests.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* config.h - dummy
|
/* config.h - dummy
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* helper.c
|
/* helper.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* client-tls-callback.c
|
/* client-tls-callback.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_settings.h
|
/* user_settings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* wifi_connect.c
|
/* wifi_connect.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* wifi_connect.h
|
/* wifi_connect.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* server-tls-callback.c
|
/* server-tls-callback.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* wifi_connect.c
|
/* wifi_connect.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_settings.h
|
/* user_settings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_settings.h
|
/* user_settings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* armtarget.c
|
/* armtarget.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* benchmark_main.c
|
/* benchmark_main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* test_main.c
|
/* test_main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* tls_client.c
|
/* tls_client.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* wolf_main.c
|
/* wolf_main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
# Makefile
|
# Makefile
|
||||||
#
|
#
|
||||||
# Copyright (C) 2006-2020 wolfSSL Inc.
|
# Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
#
|
#
|
||||||
# This file is part of wolfSSL.
|
# This file is part of wolfSSL.
|
||||||
#
|
#
|
||||||
@ -17,6 +17,7 @@
|
|||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program; if not, write to the Free Software
|
# along with this program; if not, write to the Free Software
|
||||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
||||||
|
#/
|
||||||
|
|
||||||
ENVI=hexagon
|
ENVI=hexagon
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
# Makefile
|
# Makefile
|
||||||
#
|
#
|
||||||
# Copyright (C) 2006-2020 wolfSSL Inc.
|
# Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
#
|
#
|
||||||
# This file is part of wolfSSL.
|
# This file is part of wolfSSL.
|
||||||
#
|
#
|
||||||
@ -17,6 +17,7 @@
|
|||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program; if not, write to the Free Software
|
# along with this program; if not, write to the Free Software
|
||||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
||||||
|
#/
|
||||||
|
|
||||||
ENVI=UbuntuARM
|
ENVI=UbuntuARM
|
||||||
|
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* ecc-verify-benchmark.c
|
/* ecc-verify-benchmark.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* ecc-verify.c
|
/* ecc-verify.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* benchmark-main.c
|
/* benchmark-main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* current-time.c
|
/* current-time.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* minimum-startup.c
|
/* minimum-startup.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* test-main.c
|
/* test-main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* lpc_18xx_port.c
|
/* lpc_18xx_port.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* lpc_18xx_startup.c
|
/* lpc_18xx_startup.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* main.c
|
/* main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* main.c
|
/* main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* time.c
|
/* time.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* certs_test.c
|
/* certs_test.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* config-BEREFOOT.h
|
/* config-BEREFOOT.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* config-FS.h
|
/* config-FS.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* config-RTX-TCP-FS.h
|
/* config-RTX-TCP-FS.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* config.h
|
/* config.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* main.c
|
/* main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/*shell.c
|
/*shell.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* time-STM32F2.c
|
/* time-STM32F2.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* time-dummy.c.c
|
/* time-dummy.c.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* wolfssl_KEIL_RL.c
|
/* wolfssl_KEIL_RL.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* wolfssl_KEIL_RL.h
|
/* wolfssl_KEIL_RL.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* time-STM32F2xx.c
|
/* time-STM32F2xx.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_settings.h
|
/* user_settings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* wolfssl_KEIL_ARM.h
|
/* wolfssl_KEIL_ARM.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_settings.h
|
/* user_settings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* main.c
|
/* main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_settings.h
|
/* user_settings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* main.c
|
/* main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_settings.h
|
/* user_settings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* main.c
|
/* main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_settings.h
|
/* user_settings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* main.c
|
/* main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_settings.h
|
/* user_settings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* main.c
|
/* main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_settings.h
|
/* user_settings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* main.c
|
/* main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* main.c
|
/* main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/*shell.c
|
/*shell.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* time-STM32F2.c
|
/* time-STM32F2.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_settings.h
|
/* user_settings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* ssl-dummy.c
|
/* ssl-dummy.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/* client-tls.c
|
/* client-tls.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL. (formerly known as CyaSSL)
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
* wolfSSL is free software; you can redistribute it and/or modify
|
* wolfSSL is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -16,8 +16,9 @@
|
|||||||
*
|
*
|
||||||
* You should have received a copy of the GNU General Public License
|
* You should have received a copy of the GNU General Public License
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* wolfSSL */
|
/* wolfSSL */
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/* server-tls.c
|
/* server-tls.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL. (formerly known as CyaSSL)
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
* wolfSSL is free software; you can redistribute it and/or modify
|
* wolfSSL is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -16,8 +16,9 @@
|
|||||||
*
|
*
|
||||||
* You should have received a copy of the GNU General Public License
|
* You should have received a copy of the GNU General Public License
|
||||||
* along with this program; if not, write to the Free Software
|
* along with this program; if not, write to the Free Software
|
||||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
/* wolfSSL */
|
/* wolfSSL */
|
||||||
#include <wolfssl/wolfcrypt/settings.h>
|
#include <wolfssl/wolfcrypt/settings.h>
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
# CMakeLists.txt
|
# CMakeLists.txt
|
||||||
#
|
#
|
||||||
# Copyright (C) 2006-2020 wolfSSL Inc.
|
# Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
#
|
#
|
||||||
# This file is part of wolfSSL.
|
# This file is part of wolfSSL.
|
||||||
#
|
#
|
||||||
@ -18,6 +18,7 @@
|
|||||||
# along with this program; if not, write to the Free Software
|
# along with this program; if not, write to the Free Software
|
||||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
||||||
#/
|
#/
|
||||||
|
#/
|
||||||
|
|
||||||
INCLUDE_DIRECTORIES(
|
INCLUDE_DIRECTORIES(
|
||||||
${CMAKE_SOURCE_DIR}/include
|
${CMAKE_SOURCE_DIR}/include
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
# CMakeLists.txt
|
# CMakeLists.txt
|
||||||
#
|
#
|
||||||
# Copyright (C) 2006-2020 wolfSSL Inc.
|
# Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
#
|
#
|
||||||
# This file is part of wolfSSL.
|
# This file is part of wolfSSL.
|
||||||
#
|
#
|
||||||
@ -18,6 +18,7 @@
|
|||||||
# along with this program; if not, write to the Free Software
|
# along with this program; if not, write to the Free Software
|
||||||
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
||||||
#/
|
#/
|
||||||
|
#/
|
||||||
|
|
||||||
INCLUDE_DIRECTORIES(
|
INCLUDE_DIRECTORIES(
|
||||||
${CMAKE_SOURCE_DIR}/include
|
${CMAKE_SOURCE_DIR}/include
|
||||||
|
34
IDE/QNX/CAAM-DRIVER/Makefile
Normal file
34
IDE/QNX/CAAM-DRIVER/Makefile
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
ARTIFACT = wolfCrypt
|
||||||
|
|
||||||
|
#Build architecture/variant string, possible values: x86, armv7le, etc...
|
||||||
|
PLATFORM = armv7le
|
||||||
|
OUTPUT_DIR = build
|
||||||
|
TARGET = $(ARTIFACT)
|
||||||
|
|
||||||
|
CC = qcc -Vgcc_nto$(PLATFORM)
|
||||||
|
CXX = qcc -lang-c++ -Vgcc_nto$(PLATFORM)
|
||||||
|
LD = $(CC)
|
||||||
|
|
||||||
|
INCLUDES += -I../../../wolfssl/wolfcrypt/port/caam/
|
||||||
|
CCFLAGS += -O2 -Wall
|
||||||
|
|
||||||
|
SRCS = \
|
||||||
|
../../../wolfcrypt/src/port/caam/caam_driver.c \
|
||||||
|
../../../wolfcrypt/src/port/caam/caam_error.c \
|
||||||
|
../../../wolfcrypt/src/port/caam/caam_qnx.c \
|
||||||
|
|
||||||
|
OBJS = $(addprefix $(OUTPUT_DIR)/,$(addsuffix .o, $(basename $(SRCS))))
|
||||||
|
|
||||||
|
$(OUTPUT_DIR)/%.o: %.c
|
||||||
|
@mkdir -p $(dir $@)
|
||||||
|
$(CC) -c -o $@ $(INCLUDES) $(CCFLAGS) $<
|
||||||
|
|
||||||
|
$(TARGET):$(OBJS)
|
||||||
|
$(LD) -o $(TARGET) $(LDFLAGS) $(OBJS) $(LIBS)
|
||||||
|
|
||||||
|
all: $(TARGET)
|
||||||
|
|
||||||
|
clean:
|
||||||
|
rm -rf $(OUTPUT_DIR) $(ARTIFACT)
|
||||||
|
|
||||||
|
rebuild: clean all
|
28
IDE/QNX/README.md
Normal file
28
IDE/QNX/README.md
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
# QNX CAAM Driver And Examples
|
||||||
|
|
||||||
|
This directory contains;
|
||||||
|
- A Makefile for creating the QNX CAAM driver located at IDE/QNX/CAAM-DRIVER/Makefile
|
||||||
|
- An example TLS server located at IDE/QNX/example-server/
|
||||||
|
- An example client located at IDE/QNX/example-client
|
||||||
|
- An example CMAC use located at IDE/QNX/example-cmac
|
||||||
|
|
||||||
|
To build either of these, first build wolfSSL with support for use with QNX CAAM. To do this use the configure option --enable-caam=qnx
|
||||||
|
|
||||||
|
```
|
||||||
|
bash
|
||||||
|
source ~/qnx700/qnxsdp-env.sh
|
||||||
|
./configure --host=arm-unknown-nto-qnx7.0.0eabi --enable-caam=qnx
|
||||||
|
make
|
||||||
|
```
|
||||||
|
|
||||||
|
Once the wolfSSL library has been built cd to IDE/QNX/CAAM-DRIVER and run "make". This will produce the wolfCrypt resource manager. It should be started on the device with root permisions. Once wolfCrypt is running on the device with root permisions then any user with access to open a connection to wolfCrypt can make use of the driver.
|
||||||
|
|
||||||
|
|
||||||
|
### Supported Operations By CAAM Driver
|
||||||
|
- ECC black key creation
|
||||||
|
- ECC black key sign / verify / ecdh
|
||||||
|
- Black blob creation and open
|
||||||
|
- Red blob creation and open
|
||||||
|
- Cover keys (turn to black key)
|
||||||
|
- CMAC with and without black keys
|
||||||
|
- TRNG used by default to seed Hash DRBG
|
33
IDE/QNX/example-client/Makefile
Normal file
33
IDE/QNX/example-client/Makefile
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
ARTIFACT = client-tls
|
||||||
|
|
||||||
|
#Build architecture/variant string, possible values: x86, armv7le, etc...
|
||||||
|
PLATFORM = armv7le
|
||||||
|
OUTPUT_DIR = build
|
||||||
|
TARGET = $(ARTIFACT)
|
||||||
|
|
||||||
|
CC = qcc -Vgcc_nto$(PLATFORM)
|
||||||
|
CXX = qcc -lang-c++ -Vgcc_nto$(PLATFORM)
|
||||||
|
LD = $(CC)
|
||||||
|
|
||||||
|
INCLUDES += -I../../../
|
||||||
|
LIBS += -L../../../src/.libs/ -lwolfssl
|
||||||
|
LIBS += -lsocket -lm
|
||||||
|
CCFLAGS += -O2 -Wall
|
||||||
|
|
||||||
|
SRCS = client-tls.c
|
||||||
|
|
||||||
|
OBJS = $(addprefix $(OUTPUT_DIR)/,$(addsuffix .o, $(basename $(SRCS))))
|
||||||
|
|
||||||
|
$(OUTPUT_DIR)/%.o: %.c
|
||||||
|
@mkdir -p $(dir $@)
|
||||||
|
$(CC) -c -o $@ $(INCLUDES) $(CCFLAGS) $<
|
||||||
|
|
||||||
|
$(TARGET):$(OBJS)
|
||||||
|
$(LD) -o $(TARGET) $(OBJS) $(LIBS)
|
||||||
|
|
||||||
|
all: $(TARGET)
|
||||||
|
|
||||||
|
clean:
|
||||||
|
rm -rf $(OUTPUT_DIR) $(ARTIFACT)
|
||||||
|
|
||||||
|
rebuild: clean all
|
266
IDE/QNX/example-client/client-tls.c
Normal file
266
IDE/QNX/example-client/client-tls.c
Normal file
@ -0,0 +1,266 @@
|
|||||||
|
/* client-tls.c
|
||||||
|
*
|
||||||
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
|
*
|
||||||
|
* This file is part of wolfSSL.
|
||||||
|
*
|
||||||
|
* wolfSSL is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* wolfSSL is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this program; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
|
/* socket includes */
|
||||||
|
#include <sys/socket.h>
|
||||||
|
#include <arpa/inet.h>
|
||||||
|
#include <netinet/in.h>
|
||||||
|
#include <unistd.h>
|
||||||
|
|
||||||
|
/* wolfSSL */
|
||||||
|
#include <wolfssl/options.h>
|
||||||
|
#include <wolfssl/ssl.h>
|
||||||
|
|
||||||
|
/* malloc out buffer and fill it with converted DER to PEM
|
||||||
|
* returns pem size on success
|
||||||
|
*/
|
||||||
|
static int convertDerToPem(int type, char* file, unsigned char **out)
|
||||||
|
{
|
||||||
|
int derSz, pemSz;
|
||||||
|
unsigned char der[4096];
|
||||||
|
unsigned char *pem;
|
||||||
|
FILE* f;
|
||||||
|
|
||||||
|
f = fopen(file, "rb");
|
||||||
|
if (f == NULL) {
|
||||||
|
fprintf(stderr, "unable to open cert file %s\n", file);
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
derSz = fread(der, 1, sizeof(der), f);
|
||||||
|
fclose(f);
|
||||||
|
|
||||||
|
pemSz = wc_DerToPemEx(der, derSz, NULL, 0, NULL, type);
|
||||||
|
if (pemSz <= 0) {
|
||||||
|
fprintf(stderr, "issue getting pem size needed\n");
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
pem = (unsigned char*)malloc(pemSz);
|
||||||
|
if (pem == NULL) {
|
||||||
|
fprintf(stderr, "issue malloc'ing pem size needed\n");
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
pemSz = wc_DerToPemEx(der, derSz, pem, pemSz, NULL, type);
|
||||||
|
if (pemSz <= 0) {
|
||||||
|
fprintf(stderr, "issue %d converting der to pem\n", pemSz);
|
||||||
|
free(pem);
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
*out = pem;
|
||||||
|
return pemSz;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
int main(int argc, char** argv)
|
||||||
|
{
|
||||||
|
int sockfd;
|
||||||
|
struct sockaddr_in servAddr;
|
||||||
|
char buff[256];
|
||||||
|
size_t len;
|
||||||
|
int ret;
|
||||||
|
int port;
|
||||||
|
|
||||||
|
int pemSz;
|
||||||
|
unsigned char *pem;
|
||||||
|
FILE* f;
|
||||||
|
|
||||||
|
/* declare wolfSSL objects */
|
||||||
|
WOLFSSL_CTX* ctx;
|
||||||
|
WOLFSSL* ssl;
|
||||||
|
|
||||||
|
/* Check for proper calling convention */
|
||||||
|
if (argc != 6) {
|
||||||
|
printf("usage: %s <port> <IPv4 address> <CA PEM> <cert DER> <key DER>\n",
|
||||||
|
argv[0]);
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
port = atoi(argv[1]);
|
||||||
|
|
||||||
|
/* Create a socket that uses an internet IPv4 address,
|
||||||
|
* Sets the socket to be stream based (TCP),
|
||||||
|
* 0 means choose the default protocol. */
|
||||||
|
if ((sockfd = socket(AF_INET, SOCK_STREAM, 0)) == -1) {
|
||||||
|
fprintf(stderr, "ERROR: failed to create the socket\n");
|
||||||
|
ret = -1;
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Initialize the server address struct with zeros */
|
||||||
|
memset(&servAddr, 0, sizeof(servAddr));
|
||||||
|
|
||||||
|
/* Fill in the server address */
|
||||||
|
servAddr.sin_family = AF_INET; /* using IPv4 */
|
||||||
|
servAddr.sin_port = htons(port); /* on DEFAULT_PORT */
|
||||||
|
|
||||||
|
/* Get the server IPv4 address from the command line call */
|
||||||
|
if (inet_pton(AF_INET, argv[2], &servAddr.sin_addr) != 1) {
|
||||||
|
fprintf(stderr, "ERROR: invalid address\n");
|
||||||
|
ret = -1;
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Connect to the server */
|
||||||
|
if ((ret = connect(sockfd, (struct sockaddr*) &servAddr, sizeof(servAddr)))
|
||||||
|
== -1) {
|
||||||
|
fprintf(stderr, "ERROR: failed to connect\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*---------------------------------*/
|
||||||
|
/* Start of security */
|
||||||
|
/*---------------------------------*/
|
||||||
|
/* Initialize wolfSSL */
|
||||||
|
if ((ret = wolfSSL_Init()) != WOLFSSL_SUCCESS) {
|
||||||
|
fprintf(stderr, "ERROR: Failed to initialize the library\n");
|
||||||
|
goto socket_cleanup;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Create and initialize WOLFSSL_CTX */
|
||||||
|
if ((ctx = wolfSSL_CTX_new(wolfSSLv23_client_method())) == NULL) {
|
||||||
|
fprintf(stderr, "ERROR: failed to create WOLFSSL_CTX\n");
|
||||||
|
ret = -1;
|
||||||
|
goto socket_cleanup;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* load cert and convert DER to PEM using dynamic length */
|
||||||
|
pemSz = convertDerToPem(CERT_TYPE, argv[4], &pem);
|
||||||
|
if (pemSz <= 0) {
|
||||||
|
fprintf(stderr, "ERROR: converting DER cert to PEM\n");
|
||||||
|
ret = -1;
|
||||||
|
goto socket_cleanup;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (wolfSSL_CTX_use_certificate_buffer(ctx, pem, pemSz,
|
||||||
|
WOLFSSL_FILETYPE_PEM) != WOLFSSL_SUCCESS) {
|
||||||
|
fprintf(stderr, "issue loading in pem cert\n");
|
||||||
|
ret = -1;
|
||||||
|
free(pem);
|
||||||
|
goto socket_cleanup;
|
||||||
|
}
|
||||||
|
free(pem);
|
||||||
|
|
||||||
|
/* load key and convert DER to PEM using dynamic length */
|
||||||
|
pemSz = convertDerToPem(PRIVATEKEY_TYPE, argv[5], &pem);
|
||||||
|
if (pemSz <= 0) {
|
||||||
|
fprintf(stderr, "ERROR: converting DER key to PEM\n");
|
||||||
|
ret = -1;
|
||||||
|
goto socket_cleanup;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (wolfSSL_CTX_use_PrivateKey_buffer(ctx, pem, pemSz,
|
||||||
|
WOLFSSL_FILETYPE_PEM) != WOLFSSL_SUCCESS) {
|
||||||
|
fprintf(stderr, "issue loading in pem key\n");
|
||||||
|
ret = -1;
|
||||||
|
free(pem);
|
||||||
|
goto socket_cleanup;
|
||||||
|
}
|
||||||
|
free(pem);
|
||||||
|
|
||||||
|
/* Load client certificates into WOLFSSL_CTX */
|
||||||
|
f = fopen(argv[3], "rb");
|
||||||
|
if (f == NULL) {
|
||||||
|
fprintf(stderr, "unable to open %s\n", argv[3]);
|
||||||
|
ret = -1;
|
||||||
|
goto socket_cleanup;
|
||||||
|
}
|
||||||
|
fseek(f, 0, SEEK_END);
|
||||||
|
pemSz = ftell(f);
|
||||||
|
rewind(f);
|
||||||
|
pem = malloc(pemSz);
|
||||||
|
if (pem == NULL) {
|
||||||
|
fclose(f);
|
||||||
|
ret = -1;
|
||||||
|
goto socket_cleanup;
|
||||||
|
}
|
||||||
|
pemSz = fread(pem, 1, pemSz, f);
|
||||||
|
fclose(f);
|
||||||
|
|
||||||
|
ret = wolfSSL_CTX_load_verify_buffer(ctx, pem, pemSz, WOLFSSL_FILETYPE_PEM);
|
||||||
|
if (ret != SSL_SUCCESS) {
|
||||||
|
fprintf(stderr, "ERROR %d: failed to load %s, please check the file.\n",
|
||||||
|
ret, argv[3]);
|
||||||
|
free(pem);
|
||||||
|
goto ctx_cleanup;
|
||||||
|
}
|
||||||
|
free(pem);
|
||||||
|
|
||||||
|
/* Create a WOLFSSL object */
|
||||||
|
if ((ssl = wolfSSL_new(ctx)) == NULL) {
|
||||||
|
fprintf(stderr, "ERROR: failed to create WOLFSSL object\n");
|
||||||
|
ret = -1;
|
||||||
|
goto ctx_cleanup;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Attach wolfSSL to the socket */
|
||||||
|
if ((ret = wolfSSL_set_fd(ssl, sockfd)) != WOLFSSL_SUCCESS) {
|
||||||
|
fprintf(stderr, "ERROR: Failed to set the file descriptor\n");
|
||||||
|
goto cleanup;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Connect to wolfSSL on the server side */
|
||||||
|
if ((ret = wolfSSL_connect(ssl)) != SSL_SUCCESS) {
|
||||||
|
fprintf(stderr, "ERROR: failed to connect to wolfSSL\n");
|
||||||
|
goto cleanup;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Get a message for the server from stdin */
|
||||||
|
printf("Message for server: ");
|
||||||
|
memset(buff, 0, sizeof(buff));
|
||||||
|
if (fgets(buff, sizeof(buff), stdin) == NULL) {
|
||||||
|
fprintf(stderr, "ERROR: failed to get message for server\n");
|
||||||
|
ret = -1;
|
||||||
|
goto cleanup;
|
||||||
|
}
|
||||||
|
len = strnlen(buff, sizeof(buff));
|
||||||
|
|
||||||
|
/* Send the message to the server */
|
||||||
|
if ((ret = wolfSSL_write(ssl, buff, len)) != len) {
|
||||||
|
fprintf(stderr, "ERROR: failed to write entire message\n");
|
||||||
|
fprintf(stderr, "%d bytes of %d bytes were sent", ret, (int) len);
|
||||||
|
goto cleanup;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Read the server data into our buff array */
|
||||||
|
memset(buff, 0, sizeof(buff));
|
||||||
|
if ((ret = wolfSSL_read(ssl, buff, sizeof(buff)-1)) == -1) {
|
||||||
|
fprintf(stderr, "ERROR: failed to read\n");
|
||||||
|
goto cleanup;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Print to stdout any data the server sends */
|
||||||
|
printf("Server: %s\n", buff);
|
||||||
|
|
||||||
|
/* Cleanup and return */
|
||||||
|
cleanup:
|
||||||
|
wolfSSL_free(ssl); /* Free the wolfSSL object */
|
||||||
|
ctx_cleanup:
|
||||||
|
wolfSSL_CTX_free(ctx); /* Free the wolfSSL context object */
|
||||||
|
wolfSSL_Cleanup(); /* Cleanup the wolfSSL environment */
|
||||||
|
socket_cleanup:
|
||||||
|
close(sockfd); /* Close the connection to the server */
|
||||||
|
end:
|
||||||
|
return ret; /* Return reporting a success */
|
||||||
|
}
|
33
IDE/QNX/example-cmac/Makefile
Normal file
33
IDE/QNX/example-cmac/Makefile
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
ARTIFACT = cmac-test
|
||||||
|
|
||||||
|
#Build architecture/variant string, possible values: x86, armv7le, etc...
|
||||||
|
PLATFORM = armv7le
|
||||||
|
OUTPUT_DIR = build
|
||||||
|
TARGET = $(ARTIFACT)
|
||||||
|
|
||||||
|
CC = qcc -Vgcc_nto$(PLATFORM)
|
||||||
|
CXX = qcc -lang-c++ -Vgcc_nto$(PLATFORM)
|
||||||
|
LD = $(CC)
|
||||||
|
|
||||||
|
INCLUDES += -I../../../
|
||||||
|
LIBS += -L../../../src/.libs/ -lwolfssl
|
||||||
|
LIBS += -lsocket -lm
|
||||||
|
CCFLAGS += -O2 -Wall
|
||||||
|
|
||||||
|
SRCS = cmac-test.c
|
||||||
|
|
||||||
|
OBJS = $(addprefix $(OUTPUT_DIR)/,$(addsuffix .o, $(basename $(SRCS))))
|
||||||
|
|
||||||
|
$(OUTPUT_DIR)/%.o: %.c
|
||||||
|
@mkdir -p $(dir $@)
|
||||||
|
$(CC) -c -o $@ $(INCLUDES) $(CCFLAGS) $<
|
||||||
|
|
||||||
|
$(TARGET):$(OBJS)
|
||||||
|
$(LD) -o $(TARGET) $(OBJS) $(LIBS)
|
||||||
|
|
||||||
|
all: $(TARGET)
|
||||||
|
|
||||||
|
clean:
|
||||||
|
rm -rf $(OUTPUT_DIR) $(ARTIFACT)
|
||||||
|
|
||||||
|
rebuild: clean all
|
110
IDE/QNX/example-cmac/cmac-test.c
Normal file
110
IDE/QNX/example-cmac/cmac-test.c
Normal file
@ -0,0 +1,110 @@
|
|||||||
|
/* cmac-test.c
|
||||||
|
*
|
||||||
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
|
*
|
||||||
|
* This file is part of wolfSSL.
|
||||||
|
*
|
||||||
|
* wolfSSL is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* wolfSSL is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this program; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include <wolfssl/options.h>
|
||||||
|
#include <wolfssl/wolfcrypt/cmac.h>
|
||||||
|
#include <wolfssl/wolfcrypt/port/caam/wolfcaam.h>
|
||||||
|
|
||||||
|
#include <sys/mman.h>
|
||||||
|
#include <hw/inout.h>
|
||||||
|
#include <sys/iofunc.h>
|
||||||
|
#include <sys/neutrino.h>
|
||||||
|
|
||||||
|
static const byte k256[] =
|
||||||
|
{
|
||||||
|
0x60, 0x3d, 0xeb, 0x10, 0x15, 0xca, 0x71, 0xbe,
|
||||||
|
0x2b, 0x73, 0xae, 0xf0, 0x85, 0x7d, 0x77, 0x81,
|
||||||
|
0x1f, 0x35, 0x2c, 0x07, 0x3b, 0x61, 0x08, 0xd7,
|
||||||
|
0x2d, 0x98, 0x10, 0xa3, 0x09, 0x14, 0xdf, 0xf4
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
static int createTag(const byte* key, int keySz, byte* msg, int msgSz,
|
||||||
|
byte* msg2, int msg2Sz)
|
||||||
|
{
|
||||||
|
Cmac cmac;
|
||||||
|
byte tag[AES_BLOCK_SIZE];
|
||||||
|
word32 i, tagSz;
|
||||||
|
byte out[48];
|
||||||
|
word32 outSz;
|
||||||
|
|
||||||
|
XMEMSET(tag, 0, sizeof(tag));
|
||||||
|
tagSz = AES_BLOCK_SIZE;
|
||||||
|
|
||||||
|
outSz = 48;
|
||||||
|
wc_caamCoverKey((byte*)key, keySz, out, &outSz, 0);
|
||||||
|
|
||||||
|
if (wc_InitCmac(&cmac, NULL, keySz, WC_CMAC_AES, out) != 0) {
|
||||||
|
printf("Cmac init error\n");
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (wc_CmacUpdate(&cmac, msg, msgSz) != 0) {
|
||||||
|
printf("message update error\n");
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (msg2Sz > 0) {
|
||||||
|
if (wc_CmacUpdate(&cmac, msg2, msg2Sz) != 0) {
|
||||||
|
printf("message2 update error\n");
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (wc_CmacFinal(&cmac, tag, &tagSz) != 0) {
|
||||||
|
printf("create tag error\n");
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
printf("TAG :");
|
||||||
|
for (i = 0; i < tagSz; i++)
|
||||||
|
printf("%02X", tag[i]);
|
||||||
|
printf("\n");
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
int main(int argc, char* argv[])
|
||||||
|
{
|
||||||
|
uintptr_t virtual_base;
|
||||||
|
byte msg[256];
|
||||||
|
byte msg2[256];
|
||||||
|
int i;
|
||||||
|
|
||||||
|
printf("checking out permissions, can we call mmap_device_io?\n");
|
||||||
|
virtual_base = mmap_device_io(0x00010000, 0x02140000);
|
||||||
|
if (virtual_base == (uintptr_t)MAP_FAILED) {
|
||||||
|
perror("mmap_device_io failed for base address ");
|
||||||
|
}
|
||||||
|
|
||||||
|
wolfCrypt_Init();
|
||||||
|
|
||||||
|
XMEMSET(msg, 1, sizeof(msg));
|
||||||
|
XMEMSET(msg2, 9, sizeof(msg2));
|
||||||
|
|
||||||
|
for (i = 0; i < 256; i+=8) {
|
||||||
|
if (createTag(k256, sizeof(k256), msg, i, NULL, 0) != 0)
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
wolfCrypt_Cleanup();
|
||||||
|
return 0;
|
||||||
|
}
|
33
IDE/QNX/example-server/Makefile
Normal file
33
IDE/QNX/example-server/Makefile
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
ARTIFACT = server-tls
|
||||||
|
|
||||||
|
#Build architecture/variant string, possible values: x86, armv7le, etc...
|
||||||
|
PLATFORM = armv7le
|
||||||
|
OUTPUT_DIR = build
|
||||||
|
TARGET = $(ARTIFACT)
|
||||||
|
|
||||||
|
CC = qcc -Vgcc_nto$(PLATFORM)
|
||||||
|
CXX = qcc -lang-c++ -Vgcc_nto$(PLATFORM)
|
||||||
|
LD = $(CC)
|
||||||
|
|
||||||
|
INCLUDES += -I../../../
|
||||||
|
LIBS += -L../../../src/.libs/ -lwolfssl
|
||||||
|
LIBS += -lsocket -lm
|
||||||
|
CCFLAGS += -O2 -Wall
|
||||||
|
|
||||||
|
SRCS = server-tls.c
|
||||||
|
|
||||||
|
OBJS = $(addprefix $(OUTPUT_DIR)/,$(addsuffix .o, $(basename $(SRCS))))
|
||||||
|
|
||||||
|
$(OUTPUT_DIR)/%.o: %.c
|
||||||
|
@mkdir -p $(dir $@)
|
||||||
|
$(CC) -c -o $@ $(INCLUDES) $(CCFLAGS) $<
|
||||||
|
|
||||||
|
$(TARGET):$(OBJS)
|
||||||
|
$(LD) -o $(TARGET) $(OBJS) $(LIBS)
|
||||||
|
|
||||||
|
all: $(TARGET)
|
||||||
|
|
||||||
|
clean:
|
||||||
|
rm -rf $(OUTPUT_DIR) $(ARTIFACT)
|
||||||
|
|
||||||
|
rebuild: clean all
|
392
IDE/QNX/example-server/server-tls.c
Normal file
392
IDE/QNX/example-server/server-tls.c
Normal file
@ -0,0 +1,392 @@
|
|||||||
|
/* server-tls.c
|
||||||
|
*
|
||||||
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
|
*
|
||||||
|
* This file is part of wolfSSL.
|
||||||
|
*
|
||||||
|
* wolfSSL is free software; you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* wolfSSL is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with this program; if not, write to the Free Software
|
||||||
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
|
/* socket includes */
|
||||||
|
#include <sys/socket.h>
|
||||||
|
#include <arpa/inet.h>
|
||||||
|
#include <netinet/in.h>
|
||||||
|
#include <unistd.h>
|
||||||
|
|
||||||
|
/* wolfSSL */
|
||||||
|
#include <wolfssl/options.h>
|
||||||
|
#include <wolfssl/ssl.h>
|
||||||
|
#include <wolfssl/wolfcrypt/ecc.h>
|
||||||
|
#include <wolfssl/wolfcrypt/port/caam/wolfcaam.h> /* functions for blob/cover*/
|
||||||
|
|
||||||
|
#define DEFAULT_PORT 11111
|
||||||
|
#define ECC_KEY_SIZE 32
|
||||||
|
|
||||||
|
#undef USE_CERT_BUFFERS_256
|
||||||
|
#define USE_CERT_BUFFERS_256
|
||||||
|
#include <wolfssl/certs_test.h>
|
||||||
|
|
||||||
|
/* creates a blob then opens it, returns 0 on success */
|
||||||
|
static int test_blob(byte* key, int keySz)
|
||||||
|
{
|
||||||
|
int ret, i;
|
||||||
|
byte out[keySz + WC_CAAM_BLOB_SZ];
|
||||||
|
int outSz;
|
||||||
|
int keyOutSz;
|
||||||
|
|
||||||
|
byte keymod[WC_CAAM_BLACK_KEYMOD_SZ];
|
||||||
|
int keymodSz = WC_CAAM_BLACK_KEYMOD_SZ;
|
||||||
|
|
||||||
|
/* using a key mod of all 1's */
|
||||||
|
XMEMSET(keymod, 1, keymodSz);
|
||||||
|
|
||||||
|
/* example of creating black blog with key for later */
|
||||||
|
outSz = keySz + WC_CAAM_BLOB_SZ;
|
||||||
|
ret = wc_caamCreateBlob_ex(key, keySz, out, (word32*)&outSz,
|
||||||
|
WC_CAAM_BLOB_BLACK, keymod, keymodSz);
|
||||||
|
if (ret != 0) {
|
||||||
|
printf("Error creating black blob\n");
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
printf("created black blob :");
|
||||||
|
for (i = 0; i < outSz; i++)
|
||||||
|
printf("%02X,", out[i]);
|
||||||
|
printf("\n");
|
||||||
|
|
||||||
|
|
||||||
|
/* open black blob and overwrite key, this is to show that the opened blob
|
||||||
|
* can be used for the upcoming TLS connection */
|
||||||
|
memset(key, 0, keySz);
|
||||||
|
keyOutSz = keySz;
|
||||||
|
ret = wc_caamOpenBlob_ex(out, outSz, key, (word32*)&keyOutSz,
|
||||||
|
WC_CAAM_BLOB_BLACK, keymod, keymodSz);
|
||||||
|
if (ret != 0) {
|
||||||
|
printf("Error opening black blob\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* example of covering an existing key and then making a black blob with it
|
||||||
|
* note that generating an ECC completely in secure memory already covered can
|
||||||
|
* be done by call wc_ecc_make_key */
|
||||||
|
int cover(ecc_key* keyOut, const byte* der, word32 derSz)
|
||||||
|
{
|
||||||
|
int ret;
|
||||||
|
ecc_key notSecure;
|
||||||
|
word32 idx = 0;
|
||||||
|
|
||||||
|
/* format bit plus public key x and y parameter */
|
||||||
|
byte x963[(ECC_KEY_SIZE*2) + 1];
|
||||||
|
word32 x963Sz = (ECC_KEY_SIZE*2) + 1;
|
||||||
|
|
||||||
|
/* uncovered private key */
|
||||||
|
byte d[ECC_KEY_SIZE];
|
||||||
|
word32 dSz = ECC_KEY_SIZE;
|
||||||
|
|
||||||
|
byte blackKey[ECC_KEY_SIZE + WC_CAAM_MAC_SZ];
|
||||||
|
word32 blackKeySz = ECC_KEY_SIZE + WC_CAAM_MAC_SZ;
|
||||||
|
|
||||||
|
|
||||||
|
/* The DER buffer for test case does not contain a black key, here we will
|
||||||
|
* extract the key information, cover it (make it a black key), and then
|
||||||
|
* import that into 'keyOut' which will create a secure partition on import.
|
||||||
|
*
|
||||||
|
* These steps of covering and importing can be avoided with a call to
|
||||||
|
* wc_ecc_make_key which creates a new black key that never leaves the CAAM.
|
||||||
|
* The cover process is only being used to make use of an existing key that
|
||||||
|
* matches the test certificate.
|
||||||
|
*/
|
||||||
|
wc_ecc_init(¬Secure);
|
||||||
|
if (wc_EccPrivateKeyDecode(der, &idx, ¬Secure, derSz) != 0) {
|
||||||
|
printf("Error extracting ECC der buffer\n");
|
||||||
|
ret = -1;
|
||||||
|
goto done;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Get the uncovered key values */
|
||||||
|
if (wc_ecc_export_private_raw(¬Secure, NULL, NULL, NULL, NULL, d, &dSz)
|
||||||
|
!= 0) {
|
||||||
|
printf("Error getting ecc key values\n");
|
||||||
|
ret = -1;
|
||||||
|
goto done;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (wc_ecc_export_x963(¬Secure, x963, &x963Sz) != 0) {
|
||||||
|
printf("Error getting ecc public key\n");
|
||||||
|
ret = -1;
|
||||||
|
goto done;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Cover up the private key (make it a black key, encrypting with AES-CCM)*/
|
||||||
|
XMEMSET(blackKey, 0, blackKeySz);
|
||||||
|
if (wc_caamCoverKey(d, dSz, blackKey, &blackKeySz, 0) != 0) {
|
||||||
|
printf("Error covering up the private key\n");
|
||||||
|
ret = -1;
|
||||||
|
goto done;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Sanity check to compare covered key versus plain text */
|
||||||
|
if (XMEMCMP(d, blackKey, dSz) == 0) {
|
||||||
|
printf("Something went wrong with key cover!!\n");
|
||||||
|
ret = -1;
|
||||||
|
goto done;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (test_blob(blackKey, blackKeySz - WC_CAAM_MAC_SZ) != 0) {
|
||||||
|
printf("test blob failed\n");
|
||||||
|
ret = -1;
|
||||||
|
goto done;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* zero out the plain text buffer and free key */
|
||||||
|
XMEMSET(d, 0, dSz);
|
||||||
|
|
||||||
|
/* Import the black key into a ecc_key structure (this step tries to create
|
||||||
|
* a partition of secure memory marked CPS)
|
||||||
|
*/
|
||||||
|
ret = wc_ecc_import_private_key(blackKey, blackKeySz, x963, x963Sz, keyOut);
|
||||||
|
if (ret != 0) {
|
||||||
|
printf("Error importing black key into secure memory %d\n", ret);
|
||||||
|
wc_ecc_free(keyOut);
|
||||||
|
goto done;
|
||||||
|
}
|
||||||
|
printf("blackKeySz = %d, virtual secure address ecc_key.blackKey = 0x%08X\n",
|
||||||
|
blackKeySz, keyOut->blackKey);
|
||||||
|
|
||||||
|
ret = 0;
|
||||||
|
done:
|
||||||
|
|
||||||
|
wc_ecc_free(¬Secure);
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* callback function for creating ECC signatures */
|
||||||
|
static int TLS_ECC_Sign_callback(WOLFSSL* ssl, const unsigned char* in,
|
||||||
|
unsigned int inSz, unsigned char* out, word32* outSz,
|
||||||
|
const unsigned char* keyDer, unsigned int keySz,
|
||||||
|
void* ctx)
|
||||||
|
{
|
||||||
|
ecc_key* blackKey;
|
||||||
|
|
||||||
|
printf("Using ECC sign callback\n");
|
||||||
|
|
||||||
|
if (ctx == NULL) {
|
||||||
|
printf("Was expecting a black key passed along with WOLFSSL\n");
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
blackKey = (ecc_key*)ctx;
|
||||||
|
|
||||||
|
return wc_ecc_sign_hash(in, inSz, out, outSz, NULL, blackKey);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* callback function to do ECDH operation in TLS handshake */
|
||||||
|
static int TLS_ECDH_callback(WOLFSSL* ssl, struct ecc_key* otherKey,
|
||||||
|
unsigned char* pubKeyDer, word32* pubKeySz,
|
||||||
|
unsigned char* out, word32* outlen,
|
||||||
|
int side, void* ctx)
|
||||||
|
{
|
||||||
|
int ret= -1;
|
||||||
|
|
||||||
|
printf("Using ECDH callback\n");
|
||||||
|
|
||||||
|
if (ctx == NULL) {
|
||||||
|
printf("Was expecting a black key passed along with WOLFSSH\n");
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* this is being called from client end */
|
||||||
|
if (side == WOLFSSL_CLIENT_END) {
|
||||||
|
}
|
||||||
|
|
||||||
|
/* this is being called from server end */
|
||||||
|
if (side == WOLFSSL_SERVER_END) {
|
||||||
|
ecc_key pub;
|
||||||
|
|
||||||
|
wc_ecc_init(&pub);
|
||||||
|
if (wc_ecc_import_x963(pubKeyDer, *pubKeySz, &pub) != 0) {
|
||||||
|
printf("Issue decoding the public key to generate shared secret\n");
|
||||||
|
wc_ecc_free(&pub);
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* otherKey is the ephemeral private key created with ECDHE cipher
|
||||||
|
* suites. As long as EccKeyGenCb has not been set this key was created
|
||||||
|
* with wc_ecc_make_key_ex, which when used with NIST P256 it will
|
||||||
|
* automatically try to create a secure black key
|
||||||
|
*/
|
||||||
|
ret = wc_ecc_shared_secret(otherKey, &pub, out, outlen);
|
||||||
|
wc_ecc_free(&pub);
|
||||||
|
}
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
int main()
|
||||||
|
{
|
||||||
|
int sockfd;
|
||||||
|
int connd = 0;
|
||||||
|
struct sockaddr_in servAddr;
|
||||||
|
struct sockaddr_in clientAddr;
|
||||||
|
socklen_t size = sizeof(clientAddr);
|
||||||
|
char buff[256];
|
||||||
|
size_t len;
|
||||||
|
int ret;
|
||||||
|
const char* reply = "I hear ya fa shizzle!\n";
|
||||||
|
|
||||||
|
ecc_key blackKey;
|
||||||
|
|
||||||
|
/* declare wolfSSL objects */
|
||||||
|
WOLFSSL_CTX* ctx = NULL;
|
||||||
|
WOLFSSL* ssl = NULL;
|
||||||
|
|
||||||
|
/* Initialize wolfSSL */
|
||||||
|
if (wolfSSL_Init() != WOLFSSL_SUCCESS) {
|
||||||
|
fprintf(stderr, "issue with wolfSSL_Init()\n");
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
wolfSSL_Debugging_ON();
|
||||||
|
wc_ecc_init(&blackKey);
|
||||||
|
|
||||||
|
/* Create a socket that uses an internet IPv4 address,
|
||||||
|
* Sets the socket to be stream based (TCP),
|
||||||
|
* 0 means choose the default protocol. */
|
||||||
|
if ((sockfd = socket(AF_INET, SOCK_STREAM, 0)) == -1) {
|
||||||
|
fprintf(stderr, "ERROR: failed to create the socket\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Create and initialize WOLFSSL_CTX */
|
||||||
|
if ((ctx = wolfSSL_CTX_new(wolfTLSv1_2_server_method())) == NULL) {
|
||||||
|
fprintf(stderr, "ERROR: failed to create WOLFSSL_CTX\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Load server certificates into WOLFSSL_CTX */
|
||||||
|
if (wolfSSL_CTX_use_certificate_buffer(ctx, serv_ecc_der_256,
|
||||||
|
sizeof_serv_ecc_der_256, SSL_FILETYPE_ASN1) != SSL_SUCCESS) {
|
||||||
|
printf("error loading in certificate buffer\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
// wolfSSL_CTX_use_PrivateKey_buffer(ctx, ecc_key_der_256, sizeof_ecc_key_der_256, SSL_FILETYPE_ASN1);
|
||||||
|
|
||||||
|
if (cover(&blackKey, ecc_key_der_256, sizeof_ecc_key_der_256) != 0) {
|
||||||
|
printf("error covering up key\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* set signing callback to use during TLS connection */
|
||||||
|
wolfSSL_CTX_SetEccSignCb(ctx, TLS_ECC_Sign_callback);
|
||||||
|
|
||||||
|
/* set ECDH shared secret callback to use during TLS connection */
|
||||||
|
wolfSSL_CTX_SetEccSharedSecretCb(ctx, TLS_ECDH_callback);
|
||||||
|
|
||||||
|
/* Initialize the server address struct with zeros */
|
||||||
|
memset(&servAddr, 0, sizeof(servAddr));
|
||||||
|
|
||||||
|
/* Fill in the server address */
|
||||||
|
servAddr.sin_family = AF_INET; /* using IPv4 */
|
||||||
|
servAddr.sin_port = htons(DEFAULT_PORT); /* on DEFAULT_PORT */
|
||||||
|
servAddr.sin_addr.s_addr = INADDR_ANY; /* from anywhere */
|
||||||
|
|
||||||
|
/* Bind the server socket to our port */
|
||||||
|
if (bind(sockfd, (struct sockaddr*)&servAddr, sizeof(servAddr)) == -1) {
|
||||||
|
fprintf(stderr, "ERROR: failed to bind\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Listen for a new connection, allow 5 pending connections */
|
||||||
|
if (listen(sockfd, 5) == -1) {
|
||||||
|
fprintf(stderr, "ERROR: failed to listen\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Continue to accept clients until shutdown is issued */
|
||||||
|
printf("Waiting for a connection...\n");
|
||||||
|
|
||||||
|
/* Accept client connections */
|
||||||
|
if ((connd = accept(sockfd, (struct sockaddr*)&clientAddr, &size)) == -1) {
|
||||||
|
fprintf(stderr, "ERROR: failed to accept the connection\n\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Create a WOLFSSL object */
|
||||||
|
if ((ssl = wolfSSL_new(ctx)) == NULL) {
|
||||||
|
fprintf(stderr, "ERROR: failed to create WOLFSSL object\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Attach wolfSSL to the socket */
|
||||||
|
wolfSSL_set_fd(ssl, connd);
|
||||||
|
|
||||||
|
/* associate the covered up black key with the WOLFSSH structure,
|
||||||
|
* this will then get passed as the last argument to the callbacks */
|
||||||
|
wolfSSL_SetEccSignCtx(ssl, (void*)&blackKey);
|
||||||
|
wolfSSL_SetEccSharedSecretCtx(ssl, (void*)&blackKey);
|
||||||
|
|
||||||
|
/* Establish TLS connection */
|
||||||
|
ret = wolfSSL_accept(ssl);
|
||||||
|
if (ret != SSL_SUCCESS) {
|
||||||
|
fprintf(stderr, "wolfSSL_accept error = %d\n",
|
||||||
|
wolfSSL_get_error(ssl, ret));
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
printf("Client connected successfully\n");
|
||||||
|
|
||||||
|
/* Read the client data into our buff array */
|
||||||
|
memset(buff, 0, sizeof(buff));
|
||||||
|
if (wolfSSL_read(ssl, buff, sizeof(buff)-1) == -1) {
|
||||||
|
fprintf(stderr, "ERROR: failed to read\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Print to stdout any data the client sends */
|
||||||
|
printf("Client: %s\n", buff);
|
||||||
|
|
||||||
|
/* Write our reply into buff */
|
||||||
|
memset(buff, 0, sizeof(buff));
|
||||||
|
memcpy(buff, reply, strlen(reply));
|
||||||
|
len = strnlen(buff, sizeof(buff));
|
||||||
|
|
||||||
|
/* Reply back to the client */
|
||||||
|
if (wolfSSL_write(ssl, buff, len) != len) {
|
||||||
|
fprintf(stderr, "ERROR: failed to write\n");
|
||||||
|
goto end;
|
||||||
|
}
|
||||||
|
|
||||||
|
end:
|
||||||
|
/* Cleanup after this connection */
|
||||||
|
wolfSSL_free(ssl); /* Free the wolfSSL object */
|
||||||
|
close(connd); /* Close the connection to the client */
|
||||||
|
wc_ecc_free(&blackKey);
|
||||||
|
|
||||||
|
printf("Shutdown complete\n");
|
||||||
|
|
||||||
|
/* Cleanup and return */
|
||||||
|
wolfSSL_CTX_free(ctx); /* Free the wolfSSL context object */
|
||||||
|
wolfSSL_Cleanup(); /* Cleanup the wolfSSL environment */
|
||||||
|
close(sockfd); /* Close the socket listening for clients */
|
||||||
|
return 0; /* Return reporting a success */
|
||||||
|
}
|
12
IDE/QNX/include.am
Normal file
12
IDE/QNX/include.am
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
# vim:ft=automake
|
||||||
|
# included from Top Level Makefile.am
|
||||||
|
# All paths should be given relative to the root
|
||||||
|
|
||||||
|
EXTRA_DIST+= IDE/QNX/README.md
|
||||||
|
EXTRA_DIST+= IDE/QNX/CAAM-DRIVER/Makefile
|
||||||
|
EXTRA_DIST+= IDE/QNX/example-server/Makefile
|
||||||
|
EXTRA_DIST+= IDE/QNX/example-server/server-tls.c
|
||||||
|
EXTRA_DIST+= IDE/QNX/example-client/Makefile
|
||||||
|
EXTRA_DIST+= IDE/QNX/example-client/client-tls.c
|
||||||
|
EXTRA_DIST+= IDE/QNX/example-cmac/Makefile
|
||||||
|
EXTRA_DIST+= IDE/QNX/example-cmac/cmac-test.c
|
@ -1,6 +1,6 @@
|
|||||||
/* main.c
|
/* main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_settings.h
|
/* user_settings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* arm_startup.c
|
/* arm_startup.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* benchmark_main.c
|
/* benchmark_main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* kinetis_hw.c
|
/* kinetis_hw.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* retarget.c
|
/* retarget.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* test_main.c
|
/* test_main.c
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* strings.h
|
/* strings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* unistd.h
|
/* unistd.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
/* user_settings.h
|
/* user_settings.h
|
||||||
*
|
*
|
||||||
* Copyright (C) 2006-2020 wolfSSL Inc.
|
* Copyright (C) 2006-2021 wolfSSL Inc.
|
||||||
*
|
*
|
||||||
* This file is part of wolfSSL.
|
* This file is part of wolfSSL.
|
||||||
*
|
*
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user