nuttx-update/include/crypto/cast.h
Alin Jerpelea 085c7e7b81 include/crypto/cast: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

define NuttX local NuttX-PublicDomain identifier

 “Public Domain” is a concept distinct from copyright licensing;
it generally means that the work no longer has any copyright protection
or ownership, and therefore requires no license permission in order to
use, copy, modify, distribute, perform, display, etc.
In the United States – and many jurisdictions – copyright protections
attach automatically to creative works upon creation if they satisfy
certain minimum criteria.
“Public Domain” would thus represent a significant change to the legal
status of the work.
The rules around “Public Domain” often vary or are unspecified
jurisdiction to jurisdiction. Adding to the confusion, some
jurisdictions may not even recognize the concept of “Public Domain”
(or similar). As such, a license may nevertheless be required or implied
in these cases. Even in the U.S., there is no clear,
officially-sanctioned procedure for affirmatively placing
copyright-eligible works into the “Public Domain” aside from natural
statutory expiration of copyright. The bottom-line is, there are few if
any objective, brightline rules for proactively placing
copyright-eligible works into the Public Domain that we can broadly
rely on.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-12-16 14:18:35 +08:00

28 lines
895 B
C

/****************************************************************************
* include/crypto/cast.h
*
* SPDX-License-Identifier: NuttX-PublicDomain
*
* Written by Steve Reid <sreid@sea-to-sky.net>
* 100% Public Domain - no warranty
* Released 1997.10.11
****************************************************************************/
#ifndef __INCLUDE_CRYPTO_CAST_H
#define __INCLUDE_CRYPTO_CAST_H
typedef struct
{
uint32_t xkey[32]; /* Key, after expansion */
int rounds; /* Number of rounds to use, 12 or 16 */
} cast_key;
void cast_setkey(FAR cast_key *key, FAR uint8_t *rawkey, int keybytes);
void cast_encrypt(FAR cast_key *key,
FAR uint8_t *inblock,
FAR uint8_t *outblock);
void cast_decrypt(FAR cast_key *key,
FAR uint8_t *inblock,
FAR uint8_t *outblock);
#endif /* __INCLUDE_CRYPTO_CAST_H */