jscope 0.4.2__tar.gz → 0.4.3__tar.gz
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.
- {jscope-0.4.2 → jscope-0.4.3}/PKG-INFO +8 -9
- {jscope-0.4.2 → jscope-0.4.3}/README.md +4 -5
- jscope-0.4.3/jscope/__init__.py +1 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/cli.py +14 -5
- jscope-0.4.3/jscope/terminal.py +96 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope.egg-info/PKG-INFO +8 -9
- {jscope-0.4.2 → jscope-0.4.3}/jscope.egg-info/SOURCES.txt +1 -0
- {jscope-0.4.2 → jscope-0.4.3}/pyproject.toml +3 -3
- jscope-0.4.2/jscope/__init__.py +0 -1
- {jscope-0.4.2 → jscope-0.4.3}/LICENSE +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/__main__.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/ai/__init__.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/ai/explain.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/ai/providers.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/__init__.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/auth_analyzer.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/authorization_analyzer.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/base.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/common.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/dataflow_analyzer.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/endpoint_analyzer.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/framework_detector.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/graphql_analyzer.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/graphql_schema_analyzer.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/html_analyzer.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/manager.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/openapi_analyzer.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/router_analyzer.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/secret_analyzer.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/service_worker_analyzer.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/source_map_analyzer.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/storage_analyzer.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/analyzers/wasm_analyzer.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/assessment_engine.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/assessment_reporting.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/benchmark/__init__.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/benchmark/fixtures.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/benchmark/runner.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/config.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/core/__init__.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/core/artifacts.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/core/cache.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/core/classification.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/core/evidence.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/core/graph.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/core/redact.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/crawler/__init__.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/crawler/crawler.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/dataflow/__init__.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/dataflow/engine.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/dataflow/modules.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/dataflow/rules.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/downloader/__init__.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/downloader/downloader.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/parsing/__init__.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/parsing/ast_engine.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/parsing/graphql_schema.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/parsing/html.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/parsing/queries.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/parsing/wasm.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/passive_discovery.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/pipeline.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/plugin/__init__.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/plugin/_worker.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/plugin/loader.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/plugin/sandbox.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/reporting/__init__.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/reporting/formats.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/reporting/human.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/reporting/json_report.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/reporting/priority.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/runtime/__init__.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/runtime/observe.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/runtime/prober.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/runtime/scope.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/security_transport.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/verify/__init__.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/verify/engine.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/workspace/__init__.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/workspace/assessment.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/workspace/common.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/workspace/diff.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope/workspace/store.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope.egg-info/dependency_links.txt +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope.egg-info/entry_points.txt +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope.egg-info/requires.txt +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/jscope.egg-info/top_level.txt +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/setup.cfg +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_analyzers.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_assessment_scope.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_ast_engine.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_benchmark.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_cli_entry.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_dataflow.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_engine_hardening_and_plugins.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_evidence_engine.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_graph_correlation.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_incremental.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_live_local.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_observe.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_path_independence.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_phase2_analyzers.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_phase2_scope_transport.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_phase3.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_phase4.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_phases345_hardening.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_plugin_isolation.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_router.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_scope.py +0 -0
- {jscope-0.4.2 → jscope-0.4.3}/tests/test_verify.py +0 -0
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: jscope
|
|
3
|
-
Version: 0.4.
|
|
3
|
+
Version: 0.4.3
|
|
4
4
|
Summary: Evidence-based JavaScript intelligence for bug bounty hunters and web app pentesters
|
|
5
5
|
Author: Muhammed Ali
|
|
6
6
|
License-Expression: MIT
|
|
7
|
-
Project-URL: Homepage, https://github.com/
|
|
8
|
-
Project-URL: Issues, https://github.com/
|
|
9
|
-
Project-URL: Changelog, https://github.com/
|
|
7
|
+
Project-URL: Homepage, https://github.com/Lime27-Star/JScope
|
|
8
|
+
Project-URL: Issues, https://github.com/Lime27-Star/JScope/issues
|
|
9
|
+
Project-URL: Changelog, https://github.com/Lime27-Star/JScope/blob/main/CHANGELOG.md
|
|
10
10
|
Keywords: security,bug-bounty,pentest,javascript,static-analysis,appsec,recon
|
|
11
11
|
Classifier: Development Status :: 4 - Beta
|
|
12
12
|
Classifier: Environment :: Console
|
|
@@ -37,7 +37,6 @@ Requires-Dist: build; extra == "dev"
|
|
|
37
37
|
Requires-Dist: twine; extra == "dev"
|
|
38
38
|
Dynamic: license-file
|
|
39
39
|
|
|
40
|
-
|
|
41
40
|
<p align="center">
|
|
42
41
|
<picture>
|
|
43
42
|
<source media="(prefers-color-scheme: dark)" srcset="assets/logo-dark.svg">
|
|
@@ -51,7 +50,7 @@ Dynamic: license-file
|
|
|
51
50
|
</p>
|
|
52
51
|
|
|
53
52
|
<p align="center">
|
|
54
|
-
<a href="https://github.com/
|
|
53
|
+
<a href="https://github.com/Lime27-Star/JScope/actions/workflows/ci.yml"><img alt="CI" src="https://github.com/Lime27-Star/JScope/actions/workflows/ci.yml/badge.svg"></a>
|
|
55
54
|
<img alt="Python 3.10+" src="https://img.shields.io/badge/python-3.10%2B-blue">
|
|
56
55
|
<img alt="License: MIT" src="https://img.shields.io/badge/license-MIT-green">
|
|
57
56
|
</p>
|
|
@@ -95,11 +94,11 @@ Try it yourself on the bundled fixture (`tests/sample_react`).
|
|
|
95
94
|
## Install
|
|
96
95
|
|
|
97
96
|
```bash
|
|
98
|
-
pip install git+https://github.com/
|
|
97
|
+
pip install git+https://github.com/Lime27-Star/JScope.git
|
|
99
98
|
jscope doctor # checks your install
|
|
100
99
|
```
|
|
101
100
|
|
|
102
|
-
Python 3.10+. For YAML OpenAPI specs: `pip install "jscope[yaml] @ git+https://github.com/
|
|
101
|
+
Python 3.10+. For YAML OpenAPI specs: `pip install "jscope[yaml] @ git+https://github.com/Lime27-Star/JScope.git"`.
|
|
103
102
|
|
|
104
103
|
## Quick start
|
|
105
104
|
|
|
@@ -166,7 +165,7 @@ JScope is a **beta development tool, not a production scanner.** Be aware of the
|
|
|
166
165
|
## Development
|
|
167
166
|
|
|
168
167
|
```bash
|
|
169
|
-
git clone https://github.com/
|
|
168
|
+
git clone https://github.com/Lime27-Star/JScope && cd JScope
|
|
170
169
|
python -m venv .venv && . .venv/bin/activate
|
|
171
170
|
pip install -e ".[dev]"
|
|
172
171
|
pytest
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
|
|
2
1
|
<p align="center">
|
|
3
2
|
<picture>
|
|
4
3
|
<source media="(prefers-color-scheme: dark)" srcset="assets/logo-dark.svg">
|
|
@@ -12,7 +11,7 @@
|
|
|
12
11
|
</p>
|
|
13
12
|
|
|
14
13
|
<p align="center">
|
|
15
|
-
<a href="https://github.com/
|
|
14
|
+
<a href="https://github.com/Lime27-Star/JScope/actions/workflows/ci.yml"><img alt="CI" src="https://github.com/Lime27-Star/JScope/actions/workflows/ci.yml/badge.svg"></a>
|
|
16
15
|
<img alt="Python 3.10+" src="https://img.shields.io/badge/python-3.10%2B-blue">
|
|
17
16
|
<img alt="License: MIT" src="https://img.shields.io/badge/license-MIT-green">
|
|
18
17
|
</p>
|
|
@@ -56,11 +55,11 @@ Try it yourself on the bundled fixture (`tests/sample_react`).
|
|
|
56
55
|
## Install
|
|
57
56
|
|
|
58
57
|
```bash
|
|
59
|
-
pip install git+https://github.com/
|
|
58
|
+
pip install git+https://github.com/Lime27-Star/JScope.git
|
|
60
59
|
jscope doctor # checks your install
|
|
61
60
|
```
|
|
62
61
|
|
|
63
|
-
Python 3.10+. For YAML OpenAPI specs: `pip install "jscope[yaml] @ git+https://github.com/
|
|
62
|
+
Python 3.10+. For YAML OpenAPI specs: `pip install "jscope[yaml] @ git+https://github.com/Lime27-Star/JScope.git"`.
|
|
64
63
|
|
|
65
64
|
## Quick start
|
|
66
65
|
|
|
@@ -127,7 +126,7 @@ JScope is a **beta development tool, not a production scanner.** Be aware of the
|
|
|
127
126
|
## Development
|
|
128
127
|
|
|
129
128
|
```bash
|
|
130
|
-
git clone https://github.com/
|
|
129
|
+
git clone https://github.com/Lime27-Star/JScope && cd JScope
|
|
131
130
|
python -m venv .venv && . .venv/bin/activate
|
|
132
131
|
pip install -e ".[dev]"
|
|
133
132
|
pytest
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
__version__ = "0.4.3"
|
|
@@ -18,6 +18,7 @@ from jscope.core.graph import KnowledgeGraph
|
|
|
18
18
|
from jscope import __version__
|
|
19
19
|
from jscope.pipeline import run_analysis
|
|
20
20
|
from jscope.reporting import human, json_report
|
|
21
|
+
from jscope import terminal
|
|
21
22
|
|
|
22
23
|
|
|
23
24
|
def _emit(text: str, output: str | None) -> None:
|
|
@@ -29,6 +30,14 @@ def _emit(text: str, output: str | None) -> None:
|
|
|
29
30
|
print(text)
|
|
30
31
|
|
|
31
32
|
|
|
33
|
+
def _run_analysis(paths, config, label: str = "Inspecting JavaScript and related source files"):
|
|
34
|
+
"""Run the existing engine with JScope's terminal activity treatment."""
|
|
35
|
+
if sys.stderr.isatty():
|
|
36
|
+
terminal.banner()
|
|
37
|
+
with terminal.activity(label):
|
|
38
|
+
return run_analysis(paths, config)
|
|
39
|
+
|
|
40
|
+
|
|
32
41
|
def _print_report(res, fmt: str, verbose: bool, output: str | None = None):
|
|
33
42
|
if fmt in ("markdown", "md", "html", "sarif"):
|
|
34
43
|
from jscope.reporting.formats import render_payload
|
|
@@ -57,7 +66,7 @@ def cmd_analyze(args: argparse.Namespace) -> int:
|
|
|
57
66
|
config.data["source_maps"]["expand"] = True
|
|
58
67
|
for pth in args.plugin_path or []:
|
|
59
68
|
config.data["plugins"]["paths"].append(pth)
|
|
60
|
-
res =
|
|
69
|
+
res = _run_analysis(args.paths, config)
|
|
61
70
|
|
|
62
71
|
if res.file_count == 0:
|
|
63
72
|
print("no analyzable files (JavaScript, HTML, OpenAPI, GraphQL schema, WASM) found at given path(s)", file=sys.stderr)
|
|
@@ -159,7 +168,7 @@ def cmd_go(args: argparse.Namespace) -> int:
|
|
|
159
168
|
|
|
160
169
|
if local_path.exists():
|
|
161
170
|
print(f"-> local path: {local_path}", file=sys.stderr)
|
|
162
|
-
res =
|
|
171
|
+
res = _run_analysis([str(local_path)], config, "Inspecting local target")
|
|
163
172
|
if res.file_count == 0:
|
|
164
173
|
print("no analyzable files (JavaScript, HTML, OpenAPI, GraphQL schema, WASM) found at that path", file=sys.stderr)
|
|
165
174
|
return 1
|
|
@@ -200,7 +209,7 @@ def cmd_go(args: argparse.Namespace) -> int:
|
|
|
200
209
|
failed = [r for r in results if not r.ok]
|
|
201
210
|
print(f" saved {ok} file(s)" + (f", {len(failed)} failed (run `jscope download {url_list} --out <dir>` to see why)" if failed else ""), file=sys.stderr)
|
|
202
211
|
print("[3/3] analyzing ...", file=sys.stderr)
|
|
203
|
-
res =
|
|
212
|
+
res = _run_analysis([str(site_dir)], config, "Analyzing downloaded source")
|
|
204
213
|
if res.file_count == 0:
|
|
205
214
|
print("downloaded files contained nothing analyzable", file=sys.stderr)
|
|
206
215
|
return 1
|
|
@@ -415,7 +424,7 @@ def cmd_scan(args: argparse.Namespace) -> int:
|
|
|
415
424
|
config.data["min_confidence"] = args.min_confidence
|
|
416
425
|
if args.format:
|
|
417
426
|
config.data["output"]["format"] = args.format
|
|
418
|
-
res =
|
|
427
|
+
res = _run_analysis([str(root)], config, "Analyzing workspace target")
|
|
419
428
|
if res.file_count == 0:
|
|
420
429
|
print("downloaded files contained nothing analyzable", file=sys.stderr)
|
|
421
430
|
return 1
|
|
@@ -442,7 +451,7 @@ def cmd_graph(args: argparse.Namespace) -> int:
|
|
|
442
451
|
graph = KnowledgeGraph.from_dict(data["graph"])
|
|
443
452
|
else:
|
|
444
453
|
config = Config.load(args.config)
|
|
445
|
-
res =
|
|
454
|
+
res = _run_analysis([args.source], config, "Analyzing input source")
|
|
446
455
|
graph = res.graph
|
|
447
456
|
chains = graph.route_chains()
|
|
448
457
|
if args.format == "json":
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
"""JScope's terminal presentation layer.
|
|
2
|
+
|
|
3
|
+
Presentation only: analysis, findings, and report generation remain independent.
|
|
4
|
+
Animations are restricted to interactive terminals; redirected output stays plain.
|
|
5
|
+
"""
|
|
6
|
+
from __future__ import annotations
|
|
7
|
+
|
|
8
|
+
import itertools
|
|
9
|
+
import os
|
|
10
|
+
import sys
|
|
11
|
+
import threading
|
|
12
|
+
import time
|
|
13
|
+
from contextlib import contextmanager
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
class _Style:
|
|
17
|
+
RESET = "\x1b[0m"
|
|
18
|
+
DIM = "\x1b[2m"
|
|
19
|
+
BOLD = "\x1b[1m"
|
|
20
|
+
WHITE = "\x1b[97m"
|
|
21
|
+
SILVER = "\x1b[37m"
|
|
22
|
+
LIME = "\x1b[38;5;154m"
|
|
23
|
+
AMBER = "\x1b[38;5;214m"
|
|
24
|
+
RED = "\x1b[38;5;203m"
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
def _color_enabled(stream) -> bool:
|
|
28
|
+
return bool(getattr(stream, "isatty", lambda: False)()) and not os.environ.get("NO_COLOR") and os.environ.get("TERM") != "dumb"
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
def _paint(value: str, code: str, enabled: bool) -> str:
|
|
32
|
+
return f"{code}{value}{_Style.RESET}" if enabled else value
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
def feather() -> str:
|
|
36
|
+
"""Small ASCII-native signature: reliable across terminal fonts and encodings."""
|
|
37
|
+
enabled = _color_enabled(sys.stderr)
|
|
38
|
+
return _paint("//>", _Style.LIME + _Style.BOLD, enabled)
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
def banner() -> None:
|
|
42
|
+
"""Print the compact White Hawk identity; never pollute machine-readable stdout."""
|
|
43
|
+
enabled = _color_enabled(sys.stderr)
|
|
44
|
+
mark = _paint("//>", _Style.LIME + _Style.BOLD, enabled)
|
|
45
|
+
name = _paint("JSCOPE", _Style.WHITE + _Style.BOLD, enabled)
|
|
46
|
+
tagline = _paint("JavaScript Intelligence", _Style.DIM, enabled)
|
|
47
|
+
print(f"\n {mark} {name} {tagline}", file=sys.stderr)
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
@contextmanager
|
|
51
|
+
def activity(label: str, *, announce: bool = True):
|
|
52
|
+
"""Show a quiet live indicator on TTYs, and deterministic status on other streams."""
|
|
53
|
+
stream = sys.stderr
|
|
54
|
+
tty = _color_enabled(stream)
|
|
55
|
+
if announce and not tty:
|
|
56
|
+
print(f"[>] {label}...", file=stream)
|
|
57
|
+
try:
|
|
58
|
+
yield
|
|
59
|
+
except BaseException:
|
|
60
|
+
print(f"[x] {label} failed", file=stream)
|
|
61
|
+
raise
|
|
62
|
+
else:
|
|
63
|
+
print(f"[+] {label} complete", file=stream)
|
|
64
|
+
return
|
|
65
|
+
|
|
66
|
+
if not tty:
|
|
67
|
+
yield
|
|
68
|
+
return
|
|
69
|
+
|
|
70
|
+
frames = itertools.cycle(("⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏"))
|
|
71
|
+
stopped = threading.Event()
|
|
72
|
+
def animate() -> None:
|
|
73
|
+
while not stopped.is_set():
|
|
74
|
+
frame = next(frames)
|
|
75
|
+
line = f"\r {_paint(frame, _Style.LIME, True)} {_paint(label, _Style.SILVER, True)}"
|
|
76
|
+
stream.write(line)
|
|
77
|
+
stream.flush()
|
|
78
|
+
stopped.wait(0.085)
|
|
79
|
+
thread = threading.Thread(target=animate, daemon=True)
|
|
80
|
+
if announce:
|
|
81
|
+
thread.start()
|
|
82
|
+
failed = False
|
|
83
|
+
try:
|
|
84
|
+
yield
|
|
85
|
+
except BaseException:
|
|
86
|
+
failed = True
|
|
87
|
+
raise
|
|
88
|
+
finally:
|
|
89
|
+
if announce:
|
|
90
|
+
stopped.set()
|
|
91
|
+
thread.join(timeout=0.3)
|
|
92
|
+
stream.write("\r\x1b[2K")
|
|
93
|
+
marker = _paint('x' if failed else '+', (_Style.RED if failed else _Style.LIME) + _Style.BOLD, True)
|
|
94
|
+
suffix = "failed" if failed else "complete"
|
|
95
|
+
stream.write(f" {marker} {_paint(label, _Style.SILVER, True)} {_paint(suffix, _Style.DIM, True)}\n")
|
|
96
|
+
stream.flush()
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: jscope
|
|
3
|
-
Version: 0.4.
|
|
3
|
+
Version: 0.4.3
|
|
4
4
|
Summary: Evidence-based JavaScript intelligence for bug bounty hunters and web app pentesters
|
|
5
5
|
Author: Muhammed Ali
|
|
6
6
|
License-Expression: MIT
|
|
7
|
-
Project-URL: Homepage, https://github.com/
|
|
8
|
-
Project-URL: Issues, https://github.com/
|
|
9
|
-
Project-URL: Changelog, https://github.com/
|
|
7
|
+
Project-URL: Homepage, https://github.com/Lime27-Star/JScope
|
|
8
|
+
Project-URL: Issues, https://github.com/Lime27-Star/JScope/issues
|
|
9
|
+
Project-URL: Changelog, https://github.com/Lime27-Star/JScope/blob/main/CHANGELOG.md
|
|
10
10
|
Keywords: security,bug-bounty,pentest,javascript,static-analysis,appsec,recon
|
|
11
11
|
Classifier: Development Status :: 4 - Beta
|
|
12
12
|
Classifier: Environment :: Console
|
|
@@ -37,7 +37,6 @@ Requires-Dist: build; extra == "dev"
|
|
|
37
37
|
Requires-Dist: twine; extra == "dev"
|
|
38
38
|
Dynamic: license-file
|
|
39
39
|
|
|
40
|
-
|
|
41
40
|
<p align="center">
|
|
42
41
|
<picture>
|
|
43
42
|
<source media="(prefers-color-scheme: dark)" srcset="assets/logo-dark.svg">
|
|
@@ -51,7 +50,7 @@ Dynamic: license-file
|
|
|
51
50
|
</p>
|
|
52
51
|
|
|
53
52
|
<p align="center">
|
|
54
|
-
<a href="https://github.com/
|
|
53
|
+
<a href="https://github.com/Lime27-Star/JScope/actions/workflows/ci.yml"><img alt="CI" src="https://github.com/Lime27-Star/JScope/actions/workflows/ci.yml/badge.svg"></a>
|
|
55
54
|
<img alt="Python 3.10+" src="https://img.shields.io/badge/python-3.10%2B-blue">
|
|
56
55
|
<img alt="License: MIT" src="https://img.shields.io/badge/license-MIT-green">
|
|
57
56
|
</p>
|
|
@@ -95,11 +94,11 @@ Try it yourself on the bundled fixture (`tests/sample_react`).
|
|
|
95
94
|
## Install
|
|
96
95
|
|
|
97
96
|
```bash
|
|
98
|
-
pip install git+https://github.com/
|
|
97
|
+
pip install git+https://github.com/Lime27-Star/JScope.git
|
|
99
98
|
jscope doctor # checks your install
|
|
100
99
|
```
|
|
101
100
|
|
|
102
|
-
Python 3.10+. For YAML OpenAPI specs: `pip install "jscope[yaml] @ git+https://github.com/
|
|
101
|
+
Python 3.10+. For YAML OpenAPI specs: `pip install "jscope[yaml] @ git+https://github.com/Lime27-Star/JScope.git"`.
|
|
103
102
|
|
|
104
103
|
## Quick start
|
|
105
104
|
|
|
@@ -166,7 +165,7 @@ JScope is a **beta development tool, not a production scanner.** Be aware of the
|
|
|
166
165
|
## Development
|
|
167
166
|
|
|
168
167
|
```bash
|
|
169
|
-
git clone https://github.com/
|
|
168
|
+
git clone https://github.com/Lime27-Star/JScope && cd JScope
|
|
170
169
|
python -m venv .venv && . .venv/bin/activate
|
|
171
170
|
pip install -e ".[dev]"
|
|
172
171
|
pytest
|
|
@@ -38,9 +38,9 @@ browser = ["playwright>=1.40"]
|
|
|
38
38
|
dev = ["pytest>=7", "PyYAML>=6.0", "build", "twine"]
|
|
39
39
|
|
|
40
40
|
[project.urls]
|
|
41
|
-
Homepage = "https://github.com/
|
|
42
|
-
Issues = "https://github.com/
|
|
43
|
-
Changelog = "https://github.com/
|
|
41
|
+
Homepage = "https://github.com/Lime27-Star/JScope"
|
|
42
|
+
Issues = "https://github.com/Lime27-Star/JScope/issues"
|
|
43
|
+
Changelog = "https://github.com/Lime27-Star/JScope/blob/main/CHANGELOG.md"
|
|
44
44
|
|
|
45
45
|
[project.scripts]
|
|
46
46
|
jscope = "jscope.cli:main"
|
jscope-0.4.2/jscope/__init__.py
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "0.4.2"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|