curl-impersonate: A special compilation of curl that makes it impersonate Chrome & Firefox

Overview

curl-impersonate

Build and test Docker images

A special compilation of curl that makes it impersonate real browsers. It can impersonate the four major browsers: Chrome, Edge, Safari & Firefox. This curl binary is able to perform a TLS handshake that is identical to that of a real browser.

Why?

When you use an HTTP client with a TLS website, it first performs a TLS handshake. The first message of that handshake is called Client Hello. The Client Hello message that curl produces differs drastically from that of a real browser. Compare the following Wireshark capture. Left is a regular curl, right is Firefox. curl-ff-before

Some web services therefore use the TLS handshake to fingerprint which HTTP client is accessing them. Notably, some bot protection platforms use this to identify curl and block it. With the modified curl in this repository, the Client Hello message looks exactly like that of a real browser. This tricks TLS fingerprinters to think that it is a real browser that is accessing them.

How?

The modifications that were needed to make this work:

  • Compiling curl with nss, the TLS library that Firefox uses, instead of OpenSSL. For the Chrome version, compiling with BoringSSL.
  • Modifying the way curl configures various TLS extensions and SSL options.
  • Adding support for new TLS extensions.
  • Running curl with some non-default flags, for example --ciphers, --curves and some -H headers.

The resulting curl looks, from a network perspective, identical to a real browser. Compare: (left is curl-impersonate, right is Firefox):

curl-ff-after

Read the full description in the blog post: part a, part b.

Supported browsers

The following browsers can be impersonated.

Browser Version Build OS Target name Wrapper script
Chrome 99 99.0.4844.51 Windows 10 chrome99 curl_chrome99
Chrome 100 100.0.4896.75 Windows 10 chrome100 curl_chrome100
Chrome 101 101.0.4951.67 Windows 10 chrome101 curl_chrome101
Chrome 99 99.0.4844.73 Android 12 chrome99_android curl_chrome99_android
Edge 99 99.0.1150.30 Windows 10 edge99 curl_edge99
Edge 101 101.0.1210.47 Windows 10 edge101 curl_edge101
Firefox 91 ESR 91.6.0esr Windows 10 ff91esr curl_ff91esr
Firefox 95 95.0.2 Windows 10 ff95 curl_ff95
Firefox 98 98.0 Windows 10 ff98 curl_ff98
Firefox 100 100.0 Windows 10 ff100 curl_ff100
Safari 15.3 16612.4.9.1.8 MacOS Big Sur safari15_3 curl_safari15_3

Basic usage

For each supported browser there is a wrapper script that launches curl-impersonate with all the needed headers and flags. For example:

curl_chrome99 https://www.wikipedia.org

You can add command line flags and they will be passed on to curl. However, some flags change curl's TLS signature which may cause it to be detected.

See Advanced usage for more options.

Installation

There are two versions of curl-impersonate for technical reasons. The chrome version is used to impersonate Chrome, Edge and Safari. The firefox version is used to impersonate Firefox.

Pre-compiled binaries

Pre-compiled binaries for Linux and macOS (Intel) are available at the GitHub releases page. Before you use them you need to install nss (Firefox's TLS library):

  • Ubuntu - sudo apt install libnss3
  • Red Hat/Fedora/CentOS - yum install nss nss-pem
  • macOS - brew install nss

The pre-compiled binaries are statically compiled with libcurl(-impersonate) for ease of use. If you wish to use libcurl-impersonate, please build from source.

Building from source

See INSTALL.md.

Docker images

Docker images based on Alpine Linux with curl-impersonate compiled and ready to use are available on Docker Hub. The images contain the binary and all the wrapper scripts. Use like the following:

# Firefox version
docker pull lwthiker/curl-impersonate:0.4-ff
docker run --rm lwthiker/curl-impersonate:0.4-ff curl_ff95 https://www.wikipedia.org

# Chrome version
docker pull lwthiker/curl-impersonate:0.4-chrome
docker run --rm lwthiker/curl-impersonate:0.4-chrome curl_chrome99 https://www.wikipedia.org

Distro packages

AUR packages are available to Arch users: curl-impersonate-chrome, curl-impersonate-firefox.

Advanced usage

libcurl-impersonate

libcurl-impersonate.so is libcurl compiled with the same changes as the command line curl-impersonate. It has an additional API function:

CURLcode curl_easy_impersonate(struct Curl_easy *data, const char *target);

You can call it with the target names, e.g. chrome98, and it will internally set all the options and headers that are otherwise set by the wrapper scripts. Specifically it sets:

  • CURLOPT_HTTP_VERSION
  • CURLOPT_SSLVERSION, CURLOPT_SSL_CIPHER_LIST, CURLOPT_SSL_EC_CURVES, CURLOPT_SSL_ENABLE_NPN, CURLOPT_SSL_ENABLE_ALPN
  • CURLOPT_HTTPBASEHEADER, CURLOPT_HTTP2_PSEUDO_HEADERS_ORDER (non-standard HTTP options created for this project).
  • CURLOPT_SSL_ENABLE_ALPS, CURLOPT_SSL_SIG_HASH_ALGS, CURLOPT_SSL_CERT_COMPRESSION, CURLOPT_SSL_ENABLE_TICKET (non-standard TLS options created for this project).

Note that if you call curl_easy_setopt() later with one of the above it will override the options set by curl_easy_impersonate().

Using CURL_IMPERSONATE env var

Experimental: If your application uses libcurl already, you can replace the existing library at runtime with LD_PRELOAD (Linux only). You can then set the CURL_IMPERSONATE env var. For example:

LD_PRELOAD=/path/to/libcurl-impersonate.so CURL_IMPERSONATE=chrome98 my_app

The CURL_IMPERSONATE env var has two effects:

  • curl_easy_impersonate() is called automatically for any new curl handle created by curl_easy_init().
  • curl_easy_impersonate() is called automatically after any curl_easy_reset() call.

This means that all the options needed for impersonation will be automatically set for any curl handle.

Note that the above will NOT WORK for curl itself because the curl tool overrides the TLS settings. Use the wrapper scripts instead.

Contents

This repository contains two main folders:

  • chrome - Scripts and patches for building the Chrome version of curl-impersonate.
  • firefox - Scripts and patches for building the Firefox version of curl-impersonate.

The layout is similar for both. For example, the Firefox directory contains:

Other files of interest:

Contributing

If you'd like to help, please check out the open issues. You can open a pull request with your changes.

This repository contains the build process for curl-impersonate. The actual patches to curl are maintained in a separate repository forked from the upstream curl. The changes are maintained in the impersonate-firefox and impersonate-chrome branches.

Comments
  • Distribute binaries, including a drop-in replacement for the shared library

    Distribute binaries, including a drop-in replacement for the shared library

    Thanks for publishing this.

    I see the release process is fairly automated, is it possible to use CI to automatically build binaries of this, and publish them as releases? I don't have experience in Github Actions, but I do in Gitlab CI. Both containers take 3 GB, but the binaries themselves are only ~7 MB.

    Another interesting build artefact would be to "bake in" the settings in curl_ff95 script in the build itself, and create a regular curl shared library. This could replace with the upstream libcurl file to use the new settings, or hacked around with LD_LIBRARY_PATH. It would need to be a different build per browser.

    Now curl is built in static mode. The library itself is in lib/.libs/libcurl.a.

    opened by somini 15
  • Impersonate Safari on Mac

    Impersonate Safari on Mac

    Safari being the second most used desktop browser according to some websites, it can be a good candidate for impersonation as well. I don't have access to a Mac right now.. Is anyone willing to share a Wireshark capture of a TLS session from Safari ? Bonus if it's HTTP/2 and if it can be decrypted as well (you can set up a local nginx with a self signed key for this).

    opened by lwthiker 13
  • Wrong host header using CURL_IMPERSONATE env var

    Wrong host header using CURL_IMPERSONATE env var

    When using libcurl and reusing the same connection, if I set the "Host:" header on the connection, and reuse it to make a request without the host header, the header is still included with the same value

    <?php
    putenv('CURL_IMPERSONATE=chrome98');
    $ch = curl_init();
    curl_setopt($ch, CURLOPT_URL, 'https://headers.cf');
    curl_setopt($ch, CURLINFO_HEADER_OUT, 1);
    curl_setopt( $ch, CURLOPT_ENCODING, "" );
    curl_setopt( $ch, CURLOPT_FOLLOWLOCATION, false );
    curl_setopt( $ch, CURLOPT_ENCODING, "" );
    curl_setopt( $ch, CURLOPT_RETURNTRANSFER, true );
    curl_setopt( $ch, CURLOPT_HTTPHEADER, ['Host: abc.com']);
    curl_setopt( $ch, CURLOPT_AUTOREFERER, true );
    
    curl_exec($ch);
    print_r(curl_getinfo($ch));
    
    //curl_reset($ch);
    curl_setopt($ch, CURLOPT_URL, 'https://headers.cf');
    curl_setopt( $ch, CURLOPT_HTTPHEADER, ['connection: Keep-Alive']); // i didn't set "host:" there
    
    
    
    echo curl_exec($ch);
    print_r(curl_getinfo($ch));
    

    ON the first request, this is what is sent

    GET / HTTP/1.1
    Host: abc.com <--- notice this
    sec-ch-ua: " Not A;Brand";v="99", "Chromium";v="98", "Google Chrome";v="98"
    sec-ch-ua-mobile: ?0
    sec-ch-ua-platform: "Windows"
    Upgrade-Insecure-Requests: 1
    User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/98.0.4758.102 Safari/537.36
    Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9
    Sec-Fetch-Site: none
    Sec-Fetch-Mode: navigate
    Sec-Fetch-User: ?1
    Sec-Fetch-Dest: document
    Accept-Encoding: gzip, deflate, br
    Accept-Language: en-US,en;q=0.9
    

    and this is sent on the second request

    GET / HTTP/1.1
    Host: abc.com <--- this is incorrect
    sec-ch-ua: " Not A;Brand";v="99", "Chromium";v="98", "Google Chrome";v="98"
    sec-ch-ua-mobile: ?0
    sec-ch-ua-platform: "Windows"
    Upgrade-Insecure-Requests: 1
    User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/98.0.4758.102 Safari/537.36
    Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9
    Sec-Fetch-Site: none
    Sec-Fetch-Mode: navigate
    Sec-Fetch-User: ?1
    Sec-Fetch-Dest: document
    Accept-Encoding: gzip, deflate, br
    Accept-Language: en-US,en;q=0.9
    connection: Keep-Alive
    

    if i remove the line putenv('CURL_IMPERSONATE=chrome98');, everything works fine : first request :

    GET / HTTP/1.1
    Host: abc.com <-- notice this
    Accept: */*
    Accept-Encoding: deflate, gzip, br
    

    second request

    GET / HTTP/1.1
    Host: headers.cf <--- this is correct this time
    Accept: */*
    Accept-Encoding: deflate, gzip, br
    connection: Keep-Alive
    
    opened by momala454 11
  • Libcurl certificate compression & more ?

    Libcurl certificate compression & more ?

    I'm using libcurl and php for curl-impersonate, i'm setting the ciphers, the ssl version, disable NPN, but i'm still missing the extensions 27 (compress_certificate) and 17513 (extensionApplicationSettings (boringssl))

    I can't set the parameters "--alps" and "--cert-compression brotli" using libcurl and PHP. The curl php extension doesn't support new parameters names (see https://github.com/php/php-src/blob/master/ext/curl/interface.c#L2306 ) What should I do to enable those 2 extensions ?

    edit: calling putenv('CURL_IMPERSONATE=chrome98'); or CURL_IMPERSONATE=chrome98 php /path/to/script.php beforehand doesn't help, the two tls extensions are still not enabled.

    My guess is that that both "alps" and "cert-compression" have not been yet added to the default parameters on curl-impersonate for libcurl.

    Using CURL_IMPERSONATE=chrome98 curl "http://...." is correctly adding the 2 extensions however

    opened by momala454 10
  • Have the headers changed a bit with Chrome 103?

    Have the headers changed a bit with Chrome 103?

    I checked my laptop's Windows Chrome 103 headers using your socat procedure, compared to the chrome101 curl-impersonate script's results I see extra headers for Connection:, Cache-Control:, and also DNT:. That last one might be due to my personal Chrome settings, not sure. Also the sec-ch-ua: string seems to be a bit different.

    Chrome 103:

    GET / HTTP/1.1\r
    Host: xx.xx.xx.xx:8443\r
    Connection: keep-alive\r
    Cache-Control: max-age=0\r
    sec-ch-ua: ".Not/A)Brand";v="99", "Google Chrome";v="103", "Chromium";v="103"\r
    sec-ch-ua-mobile: ?0\r
    sec-ch-ua-platform: "Windows"\r
    DNT: 1\r
    Upgrade-Insecure-Requests: 1\r
    User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/103.0.0.0 Safari/537.36\r
    Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9\r
    Sec-Fetch-Site: none\r
    Sec-Fetch-Mode: navigate\r
    Sec-Fetch-User: ?1\r
    Sec-Fetch-Dest: document\r
    Accept-Encoding: gzip, deflate, br\r
    Accept-Language: en-US,en;q=0.9\r
    

    curl-impersonate chrome101:

    GET / HTTP/1.1\r
    Host: localhost:8443\r
    sec-ch-ua: " Not A;Brand";v="99", "Chromium";v="101", "Google Chrome";v="101"\r
    sec-ch-ua-mobile: ?0\r
    sec-ch-ua-platform: "Windows"\r
    Upgrade-Insecure-Requests: 1\r
    User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/101.0.4951.67 Safari/537.36\r
    Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9\r
    Sec-Fetch-Site: none\r
    Sec-Fetch-Mode: navigate\r
    Sec-Fetch-User: ?1\r
    Sec-Fetch-Dest: document\r
    Accept-Encoding: gzip, deflate, br\r
    Accept-Language: en-US,en;q=0.9\r
    

    Related question: I tried setting custom headers via node-libcurl in my program, by passing an array to my .get() method's 'HTTPHEADER' option, like below, but in the resulting request socat is showing the Connection: and Cache-Control: headers end up at the end, despite my array passing them first. Is this a curl bug? Anyway to override it to get the right order like Chrome 103?

    let headers = [
        'Connection: keep-alive',
        'Cache-Control: max-age=0',
        'sec-ch-ua: ".Not/A)Brand";v="99", "Google Chrome";v="103", "Chromium";v="103"',
        'sec-ch-ua-mobile: ?0',
        'sec-ch-ua-platform: "Windows"',
        'Upgrade-Insecure-Requests: 1',
        'User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/103.0.0.0 Safari/537.36',
        'Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9',
        'Sec-Fetch-Site: none',
        'Sec-Fetch-Mode: navigate',
        'Sec-Fetch-User: ?1',
        'Sec-Fetch-Dest: document',
        'Accept-Encoding: gzip, deflate, br',
        'Accept-Language: en-US,en;q=0.9'
    ];
    let response = await aCurly.get('https://localhost:8443/', { SSL_VERIFYPEER: false, SSL_VERIFYHOST: false, HTTPHEADER: headers });
    

    socat result:

    GET / HTTP/1.1\r
    Host: localhost:8443\r
    sec-ch-ua: ".Not/A)Brand";v="99", "Google Chrome";v="103", "Chromium";v="103"\r
    sec-ch-ua-mobile: ?0\r
    sec-ch-ua-platform: "Windows"\r
    Upgrade-Insecure-Requests: 1\r
    User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/103.0.0.0 Safari/537.36\r
    Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9\r
    Sec-Fetch-Site: none\r
    Sec-Fetch-Mode: navigate\r
    Sec-Fetch-User: ?1\r
    Sec-Fetch-Dest: document\r
    Accept-Encoding: gzip, deflate, br\r
    Accept-Language: en-US,en;q=0.9\r
    Connection: keep-alive\r
    Cache-Control: max-age=0\r
    

    I tried editing the curl_chrome101 script to add these 2 headers in there, and same behavior: they end up at the bottom of the headers instead of top.

    opened by A-Posthuman 6
  • Failed to load NSS PEM library libnsspem.so. Using OpenSSL PEM certificates will not work.

    Failed to load NSS PEM library libnsspem.so. Using OpenSSL PEM certificates will not work.

    Hi, found this warning while running curl_ff95 (I guess happens on others too):

    * WARNING: failed to load NSS PEM library libnsspem.so. Using OpenSSL PEM certificates will not work
    

    Downloaded and ran the binary without installing anything else. Not sure if it affects anything.

    opened by jlcd 6
  • support build on Amazon Linux(or centos, redhat linux)

    support build on Amazon Linux(or centos, redhat linux)

    thought this should be quite similar to build on Ubuntu, tried for hours but failed

    my efforts include:

    • install build prerequisites by: sudo yum groupinstall "Development Tools"
    • upgrade cmake by: pip3 install cmake --upgrade
    • create symbolic link for ninjia-build by: ln -s /usr/bin/ninja-build /usr/bin/ninja
    • install nss by: sudo yum install libnss3.so libnssutil3.so
    • add search path(/usr/lib/) for lib nss in curl-impersonate.patch#:
      -+          search_paths="/usr/lib/$host /usr/lib/$host/nss"
      ++          search_paths="/usr/lib/ /usr/lib/$host /usr/lib/$host/nss"
      

    still failed when doing make firefox-build, the log suggested failed linking NSS:

    configure: WARNING: Using hard-wired libraries and compilation flags for NSS.
    checking if libnssckbi is in a non-standard location... /usr/lib
    checking for SSL_VersionRangeSet in -lnss_static... no
    configure: error: Failed linking NSS statically
    Makefile:198: recipe for target 'curl-7.81.0/.firefox' failed
    make: *** [curl-7.81.0/.firefox] Error 1
    

    the related log in ./curl-7.81.0/config.log is:

    ...
    configure:26797: checking if libnssckbi is in a non-standard location
    configure:26815: result: /usr/lib
    configure:26843: checking for SSL_VersionRangeSet in -lnss_static
    configure:26865: gcc -o conftest -I/home/ec2-user/apps/curl-impersonate/buil
    d/nss-3.75/dist/Release/../public/nss -I/home/ec2-user/apps/curl-impersonate
    /build/nss-3.75/dist/Release/include/nspr -Werror-implicit-function-declarat
    ion -O2 -Wno-system-headers    -I/home/ec2-user/apps/curl-impersonate/build/
    brotli-1.0.9/out/installed/include -I/home/ec2-user/apps/curl-impersonate/bu
    ild/nss-3.75/dist/Release/include -L/home/ec2-user/apps/curl-impersonate/bui
    ld/nss-3.75/dist/Release/lib -Wl,-rpath,/usr/lib    -L/home/ec2-user/apps/cu
    rl-impersonate/build/brotli-1.0.9/out/installed/lib conftest.c -lnss_static
     -Wl,--start-group -lssl -lnss_static -lpk11wrap_static -lcertdb -lcerthi -l
    nsspki -lnssdev -lsoftokn_static -lfreebl_static -lnssutil -lnssb -lcryptohi
     -l:libplc4.a -l:libplds4.a -l:libnspr4.a -lsqlite -lgcm-aes-x86_c_lib -lhw-
    acc-crypto-avx -lhw-acc-crypto-avx2 -lsha-x86_c_lib -lintel-gcm-wrap_c_lib -
    lintel-gcm-s_lib -Wl,--end-group -pthread -ldl -lbrotlidec-static -lbrotlico
    mmon-static -lz  >&5
    /usr/bin/ld: cannot find -lbrotlidec-static
    /usr/bin/ld: cannot find -lbrotlicommon-static
    collect2: error: ld returned 1 exit status
    configure:26865: $? = 1
    configure: failed program was:
    | /* confdefs.h */
    | #define PACKAGE_NAME "curl"
    | #define PACKAGE_TARNAME "curl"
    | #define PACKAGE_VERSION "-"
    | #define PACKAGE_STRING "curl -"
    | #define PACKAGE_BUGREPORT "a suitable curl mailing list: https://curl.se/mail/"
    ...
    

    any help is appreciated

    opened by DiveInto 6
  • Custom Client Hello values

    Custom Client Hello values

    Is it possible to set custom values of Client Hello packet? Like with usage of curl_easy_impersonate set values of for example CURLOPT_SSL_CIPHER_LIST or CURLOPT_SSL_EC_CURVES

    question 
    opened by Kaspek2480 5
  • On Mac: Can't execute curl-impersonate --cannot execute binary file

    On Mac: Can't execute curl-impersonate --cannot execute binary file

    Thanks for publishing this useful tool.

    Is it possible or any insights to run on Mac OS? currently it always throws error: ./curl_ff95 https://www.ha.com/c/search-results.zx ./curl_ff95: line 10: ./curl-impersonate: cannot execute binary file

    opened by icesmartjuan 5
  • /usr/bin/env: 'ash': No such file or directory when using as docker Multi-stage

    /usr/bin/env: 'ash': No such file or directory when using as docker Multi-stage

    1. Dockerfile :
    FROM php:8.1.1-cli-buster
    
    COPY --from=lwthiker/curl-impersonate:0.5-chrome /usr/local/bin/ /usr/local/bin/
    
    1. docker build -t test .

    2. docker run -it test bash

    3. curl_chrome101

    the following error will ocurrs:

    /usr/bin/env: 'ash': No such file or directory
    

    What is wrong here ?

    opened by foremtehan 4
  • "lwthiker/curl-impersonate:0.5.1-ff" is built using Alpine, not Debian

    It seems that something is potentially off with your generate_dockerfiles.sh script, as the non-Alpine images are, in fact, also Alpine:

    [email protected]:~/rss-bridge/rss-bridge$ sudo docker run -it lwthiker/curl-impersonate:0.5.1-ff sh
    / # apk
    apk-tools 2.12.7, compiled for x86_64.
    
    usage: apk [<OPTIONS>...] COMMAND [<ARGUMENTS>...]
    
    Package installation and removal:
      add        Add packages to WORLD and commit changes
      del        Remove packages from WORLD and commit changes
    
    System maintenance:
      fix        Fix, reinstall or upgrade packages without modifying WORLD
      update     Update repository indexes
      upgrade    Install upgrades available from repositories
      cache      Manage the local package cache
    
    Querying package information:
      info       Give detailed information about packages or repositories
      list       List packages matching a pattern or other criteria
      dot        Render dependencies as graphviz graphs
      policy     Show repository policy for packages
      search     Search for packages by name or description
    
    Repository maintenance:
      index      Create repository index file from packages
      fetch      Download packages from global repositories to a local directory
      manifest   Show checksums of package contents
      verify     Verify package integrity and signature
    
    Miscellaneous:
      audit      Audit system for changes
      stats      Show statistics about repositories and installations
      version    Compare package versions or perform tests on version strings
    
    This apk has coffee making abilities.
    
    opened by wrobelda 4
  • cannot build from source on macbook air

    cannot build from source on macbook air

    Sir, I follow the guide: https://github.com/lwthiker/curl-impersonate/blob/main/INSTALL.md#macos to build source code on MacBook air - m2 chip. All is ok until running gmake, here is the logs:

    > gmake firefox-build
    .... some other logs
    
    curl -L -o nss-3.77.tar.gz https://ftp.mozilla.org/pub/security/nss/releases/NSS_3_77_RTM/src/nss-3.77-with-nspr-4.32.tar.gz
      % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                     Dload  Upload   Total   Spent    Left  Speed
    100 82.2M  100 82.2M    0     0  1059k      0  0:01:19  0:01:19 --:--:-- 1226k
    tar xf nss-3.77.tar.gz
    # Native build, use NSS' build script.
    cd nss-3.77/nss
    ./build.sh -o --disable-tests --static --python=python3
    # Hack for macOS: Remove dynamic libraries to force the linker to use the
    # static ones when linking curl.
    rm -Rf /Users/ntopliu/workspace/GithubProjects/curl-impersonate/build/nss-3.77/dist/Release/lib/*.dylib
    NSPR [1/5] configure ...
    NSPR [2/5] make ...
    NSPR [3/5] NOT building tests
    NSPR [4/5] NOT running tests
    NSPR [5/5] install ...
    Building NSS requires an installation of gyp: https://gyp.gsrc.io/
    gmake: *** [Makefile:211: /Users/ntop/workspace/GithubProjects/curl-impersonate/build/nss-3.77/dist/Release/lib/libnss_static.a] Error 3
    

    I searched the directory nss-3.77/dist/Release/lib/ there is no libnss_static.a :

    libnspr4.a     libnspr4.dylib libplc4.a      libplc4.dylib  libplds4.a     libplds4.dylib pkgconfig
    

    I don't know what happened and how can I fix it.

    I also installed the gyp.

    pip3 install gyp-next
    Defaulting to user installation because normal site-packages is not writeable
    Requirement already satisfied: gyp-next in /Users/ntopliu/Library/Python/3.9/lib/python/site-packages (0.4.0)
    WARNING: You are using pip version 21.2.4; however, version 22.3.1 is available.
    You should consider upgrading via the '/Applications/Xcode.app/Contents/Developer/usr/bin/python3 -m pip install --upgrade pip' command.
    
    
    opened by ntop001 1
  • Why do we need the Accept header?

    Why do we need the Accept header?

    Hi, why do we need the Accept header among the impersonated browser headers?

    Also, sec-fetch-* and a few others change depending on how the request is made, so it doesn't make a lot of sense to keep them every requests. Why are they set for all requests?

    opened by jlcd 1
  • Any SaaS available?

    Any SaaS available?

    Great project. I've had success in impersonating chrome 101. Are there are any API services available that offer this as a SaaS? I have tried a number of web scraping APIs and none of them quite match the capabilities of curl-impersonate.

    opened by wup-one 0
  • Chrome 107 is experimenting with randomizing the order of TLS ClientHello extensions

    Chrome 107 is experimenting with randomizing the order of TLS ClientHello extensions

    See here:

    https://groups.google.com/a/chromium.org/g/blink-dev/c/zdmNs2rTyVI/m/MAiQwQkwCAAJ

    it's not clear to me if this is enabled on most installations yet, but there is a report here of some cases of encountering it:

    https://github.com/refraction-networking/utls/issues/132

    that project implemented a PR to address it:

    https://github.com/refraction-networking/utls/pull/133

    Something to keep an eye on apparently?

    opened by A-Posthuman 1
  • PyCurl Integration?

    PyCurl Integration?

    Hi, please help me make curl-impersonate to work via PyCurl. (I'm aware of #111)

    I'm on debian bullseye, i had compile the library myself.

    I had try:

    export LD_LIBRARY_PATH=/usr/local/lib CURL_IMPERSONATE=ff102 test

    Seems like the real libcurl.so get's loaded

    export LD_PRELOAD=/usr/local/lib/libcurl-impersonate-ff.so

    ImportError: pycurl: libcurl link-time ssl backends (nss) do not include compile-time ssl backend (gnutls)

    cd pycurl export C_INCLUDE_PATH=$C_INCLUDE_PATH:/home/user/Documents/curl-impersonate/build/curl-7.84.0/include python3 setup.py install --curl-config=/usr/local/bin/curl-impersonate-ff-config

    src/pycurl.h:33:10: fatal error: curl/curl.h: No such file or directory 33 | #include <curl/curl.h> | ^~~~~~~~~~~~~ compilation terminated. error: command '/usr/bin/x86_64-linux-gnu-gcc' failed with exit code 1

    Currently no success.

    opened by Flanco1 3
Releases(v0.5.3)
Owner
lwthiker
lwthiker
Pytorch implementation for the paper: Contrastive Learning for Cold-start Recommendation

Contrastive Learning for Cold-start Recommendation This is our Pytorch implementation for the paper: Yinwei Wei, Xiang Wang, Qi Li, Liqiang Nie, Yan L

45 Dec 13, 2022
Surrogate-Assisted Genetic Algorithm for Wrapper Feature Selection

SAGA Surrogate-Assisted Genetic Algorithm for Wrapper Feature Selection Please refer to the Jupyter notebook (Example.ipynb) for an example of using t

9 Dec 28, 2022
This repository includes the official project for the paper: TransMix: Attend to Mix for Vision Transformers.

TransMix: Attend to Mix for Vision Transformers This repository includes the official project for the paper: TransMix: Attend to Mix for Vision Transf

Jie-Neng Chen 130 Jan 01, 2023
End-to-End Referring Video Object Segmentation with Multimodal Transformers

End-to-End Referring Video Object Segmentation with Multimodal Transformers This repo contains the official implementation of the paper: End-to-End Re

608 Dec 30, 2022
OBG-FCN - implementation of 'Object Boundary Guided Semantic Segmentation'

OBG-FCN This repository is to reproduce the implementation of 'Object Boundary Guided Semantic Segmentation' in http://arxiv.org/abs/1603.09742 Object

Jiu XU 3 Mar 11, 2019
This repository contains the implementation of the paper Contrastive Instance Association for 4D Panoptic Segmentation using Sequences of 3D LiDAR Scans

Contrastive Instance Association for 4D Panoptic Segmentation using Sequences of 3D LiDAR Scans This repository contains the implementation of the pap

Photogrammetry & Robotics Bonn 40 Dec 01, 2022
Voila - Voilà turns Jupyter notebooks into standalone web applications

Rendering of live Jupyter notebooks with interactive widgets. Introduction Voilà turns Jupyter notebooks into standalone web applications. Unlike the

Voilà Dashboards 4.5k Jan 03, 2023
Conjugated Discrete Distributions for Distributional Reinforcement Learning (C2D)

Conjugated Discrete Distributions for Distributional Reinforcement Learning (C2D) Code & Data Appendix for Conjugated Discrete Distributions for Distr

1 Jan 11, 2022
A program that uses computer vision to detect hand gestures, used for controlling movie players.

HandGestureDetection This program uses a Haar Cascade algorithm to detect the presence of your hand, and then passes it on to a self-created and self-

2 Nov 22, 2022
Style transfer, deep learning, feature transform

FastPhotoStyle License Copyright (C) 2018 NVIDIA Corporation. All rights reserved. Licensed under the CC BY-NC-SA 4.0 license (https://creativecommons

NVIDIA Corporation 10.9k Jan 02, 2023
Mip-NeRF: A Multiscale Representation for Anti-Aliasing Neural Radiance Fields.

This repository contains the code release for Mip-NeRF: A Multiscale Representation for Anti-Aliasing Neural Radiance Fields. This implementation is written in JAX, and is a fork of Google's JaxNeRF

Google 625 Dec 30, 2022
PyTorch implementations of Top-N recommendation, collaborative filtering recommenders.

PyTorch implementations of Top-N recommendation, collaborative filtering recommenders.

Yoonki Jeong 129 Dec 22, 2022
PyTorch implementation of the ACL, 2021 paper Parameter-efficient Multi-task Fine-tuning for Transformers via Shared Hypernetworks.

Parameter-efficient Multi-task Fine-tuning for Transformers via Shared Hypernetworks This repo contains the PyTorch implementation of the ACL, 2021 pa

Rabeeh Karimi Mahabadi 98 Dec 28, 2022
A Nim frontend for pytorch, aiming to be mostly auto-generated and internally using ATen.

Master Release Pytorch - Py + Nim A Nim frontend for pytorch, aiming to be mostly auto-generated and internally using ATen. Because Nim compiles to C+

Giovanni Petrantoni 425 Dec 22, 2022
EASY - Ensemble Augmented-Shot Y-shaped Learning: State-Of-The-Art Few-Shot Classification with Simple Ingredients.

EASY - Ensemble Augmented-Shot Y-shaped Learning: State-Of-The-Art Few-Shot Classification with Simple Ingredients. This repository is the official im

Yassir BENDOU 57 Dec 26, 2022
​ This is the Pytorch implementation of Progressive Attentional Manifold Alignment.

PAMA This is the Pytorch implementation of Progressive Attentional Manifold Alignment. Requirements python 3.6 pytorch 1.2.0+ PIL, numpy, matplotlib C

98 Nov 15, 2022
Styled Handwritten Text Generation with Transformers (ICCV 21)

⚡ Handwriting Transformers [PDF] Ankan Kumar Bhunia, Salman Khan, Hisham Cholakkal, Rao Muhammad Anwer, Fahad Shahbaz Khan & Mubarak Shah Abstract: We

Ankan Kumar Bhunia 85 Dec 22, 2022
MicroNet: Improving Image Recognition with Extremely Low FLOPs (ICCV 2021)

MicroNet: Improving Image Recognition with Extremely Low FLOPs (ICCV 2021) A pytorch implementation of MicroNet. If you use this code in your research

Yunsheng Li 293 Dec 28, 2022
Code for reproducing our analysis in the paper titled: Image Cropping on Twitter: Fairness Metrics, their Limitations, and the Importance of Representation, Design, and Agency

Image Crop Analysis This is a repo for the code used for reproducing our Image Crop Analysis paper as shared on our blog post. If you plan to use this

Twitter Research 239 Jan 02, 2023
PyTorch implementation for 3D human pose estimation

Towards 3D Human Pose Estimation in the Wild: a Weakly-supervised Approach This repository is the PyTorch implementation for the network presented in:

Xingyi Zhou 579 Dec 22, 2022