lexiforest/curl_cffi

Add support for Firefox

JodanJodan opened this issue · 13 comments

The latest curl_impersonate supports 6 Firefox versions, could these be added?

Hi, this would also interest me. is there any way we can modify code to do this ourself?

Take a look at the makefile, it's fairly simple. Basically, it's just downloading the compiled .so files and then using cibuildwheel to build binary wheels.

gunir commented

+1

I also think Firefox's TLS Fingerprint should also be an option, it's useful to impersonate Firefox in case we use curl_cffi as proxy to surf the web with Firefox too, can't just impersonate Chrome because it's easy to detect.

Hello, I'm trying to add firefox. How can I get browser infos like ciphers, and curves?

bjia56 commented

Would it be easier to have a sibling package, e.g. curl_cffi_ff, which provides the Firefox version of curl-impersonate? I would think that avoids the duplicate symbols issue

gunir commented

I was thinking that is it possible to use boringssl to emulate NSS? Then it

I think it's possible, as BoringSSL is very very close to NSS, unlike OpenSSL it's impossible because OpenSSL doesn't allow to hide some ciphers and a lot of extensions.

bjia56 commented

It turns out that ffi is happy build multiple .so wrappers within the curl_cffi package, so it's possible to build curl_cffi._wrapper_chrome and curl_cffi._wrapper_ff at the same time.
image
Much of the library will need to be tweaked slightly to generalize the assumption that there's only one wrapper. Additionally, Firefox does not support the certificate store:
image

Cool, do you mind submitting a PR?

bjia56 commented

Yeah I'll probably need a bit of time to clean things up but I'll open a PR soon