@ossiana/node-libcurl 1.0.7-alpha-2 → 1.0.7-alpha-3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) node-libcurl Ossianaa Project Contributors. All rights reserved.
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/binding.gyp CHANGED
@@ -27,7 +27,7 @@
27
27
  'msvs_settings': {
28
28
  'VCCLCompilerTool': {
29
29
  'DisableSpecificWarnings':['4530','4819'],
30
- 'RuntimeLibrary': '2',
30
+ 'RuntimeLibrary': '1',
31
31
  }
32
32
  }
33
33
  },
@@ -64,7 +64,7 @@
64
64
 
65
65
  "configurations": {
66
66
  'Release': {
67
- 'cflags': [ '-std=c++11', '-fexceptions', '-frtti', '-Wno-deprecated', '-Wno-unused-variable', '-Wno-unused-but-set-variable', '-Wno-maybe-uninitialized', '-Wno-sign-compare', '-Wno-reorder', '-Wno-extra', '-Wno-switch' ,'-fPIC'],
67
+ 'cflags': [ '-std=c++11', '-fexceptions', '-frtti', '-Wno-deprecated', '-Wno-unused-variable', '-Wno-unused-but-set-variable', '-Wno-maybe-uninitialized', '-Wno-sign-compare', '-Wno-reorder', '-Wno-extra', '-Wno-switch' ,'-fPIC'],
68
68
  'cflags_cc': [ '-std=c++11', '-fexceptions', '-frtti', '-Wno-deprecated', '-Wno-unused-variable', '-Wno-unused-but-set-variable', '-Wno-maybe-uninitialized', '-Wno-sign-compare', '-Wno-reorder', '-Wno-extra', '-Wno-switch','-fPIC']
69
69
  },
70
70
  'Debug': {
@@ -72,25 +72,11 @@
72
72
  },
73
73
  },
74
74
  'libraries': [
75
- # "<(module_root_dir)/src/libcurl/lib/Debug/libcurl-d_imp.lib"
76
75
  "<(module_root_dir)/src/libcurl/lib/Release/linux/libcurl.a",
77
76
  "<(module_root_dir)/src/libcurl/lib/Release/linux/libssl.a",
78
77
  "<(module_root_dir)/src/libcurl/lib/Release/linux/libcrypto.a"
79
78
  ],
80
- "copies": [
81
- # {
82
- # "destination": "<(module_root_dir)/build/Debug/",
83
- # "files": [
84
- # "<(module_root_dir)/src/libcurl/lib/Debug/libcurl-d.dll"
85
- # ]
86
- # },
87
- # {
88
- # "destination": "<(module_root_dir)/build/Release/",
89
- # "files": [
90
- # "<(module_root_dir)/src/libcurl/lib/Release/libcurl.so"
91
- # ]
92
- # }
93
- ]
79
+
94
80
  }],
95
81
  ['OS=="mac"', {
96
82
  "configurations": {
package/package.json CHANGED
@@ -1,29 +1,29 @@
1
- {
2
- "name": "@ossiana/node-libcurl",
3
- "version": "1.0.7-alpha-2",
4
- "dependencies": {
5
- "bindings": "^1.5.0",
6
- "node-addon-api": "^5.0.0",
7
- "node-gyp": "^9.3.1"
8
- },
9
- "scripts": {
10
- "test": "node ./test/requests_tls.js",
11
- "build:dev": "node-gyp configure --node_use_openssl=false --openssl_quic=false --node_shared_openssl=false && node-gyp -j 16 build --release",
12
- "unittest": "mocha"
13
- },
14
- "devDependencies": {
15
- "@types/node": "^18.11.18",
16
- "body-parser": "^1.20.1",
17
- "chai": "^4.3.7",
18
- "express": "^4.18.2",
19
- "mocha": "^10.2.0",
20
- "typescript": "^4.9.4"
21
- },
22
- "author": {
23
- "name": "Ossian"
24
- },
25
- "repository": {
26
- "type": "git",
27
- "url": "git@github.com/Ossianaa/node-libcurl.git"
28
- }
29
- }
1
+ {
2
+ "name": "@ossiana/node-libcurl",
3
+ "version": "1.0.7-alpha-3",
4
+ "dependencies": {
5
+ "bindings": "^1.5.0",
6
+ "node-addon-api": "^5.0.0",
7
+ "node-gyp": "^9.3.1"
8
+ },
9
+ "scripts": {
10
+ "test": "node ./test/requests_tls.js",
11
+ "build:dev": "node-gyp configure --node_use_openssl=false --openssl_quic=false --node_shared_openssl=false && node-gyp -j 16 build --release",
12
+ "unittest": "mocha"
13
+ },
14
+ "devDependencies": {
15
+ "@types/node": "^18.11.18",
16
+ "body-parser": "^1.20.1",
17
+ "chai": "^4.3.7",
18
+ "express": "^4.18.2",
19
+ "mocha": "^10.2.0",
20
+ "typescript": "^4.9.4"
21
+ },
22
+ "author": {
23
+ "name": "Ossian"
24
+ },
25
+ "repository": {
26
+ "type": "git",
27
+ "url": "git@github.com/Ossianaa/node-libcurl.git"
28
+ }
29
+ }
package/readme.md CHANGED
@@ -2,15 +2,27 @@
2
2
 
3
3
  ## different with Nodejs fetch api
4
4
  * JA3 FingerPrint is the same as chrome 108,it modified the BoringSSL extension, set the custom cipher suite with Libcurl
5
- * Now only support on Windows, linux and MacOS will be supported in the future
5
+ ------------
6
+
7
+ ## Build Status
6
8
 
9
+ | Platform | Support |
10
+ |:-----------------------------:|:---------:|
11
+ | __Windows (x64)__ |__Yes__|
12
+ | __Windows (x86)__ |__No__|
13
+ | __Windows (ARM)__ |__No__|
14
+ | __Ubuntu (x86_64)__ |__Yes__|
15
+ | __MacOS (x86_64)__ |__Yes__|
16
+ | __MacOS (arm64)__ |__No__|
7
17
  ------------
18
+
8
19
  ## how to build
9
- > npm i @ossiana/node-libcurl -g
20
+ > npm i -g @ossiana/node-libcurl
10
21
 
11
22
  #### Some Problems on Windows
12
- You should install Python 2.7 and the Visual Studio compiler;
23
+ You should install Python 3.x and the Visual Studio compiler;
13
24
  > npm i -g --production windows-build-tools
25
+ ------------
14
26
 
15
27
 
16
28
 
@@ -57,7 +69,7 @@ curl.open('POST', 'https://xxx.io/api/graphql/', true);
57
69
  curl.setRequestHeaders(`Host: xxx.io
58
70
  User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/108.0.0.0 Safari/537.36
59
71
  Content-Type: application/octet-stream
60
- Referer: https://opensea.io/
72
+ Referer: https://xxx.io/
61
73
  Accept-Encoding: gzip, deflate, br
62
74
  Accept-Language: zh-CN,zh;q=0.9
63
75
  `);