Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
torvalds
GitHub Repository: torvalds/linux
Path: blob/master/lib/crypto/curve25519-generic.c
26282 views
1
// SPDX-License-Identifier: GPL-2.0 OR MIT
2
/*
3
* Copyright (C) 2015-2019 Jason A. Donenfeld <[email protected]>. All Rights Reserved.
4
*
5
* This is an implementation of the Curve25519 ECDH algorithm, using either
6
* a 32-bit implementation or a 64-bit implementation with 128-bit integers,
7
* depending on what is supported by the target compiler.
8
*
9
* Information: https://cr.yp.to/ecdh.html
10
*/
11
12
#include <crypto/curve25519.h>
13
#include <linux/export.h>
14
#include <linux/module.h>
15
16
const u8 curve25519_null_point[CURVE25519_KEY_SIZE] __aligned(32) = { 0 };
17
const u8 curve25519_base_point[CURVE25519_KEY_SIZE] __aligned(32) = { 9 };
18
19
EXPORT_SYMBOL(curve25519_null_point);
20
EXPORT_SYMBOL(curve25519_base_point);
21
EXPORT_SYMBOL(curve25519_generic);
22
23
MODULE_LICENSE("GPL v2");
24
MODULE_DESCRIPTION("Curve25519 scalar multiplication");
25
MODULE_AUTHOR("Jason A. Donenfeld <[email protected]>");
26
27