2017-04-03 01:18:22 +02:00
|
|
|
TERMUX_PKG_HOMEPAGE=https://curl.haxx.se/docs/caextract.html
|
2015-08-12 05:52:41 +02:00
|
|
|
TERMUX_PKG_DESCRIPTION="Common CA certificates"
|
2018-12-05 21:35:21 +01:00
|
|
|
TERMUX_PKG_VERSION=20181205
|
2018-06-22 01:12:41 +02:00
|
|
|
TERMUX_PKG_SRCURL=https://curl.haxx.se/ca/cacert.pem
|
|
|
|
# If the checksum has changed, it may be time to update the package version:
|
2018-12-05 21:35:21 +01:00
|
|
|
TERMUX_PKG_SHA256=4d89992b90f3e177ab1d895c00e8cded6c9009bec9d56981ff4f0a59e9cc56d6
|
2018-06-22 01:12:41 +02:00
|
|
|
TERMUX_PKG_SKIP_SRC_EXTRACT=yes
|
2015-12-02 02:32:08 +01:00
|
|
|
TERMUX_PKG_PLATFORM_INDEPENDENT=yes
|
2015-08-12 05:52:41 +02:00
|
|
|
|
|
|
|
termux_step_make_install () {
|
2016-08-24 12:34:43 +02:00
|
|
|
local CERTDIR=$TERMUX_PREFIX/etc/tls
|
|
|
|
local CERTFILE=$CERTDIR/cert.pem
|
|
|
|
|
|
|
|
mkdir -p $CERTDIR
|
|
|
|
|
2018-06-22 01:12:41 +02:00
|
|
|
termux_download $TERMUX_PKG_SRCURL \
|
2016-08-24 12:34:43 +02:00
|
|
|
$CERTFILE \
|
2018-06-22 01:12:41 +02:00
|
|
|
$TERMUX_PKG_SHA256
|
2017-04-03 01:14:47 +02:00
|
|
|
touch $CERTFILE
|
|
|
|
|
|
|
|
# Build java keystore which is split out into a ca-certificates-java subpackage:
|
|
|
|
local KEYUTIL_JAR=$TERMUX_PKG_CACHEDIR/keyutil-0.4.0.jar
|
|
|
|
termux_download \
|
|
|
|
https://github.com/use-sparingly/keyutil/releases/download/0.4.0/keyutil-0.4.0.jar \
|
|
|
|
$KEYUTIL_JAR \
|
|
|
|
18f1d2c82839d84949b1ad015343c509e81ef678c24db6112acc6c0761314610
|
|
|
|
|
|
|
|
local JAVA_KEYSTORE_DIR=$PREFIX/lib/jvm/openjdk-9/lib/security
|
|
|
|
mkdir -p $JAVA_KEYSTORE_DIR
|
|
|
|
|
|
|
|
java -jar $KEYUTIL_JAR \
|
|
|
|
--import \
|
|
|
|
--new-keystore $JAVA_KEYSTORE_DIR/jssecacerts \
|
|
|
|
--password changeit \
|
|
|
|
--force-new-overwrite \
|
|
|
|
--import-pem-file $CERTFILE
|
2015-08-12 05:52:41 +02:00
|
|
|
}
|