1 /* 2 // Copyright (C) 2022 Beken Corporation 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 #define USE_SEC_TEST_CMD 0 16 17 extern int hal_sha256_self_test(int); 18 19 extern void *aes_encrypt_init(const u8 *key, size_t len); 20 extern void aes_encrypt(void *ctx, const u8 *plain, u8 *crypt); 21 extern void aes_encrypt_deinit(void *ctx); 22 extern void *aes_decrypt_init(const u8 *key, size_t len); 23 extern void aes_decrypt(void *ctx, const u8 *crypt, u8 *plain); 24 extern void aes_decrypt_deinit(void *ctx); 25