Gathering detailed insights and metrics for weboverlay
Gathering detailed insights and metrics for weboverlay
Gathering detailed insights and metrics for weboverlay
Gathering detailed insights and metrics for weboverlay
npm install weboverlay
Typescript
Module System
Min. Node Version
Node Version
NPM Version
64.6
Supply Chain
63.2
Quality
72.9
Maintenance
100
Vulnerability
100
License
TypeScript (94.55%)
JavaScript (4.8%)
HTML (0.47%)
CSS (0.18%)
Love this project? Help keep it running — sponsor us today! 🚀
Total Downloads
5,824
Last Day
2
Last Week
32
Last Month
150
Last Year
2,724
1 Stars
131 Commits
2 Watching
13 Branches
1 Contributors
Minified
Minified + Gzipped
Latest Version
1.0.2
Package Id
weboverlay@1.0.2
Unpacked Size
24.48 kB
Size
7.08 kB
File Count
10
NPM Version
9.6.7
Node Version
18.17.0
Publised On
01 Aug 2023
Cumulative downloads
Total Downloads
Last day
-75%
2
Compared to previous day
Last week
-17.9%
32
Compared to previous week
Last month
240.9%
150
Compared to previous month
Last year
189.5%
2,724
Compared to previous year
13
Layered Hybrid Web Server: local files, upstream proxy and content transform
1# install 2npm install -g weboverlay 3 4# overlay multiple local document root paths 5weboverlay ../repo1/htdocs ../repo2/htdocs ../repo3/htdocs 6 7# overlay local files and upstream remote origin server contents with cache 8weboverlay htdocs https://example.com --cache 9 10# rewrite remote content with sed-style transform 11weboverlay 's#/example.com/#/127.0.0.1:3000/#g' https://example.com --cache=cached --log=dev --json 12 13# replace product names on a corporate website 14weboverlay "s/MacBook/Surface/g" https://www.apple.com --cache=cached --port=3000 15 16# mount git repository 17weboverlay ../repo1/.git:htdocs 18 19# mount raw Express middleware 20weboverlay "(req, res, next) => res.send('OK\n')" 21 22# open browser 23open http://127.0.0.1:3000/
1weboverlay [s/regexp/replacement/g] [type(function)] [htdocs...] [https://hostname] [--options...]
s/regexp/replacement/g
- sed
-style transforms applied for every text contentshtml(s=>s.toLowerCase())
- custom transform JavaScript function for the content typehtdocs
- path to local document root directory^/path/with/regexp\.(html|css|js)$=htdocs
- regexp to match with the path specified/path/to/not/found=404
- path to always respond the status: 404 Not Found
path/to/.git:htdocs
- mount htdocs
directory from .git
repository/alias/=local/path
- partial mount aliashttps://upstream.host
- URL to remote upstream origin server: http://
or https://
//virtual.host.name/=htdocs
- name based virtual host for local files//proxy.host.name/=https://upstream.host
- name based virtual host for upstream proxy//transorm.host.name/=s/regexp/replacement/g
- name based virtual host for content transform(req, res, next) => res.send('OK\n')
- raw Express middleware--basic=user:password
- username and password for basic authentication--cache=cached
- path to directory to cache remote content (default: disabled)--compress=br
- force compression with Brotli--compress=identity
- no compression--config=weboverlay.yml
- path to load configuration in YAML--index
- directory listing for local files (default: disabled)--json
- prettify JSON response (default: disabled)--log=dev
- morgan access log format: combined
, dev
, etc. (default: tiny
)--logfile=weboverlay.log
- path to write log (default: STDOUT)--port=3000
- port number to listen (default: 3000
)1# content source layers: local path, upstream proxy and content transform 2layers: 3 - s/regexp/replacement/g 4 - html(s => s.toLowerCase()) 5 - htdocs 6 - path/to/.git:htdocs 7 - ^/path/with/regexp\.(html|css|js)$ = htdocs 8 - /path/to/not/found = 404 9 - /alias/ = local/path 10 - https://upstream.host 11 - //virtual.host.name/ = htdocs 12 - //proxy.host.name/ = https://upstream.host 13 - //transorm.host.name/ = s/regexp/replacement/g 14 - (req, res, next) => res.send('OK\n') 15 16# username and password for basic authentication 17basic: 18 - user:password 19 20# path to directory to cache remote content (default: disabled) 21cache: cached 22 23# no compression 24compress: identity 25 26# directory listing for local files (default: disabled) 27index: true 28 29# prettify JSON response (default: disabled) 30json: true 31 32# morgan access log format: `combined`, `dev`, etc. (default: `tiny`) 33log: dev 34 35# path to write log (default: STDOUT) 36logfile: weboverlay.log 37 38# port number to listen (default: `3000`) 39port: 3000
See TypeScript declaration weboverlay.d.ts for more detail.
The MIT License (MIT)
Copyright (c) 2020-2023 Yusuke Kawasaki
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
0 existing vulnerabilities detected
Reason
license file detected
Details
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
Found 0/11 approved changesets -- score normalized to 0
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Score
Last Scanned on 2025-02-03
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More