btstack_crypto.c (b632467195a49e8a9031e7c7172e34855608b6bb) btstack_crypto.c (72c3a9edf416103e9c70b332ffd52431ba0dfd21)
1/*
2 * Copyright (C) 2017 BlueKitchen GmbH
3 *
4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions
6 * are met:
7 *
8 * 1. Redistributions of source code must retain the above copyright

--- 75 unchanged lines hidden (view full) ---

84// Software ECC-P256 implementation provided by micro-ecc
85#ifdef ENABLE_MICRO_ECC_P256
86#define ENABLE_ECC_P256
87#define USE_MICRO_ECC_P256
88#define USE_SOFTWARE_ECC_P256_IMPLEMENTATION
89#include "uECC.h"
90#endif
91
1/*
2 * Copyright (C) 2017 BlueKitchen GmbH
3 *
4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions
6 * are met:
7 *
8 * 1. Redistributions of source code must retain the above copyright

--- 75 unchanged lines hidden (view full) ---

84// Software ECC-P256 implementation provided by micro-ecc
85#ifdef ENABLE_MICRO_ECC_P256
86#define ENABLE_ECC_P256
87#define USE_MICRO_ECC_P256
88#define USE_SOFTWARE_ECC_P256_IMPLEMENTATION
89#include "uECC.h"
90#endif
91
92// Software ECC-P256 implementation provided by mbedTLS
92// Software ECC-P256 implementation provided by mbedTLS, allow config via MBEDTLS_CONFIG_FILE
93#ifdef HAVE_MBEDTLS_ECC_P256
94#define ENABLE_ECC_P256
95#define USE_MBEDTLS_ECC_P256
96#define USE_SOFTWARE_ECC_P256_IMPLEMENTATION
93#ifdef HAVE_MBEDTLS_ECC_P256
94#define ENABLE_ECC_P256
95#define USE_MBEDTLS_ECC_P256
96#define USE_SOFTWARE_ECC_P256_IMPLEMENTATION
97#include "mbedtls/config.h"
97#ifdef MBEDTLS_CONFIG_FILE
98#include MBEDTLS_CONFIG_FILE
99#else
100#include "mbedtls/mbedtls_config.h"
101#endif
98#include "mbedtls/platform.h"
99#include "mbedtls/ecp.h"
100#endif
101
102#if defined(ENABLE_LE_SECURE_CONNECTIONS) && !defined(ENABLE_ECC_P256)
103#define ENABLE_ECC_P256
104#endif
105

--- 1302 unchanged lines hidden ---
102#include "mbedtls/platform.h"
103#include "mbedtls/ecp.h"
104#endif
105
106#if defined(ENABLE_LE_SECURE_CONNECTIONS) && !defined(ENABLE_ECC_P256)
107#define ENABLE_ECC_P256
108#endif
109

--- 1302 unchanged lines hidden ---