mirror of
https://github.com/ading2210/libcurl.js.git
synced 2025-05-13 22:40:01 -04:00
expose wisp-client-js apis
This commit is contained in:
parent
4d64b27a82
commit
88f2249e4e
5 changed files with 14 additions and 5 deletions
|
@ -1,5 +1,8 @@
|
||||||
# Libcurl.js Changelog:
|
# Libcurl.js Changelog:
|
||||||
|
|
||||||
|
## v0.6.12 (7/28/24):
|
||||||
|
- The APIs from [wisp-client-js](https://github.com/MercuryWorkshop/wisp-client-js) are now exposed at `libcurl.wisp`
|
||||||
|
|
||||||
## v0.6.11 (7/18/24):
|
## v0.6.11 (7/18/24):
|
||||||
- Add support for SOCKS5, SOCKS4, and HTTP proxies
|
- Add support for SOCKS5, SOCKS4, and HTTP proxies
|
||||||
|
|
||||||
|
|
|
@ -21,6 +21,7 @@ This is an experimental port of [libcurl](https://curl.se/libcurl/) to WebAssemb
|
||||||
* [Getting Error Strings](#getting-error-strings)
|
* [Getting Error Strings](#getting-error-strings)
|
||||||
* [Getting Version Info](#getting-version-info)
|
* [Getting Version Info](#getting-version-info)
|
||||||
* [Getting the CA Certificates Bundle](#getting-the-ca-certificates-bundle)
|
* [Getting the CA Certificates Bundle](#getting-the-ca-certificates-bundle)
|
||||||
|
* [Using the Wisp Client](#using-the-wisp-client)
|
||||||
- [Proxy Server](#proxy-server)
|
- [Proxy Server](#proxy-server)
|
||||||
- [Project Structure](#project-structure)
|
- [Project Structure](#project-structure)
|
||||||
- [Copyright](#copyright)
|
- [Copyright](#copyright)
|
||||||
|
@ -266,6 +267,9 @@ You can get version information from the `libcurl.version` object. This object w
|
||||||
### Getting the CA Certificates Bundle:
|
### Getting the CA Certificates Bundle:
|
||||||
You can get the CA cert bundle that libcurl uses by calling `libcurl.get_cacert`. The function will return a string with the certificates in PEM format. The cert bundle comes from the [official curl website](https://curl.se/docs/caextract.html), which is extracted from the Mozilla Firefox source code.
|
You can get the CA cert bundle that libcurl uses by calling `libcurl.get_cacert`. The function will return a string with the certificates in PEM format. The cert bundle comes from the [official curl website](https://curl.se/docs/caextract.html), which is extracted from the Mozilla Firefox source code.
|
||||||
|
|
||||||
|
### Using the Wisp Client
|
||||||
|
The `libcurl.wisp` object exposes all of the APIs from [wisp-client-js](https://github.com/MercuryWorkshop/wisp-client-js). This API is not guarenteed to be reliable.
|
||||||
|
|
||||||
## Proxy Server:
|
## Proxy Server:
|
||||||
The proxy server consists of a standard [Wisp](https://github.com/MercuryWorkshop/wisp-protocol) server, allowing multiple TCP connections to share the same websocket.
|
The proxy server consists of a standard [Wisp](https://github.com/MercuryWorkshop/wisp-protocol) server, allowing multiple TCP connections to share the same websocket.
|
||||||
|
|
||||||
|
|
|
@ -102,8 +102,12 @@ api = {
|
||||||
get_cacert: get_cacert,
|
get_cacert: get_cacert,
|
||||||
get_error_string: get_error_str,
|
get_error_string: get_error_str,
|
||||||
|
|
||||||
|
wisp: {
|
||||||
wisp_connections: _wisp_connections,
|
wisp_connections: _wisp_connections,
|
||||||
WispConnection: WispConnection,
|
WispConnection: WispConnection,
|
||||||
|
WispWebSocket: WispWebSocket
|
||||||
|
},
|
||||||
|
|
||||||
transport: "wisp",
|
transport: "wisp",
|
||||||
|
|
||||||
WebSocket: FakeWebSocket,
|
WebSocket: FakeWebSocket,
|
||||||
|
|
|
@ -1,5 +1,3 @@
|
||||||
//currently broken
|
|
||||||
|
|
||||||
class TLSSocket extends CurlSession {
|
class TLSSocket extends CurlSession {
|
||||||
constructor(hostname, port, options={}) {
|
constructor(hostname, port, options={}) {
|
||||||
super();
|
super();
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "libcurl.js",
|
"name": "libcurl.js",
|
||||||
"version": "0.6.11",
|
"version": "0.6.12",
|
||||||
"description": "An experimental port of libcurl to WebAssembly for use in the browser.",
|
"description": "An experimental port of libcurl to WebAssembly for use in the browser.",
|
||||||
"main": "libcurl.mjs",
|
"main": "libcurl.mjs",
|
||||||
"exports": {
|
"exports": {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue