Skip to content
Navigation Menu
Sign in
Products
Platform
GitHub
Repository hosting, code review, and collaboration
Copilot
AI coding agent for tasks, projects, and automated work
Build & Ship
Actions
CI/CD and automation
Code Quality
Quality analysis, fixes, and enforcement
Codespaces
Cloud development environments
Secure
Code Security
Vulnerability detection and remediation
Secret Protection
Secret scanning and leak prevention
All Features
Developers
Learn
Documentation
Training
Certifications
Build
Build with Copilot
Customize Copilot
Integrations
Explore
Trending repos
GitHub Sponsors
Developer articles
Changelog
Changelog
Your source for the latest features, improvements, and fixes across GitHub products, all in one place.
Businesses
By Stage
Enterprises
Team
Startups
Nonprofits
By Industry
Healthcare
Financial services
Manufacturing
Government
See all industries
Evaluate GitHub
Why GitHub
Customer Stories
Business insights
Trust Center
Add-ons
GitHub Advanced Security
Enterprise-grade code security
Copilot for business
Enterprise-grade AI features
Premium Support
Enterprise-grade 24/7 support
Resources
Learn & Connect
Documentation
Resource center
Blog
Events & webinars
Community Forum
Customer Stories
Integrations
Support
Customer support
Training
GitHub Status
Company
About
Partners
Changelog
GitHub Universe
GitHub Universe
The event for developers, by developers — talks, workshops, and what’s next for GitHub.
Pricing
Search
/
Sign in
Sign up
Appearance settings
You signed in with another tab or window.
Reload
to refresh your session.
You signed out in another tab or window.
Reload
to refresh your session.
You switched accounts on another tab or window.
Reload
to refresh your session.
Dismiss alert
{{ message }}
codeman857
GeneralEncryptionMiddleware
Repository navigation
Code
Issues
Pull requests
Actions
Projects
Wiki
Security and quality
Insights
More
items
Files
Expand file tree
main
Breadcrumbs
GeneralEncryptionMiddleware
/
.env
Copy path
Blame
More file actions
Blame
More file actions
Latest commit
History
History
History
28 lines (23 loc) · 2.08 KB
main
Breadcrumbs
GeneralEncryptionMiddleware
/
.env
Copy path
Top
File metadata and controls
Code
Blame
28 lines (23 loc) · 2.08 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# 1. ─────────────────────────── 基础服务器设置 ───────────────────────────
PORT=3000 # 服务器监听端口
BACKEND_API_URL=https://skhsn6q4pnv95.ezdemo.xyz # 后端真实 API 根地址不带 /api/v1(无尾斜杠)
PATH_PREFIX=/ez/ez # 路径前缀,为空""则处理所有路径,否则只处理匹配前缀的路径
# API 路径前缀,解密后的普通请求会拼上此前缀再转发到后端
# 不同面板按需修改,如 /api/v1、/api/v2 等
API_PREFIX=/api/v1
# 订阅请求标记前缀
# 客户端加密订阅路径前会加上此前缀,中间件检测到后去掉前缀直接转发(不拼 API_PREFIX)
SUBSCRIPTION_PREFIX=/sub
# 2. ─────────────────────────── CORS / 安全设置 ──────────────────────────
CORS_ORIGIN=* # 允许的 CORS 源;* 表示全部
ALLOWED_ORIGINS=* # 请求来源白名单,逗号分隔或 * 通配
REQUEST_TIMEOUT=30000 # 请求超时(ms)
ENABLE_LOGGING=false # 是否输出请求日志
DEBUG_MODE=false # 是否输出调试日志
# 3. ────────────────────────── 支付回调免验证路径 ────────────────────────
# 多条用英文逗号分隔,须写完整路径(含前缀)
# 例如: /api/v1/guest/payment/notify/EPay/12345, /api/v1/guest/payment/notify/Alipay/ABC123
ALLOWED_PAYMENT_NOTIFY_PATHS=
# 5. ────────────────────────── AES 加解密配置 ───────────────────────────
# 中间件加密KEY必须是16位的16进制字符串,必须和前端key保持一致 在线生成地址 https://www.bejson.com/math/hex_gen/
AES_KEY=4c6f8e5f9467dc71
You can’t perform that action at this time.