惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
Apple Machine Learning Research
Apple Machine Learning Research
月光博客
月光博客
量子位
IT之家
IT之家
Jina AI
Jina AI
Help Net Security
Help Net Security
Cyberwarzone
Cyberwarzone
人人都是产品经理
人人都是产品经理
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
AWS News Blog
AWS News Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
罗磊的独立博客
P
Proofpoint News Feed
S
Schneier on Security
Spread Privacy
Spread Privacy
The Hacker News
The Hacker News
Know Your Adversary
Know Your Adversary
雷峰网
雷峰网
L
LINUX DO - 热门话题
博客园 - 聂微东
C
Cisco Blogs
酷 壳 – CoolShell
酷 壳 – CoolShell
Security Latest
Security Latest
阮一峰的网络日志
阮一峰的网络日志
I
Intezer
K
Kaspersky official blog
C
CXSECURITY Database RSS Feed - CXSecurity.com
T
Threatpost
Last Week in AI
Last Week in AI
博客园 - Franky
G
GRAHAM CLULEY
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
T
Tailwind CSS Blog
L
LINUX DO - 最新话题
T
The Exploit Database - CXSecurity.com
博客园 - 三生石上(FineUI控件)
P
Privacy International News Feed
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
有赞技术团队
有赞技术团队
Schneier on Security
Schneier on Security
V
V2EX
V
Visual Studio Blog
S
Security @ Cisco Blogs
博客园 - 叶小钗
H
Hacker News: Front Page
小众软件
小众软件
WordPress大学
WordPress大学
V2EX - 技术
V2EX - 技术
美团技术团队

zplb

I Built a Web Server That Runs Python and PHP in the Same Page How to Host a .onion Site on Your Own Computer (No VPS Required) Converting IPA to Speech Using Python Huawei Switch CLI Cheat Sheet
Setting Up a Minimal Public TinyProxy with Basic Authentication on CentOS
2026-02-15 · via zplb

I wanted a lightweight HTTP/HTTPS proxy for CentOS 7/8 with username/password authentication. TinyProxy is perfect for this—it’s simple, fast, and can be exposed to the public Internet.

Here’s a minimal guide.


1. Environment

  • OS: CentOS 7 / 8
  • Proxy software: TinyProxy
  • Protocols: HTTP / HTTPS
  • Auth: Basic Authentication
  • Port: 8888

2. Install TinyProxy

sudo yum install -y tinyproxy

After installation:

  • Config file: /etc/tinyproxy/tinyproxy.conf
  • Service name: tinyproxy

3. Configure TinyProxy (Public + Auth)

a) Edit config file

sudo vi /etc/tinyproxy/tinyproxy.conf

b) Set listening port

Port 8888

To reduce scanning risk, you can choose a non-default port, e.g., 28888.


c) Allow public access

By default, TinyProxy only allows localhost. Remove or comment out:

Allow 127.0.0.1
Allow ::1

Add:

Allow 0.0.0.0/0

This allows all IPv4 addresses to connect (public).


d) Enable username/password authentication

Add or uncomment:

BasicAuth user123 foiehfsefh

Explanation:

  • Username: user123
  • Password: foiehfsefh
  • TinyProxy stores credentials in plain text (HTTP Basic Auth).

e) Recommended minimal settings

Timeout 600
LogLevel Info
MaxClients 100
ViaProxyName "tinyproxy"

4. Minimal Full Config Example

User tinyproxy
Group tinyproxy

Port 8888

Timeout 600
LogLevel Info
MaxClients 100

Allow 0.0.0.0/0

BasicAuth user123 foiehfsefh

ViaProxyName "tinyproxy"

All other settings can remain default.


5. Start Service & Enable Autostart

sudo systemctl restart tinyproxy
sudo systemctl enable tinyproxy

Check status:

systemctl status tinyproxy

6. Open Firewall Port

If firewalld is enabled:

sudo firewall-cmd --permanent --add-port=8888/tcp
sudo firewall-cmd --reload

7. Client Test

a) Command-line test

curl -x http://user123:foiehfsefh@<PUBLIC_IP>:8888 http://www.google.com

If HTML content is returned, the proxy and auth are working.


b) Browser Test

  • Proxy type: HTTP
  • Server IP: <PUBLIC_IP>
  • Port: 8888

When visiting a website, you will be prompted for username/password. HTTPS works as well.