Преглед изворни кода

Move curve25519 code to third_party/fiat.

This change doesn't actually introduce any Fiat code yet. It sets up the
directory structure to make the diffs in the next change clearer.

Change-Id: I38a21fb36b18a08b0907f9d37b7ef5d7d3137ede
Reviewed-on: https://boringssl-review.googlesource.com/22624
Reviewed-by: David Benjamin <davidben@google.com>
kris/onging/CECPQ3_patch15
Andres Erbsen пре 7 година
committed by Adam Langley
родитељ
комит
5b280a80df
11 измењених фајлова са 22 додато и 9 уклоњено
  1. +1
    -0
      CMakeLists.txt
  2. +2
    -1
      LICENSE
  3. +1
    -0
      crypto/CMakeLists.txt
  4. +0
    -1
      crypto/curve25519/CMakeLists.txt
  5. +1
    -1
      crypto/curve25519/spake25519.c
  6. +1
    -1
      crypto/curve25519/spake25519_test.cc
  7. +1
    -1
      crypto/curve25519/x25519-x86_64.c
  8. +9
    -0
      third_party/fiat/CMakeLists.txt
  9. +1
    -1
      third_party/fiat/curve25519.c
  10. +0
    -0
      third_party/fiat/internal.h
  11. +5
    -3
      util/generate_build_files.py

+ 1
- 0
CMakeLists.txt Прегледај датотеку

@@ -338,6 +338,7 @@ add_custom_command(
add_library(crypto_test_data OBJECT crypto_test_data.cc)

add_subdirectory(crypto)
add_subdirectory(third_party/fiat)
add_subdirectory(ssl)
add_subdirectory(ssl/test)
add_subdirectory(fipstools)


+ 2
- 1
LICENSE Прегледај датотеку

@@ -6,7 +6,8 @@ Contributors to BoringSSL are required to follow the CLA rules for Chromium:
https://cla.developers.google.com/clas

Some files from Intel are under yet another license, which is also included
underneath.
underneath. Files in third_party/ have their own licenses, as described
therein.

The OpenSSL toolkit stays under a dual license, i.e. both the conditions of the
OpenSSL License and the original SSLeay license apply to the toolkit. See below


+ 1
- 0
crypto/CMakeLists.txt Прегледај датотеку

@@ -179,6 +179,7 @@ add_library(
$<TARGET_OBJECTS:chacha>
$<TARGET_OBJECTS:poly1305>
$<TARGET_OBJECTS:curve25519>
$<TARGET_OBJECTS:fiat>
$<TARGET_OBJECTS:buf>
$<TARGET_OBJECTS:bn_extra>
$<TARGET_OBJECTS:bio>


+ 0
- 1
crypto/curve25519/CMakeLists.txt Прегледај датотеку

@@ -21,7 +21,6 @@ add_library(

OBJECT

curve25519.c
spake25519.c
x25519-x86_64.c



+ 1
- 1
crypto/curve25519/spake25519.c Прегледај датотеку

@@ -22,8 +22,8 @@
#include <openssl/rand.h>
#include <openssl/sha.h>

#include "internal.h"
#include "../internal.h"
#include "../../third_party/fiat/internal.h"


// The following precomputation tables are for the following


+ 1
- 1
crypto/curve25519/spake25519_test.cc Прегледај датотеку

@@ -23,7 +23,7 @@
#include <gtest/gtest.h>

#include "../internal.h"
#include "internal.h"
#include "../../third_party/fiat/internal.h"


// TODO(agl): add tests with fixed vectors once SPAKE2 is nailed down.


+ 1
- 1
crypto/curve25519/x25519-x86_64.c Прегледај датотеку

@@ -24,7 +24,7 @@
#include <string.h>

#include "../internal.h"
#include "internal.h"
#include "../../third_party/fiat/internal.h"


#if defined(BORINGSSL_X25519_X86_64)


+ 9
- 0
third_party/fiat/CMakeLists.txt Прегледај датотеку

@@ -0,0 +1,9 @@
include_directories(../../include)

add_library(
fiat

OBJECT

curve25519.c
)

crypto/curve25519/curve25519.c → third_party/fiat/curve25519.c Прегледај датотеку

@@ -30,7 +30,7 @@
#include <openssl/sha.h>

#include "internal.h"
#include "../internal.h"
#include "../../crypto/internal.h"


static const int64_t kBottom25Bits = INT64_C(0x1ffffff);

crypto/curve25519/internal.h → third_party/fiat/internal.h Прегледај датотеку


+ 5
- 3
util/generate_build_files.py Прегледај датотеку

@@ -587,7 +587,8 @@ def ExtractVariablesFromCMakeFile(cmakefile):

def main(platforms):
cmake = ExtractVariablesFromCMakeFile(os.path.join('src', 'sources.cmake'))
crypto_c_files = FindCFiles(os.path.join('src', 'crypto'), NoTestsNorFIPSFragments)
crypto_c_files = (FindCFiles(os.path.join('src', 'crypto'), NoTestsNorFIPSFragments) +
FindCFiles(os.path.join('src', 'third_party', 'fiat'), NoTestsNorFIPSFragments))
fips_fragments = FindCFiles(os.path.join('src', 'crypto', 'fipsmodule'), OnlyFIPSFragments)
ssl_source_files = FindCFiles(os.path.join('src', 'ssl'), NoTests)
tool_c_files = FindCFiles(os.path.join('src', 'tool'), NoTests)
@@ -638,8 +639,9 @@ def main(platforms):
NotSSLHeaderFiles))

ssl_internal_h_files = FindHeaderFiles(os.path.join('src', 'ssl'), NoTests)
crypto_internal_h_files = FindHeaderFiles(
os.path.join('src', 'crypto'), NoTests)
crypto_internal_h_files = (
FindHeaderFiles(os.path.join('src', 'crypto'), NoTests) +
FindHeaderFiles(os.path.join('src', 'third_party', 'fiat'), NoTests))

files = {
'crypto': crypto_c_files,


Loading…
Откажи
Сачувај