curl-impersonate: A special build of curl that can impersonate Chrome & Firefox
Add missing Dockerfile dependencies
lwthiker918d553ae8f4
diff --git a/Dockerfile b/Dockerfileindex 0be8afb..2f7c823 100644--- a/Dockerfile+++ b/Dockerfile@@ -42,11 +42,6 @@ RUN cd ${NGHTTP2_VERSION} && \./configure && \make && make install-# curl tries to load the CA certificates for libnss.-# It loads them from /usr/lib/x86_64-linux-gnu/nss/libnssckbi.so,-# which is supplied by libnss3 on Debian/Ubuntu-RUN apt-get install -y libnss3-# Download curl and compile it with nssARG CURL_VERSION=curl-7.81.0RUN curl -o ${CURL_VERSION}.tar.xz https://curl.se/download/${CURL_VERSION}.tar.xz@@ -65,10 +60,18 @@ RUN cd ${CURL_VERSION} && \./configure --with-nss=/build/${NSS_VERSION}/dist/Release --enable-static --disable-shared CFLAGS="-I/build/${NSS_VERSION}/dist/public/nss -I/build/${NSS_VERSION}/dist/Release/include/nspr" --with-nghttp2=/usr/local && \make+# curl tries to load the CA certificates for libnss.+# It loads them from /usr/lib/x86_64-linux-gnu/nss/libnssckbi.so,+# which is supplied by libnss3 on Debian/Ubuntu+RUN apt-get install -y libnss3++# 'xxd' is needed for the wrapper curl_ff95 script+RUN apt-get install -y xxd+RUN mkdir out && \- cp ${CURL_VERSION}/src/curl out/curl-nss+ cp ${CURL_VERSION}/src/curl out/curl-impersonate# Wrapper script-COPY curl_ff97 out/+COPY curl_ff95 out/RUN chmod +x out/*diff --git a/curl_ff95 b/curl_ff95index ce225ba..f145bf7 100755--- a/curl_ff95+++ b/curl_ff95@@ -9,7 +9,7 @@ exec 5<>pipe 3>pipe 4<pipe 5>&-# The list of ciphers can be obtained by looking at the Client Hello message in# Wireshark, then converting it using the cipherlist array at# https://github.com/curl/curl/blob/master/lib/vtls/nss.c-"$dir/curl-nss" \+"$dir/curl-impersonate" \--ciphers aes_128_gcm_sha_256,chacha20_poly1305_sha_256,aes_256_gcm_sha_384,ecdhe_ecdsa_aes_128_gcm_sha_256,ecdhe_rsa_aes_128_gcm_sha_256,ecdhe_ecdsa_chacha20_poly1305_sha_256,ecdhe_rsa_chacha20_poly1305_sha_256,ecdhe_ecdsa_aes_256_gcm_sha_384,ecdhe_rsa_aes_256_gcm_sha_384,ecdhe_ecdsa_aes_256_sha,ecdhe_ecdsa_aes_128_sha,ecdhe_rsa_aes_128_sha,ecdhe_rsa_aes_256_sha,rsa_aes_128_gcm_sha_256,rsa_aes_256_gcm_sha_384,rsa_aes_128_sha,rsa_aes_256_sha \-H 'User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:95.0) Gecko/20100101 Firefox/95.0' \-H 'Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,*/*;q=0.8' \