Files
luban-lite/target/d12x/demo68-nor/pack/keys/gen_spienc_key.sh
刘可亮 0ef85b55da v1.1.0
2024-09-30 17:06:01 +08:00

17 lines
398 B
Bash
Executable File

#!/bin/bash
#
# Copyright (c) 2022-2024, ArtInChip Technology Co., Ltd
#
# SPDX-License-Identifier: Apache-2.0
#
# Authors: Xiong Hao <hao.xiong@artinchip.com>
#
if [ ! -f "set_aes_key.txt" ];then
openssl rand -hex 16 > set_aes_key.txt
fi
xxd -p -r set_aes_key.txt > spi_aes.key
xxd -c 16 -i spi_aes.key > spi_aes_key.h
cp spi_aes_key.h ../../../../../bsp/examples_bare/test-efuse/spi_aes_key.h