Files
ESP8266_RTOS_SDK/tools/makefile.sh
Espressif Systems c24c2a557d NEW VERSION: 1.1.0
1. Add pwm support;
2. Add c++ support; Please update to the latest folder "ld".
3. Add rand in libminic;
4. Add new reset reason REASON_EXT_SYS_RST in rst_reason;
5. Update the complied script ‘gen_misc.sh(bat)’, use the new boot and remove the old one;
6. Update folder "tools", and support CRC check of bin files;  Please update to the latest folder "tools".
7. Optimize the process procedure of Wi-Fi event;
8. Fix bugs in printf when its runs out of memory;
9. Fix bugs in malloc when CACHE is disabled;
10.Fix exception and WDT reset bugs when CACHE is disabled;
11.Fix some Wi-Fi connection bugs;
12.Fix some Wi-Fi scan bugs;
13.Tune API "wifi_station_get_connect_status" for more accurate WiFi positioning;
14.Porting the optimization of non-OS SDK to RTOS SDK;
15.Fix other minor bugs.
2015-08-21 18:10:07 +08:00

93 lines
3.1 KiB
Bash

# * Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials provided with the distribution.
# * Neither the name of the axTLS project nor the names of its
# contributors may be used to endorse or promote products derived
# from this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
# TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
# OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
# NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
#
# Generate the certificates and keys for testing.
#
PROJECT_NAME="TLS Project"
# Generate the openssl configuration files.
cat > ca_cert.conf << EOF
[ req ]
distinguished_name = req_distinguished_name
prompt = no
[ req_distinguished_name ]
O = $PROJECT_NAME Dodgy Certificate Authority
EOF
cat > certs.conf << EOF
[ req ]
distinguished_name = req_distinguished_name
prompt = no
[ req_distinguished_name ]
O = $PROJECT_NAME
CN = 127.0.0.1
EOF
cat > device_cert.conf << EOF
[ req ]
distinguished_name = req_distinguished_name
prompt = no
[ req_distinguished_name ]
O = $PROJECT_NAME Device Certificate
EOF
# private key generation
openssl genrsa -out TLS.ca_key.pem 1024
openssl genrsa -out TLS.key_1024.pem 1024
# convert private keys into DER format
openssl rsa -in TLS.key_1024.pem -out TLS.key_1024 -outform DER
# cert requests
openssl req -out TLS.ca_x509.req -key TLS.ca_key.pem -new \
-config ./ca_cert.conf
openssl req -out TLS.x509_1024.req -key TLS.key_1024.pem -new \
-config ./certs.conf
# generate the actual certs.
openssl x509 -req -in TLS.ca_x509.req -out TLS.ca_x509.pem \
-sha1 -days 5000 -signkey TLS.ca_key.pem
openssl x509 -req -in TLS.x509_1024.req -out TLS.x509_1024.pem \
-sha1 -CAcreateserial -days 5000 \
-CA TLS.ca_x509.pem -CAkey TLS.ca_key.pem
# some cleanup
rm TLS*.req
rm *.conf
openssl x509 -in TLS.ca_x509.pem -outform DER -out TLS.ca_x509.cer
openssl x509 -in TLS.x509_1024.pem -outform DER -out TLS.x509_1024.cer
#
# Generate the certificates and keys for encrypt.
#
# set default cert for use in the client
xxd -i TLS.x509_1024.cer | sed -e \
"s/TLS_x509_1024_cer/default_certificate/" > cert.h
# set default key for use in the server
xxd -i TLS.key_1024 | sed -e \
"s/TLS_key_1024/default_private_key/" > private_key.h