Linux Proxy Controller/Forwarder
$250-750 USD
Paguhet në dorëzim
I need a Linux-based proxy controller/forwarded that will take requests from users, and use a proxy from our database to relay it. Preferably, you would use something out-of-the-box like Squid Proxy Server and modify it to achieve the below.
============================
DB STRUCTURE
============================
Sample DB structure: [login to view URL]
============================
GENERAL OUTLINE
============================
1. User specifies proxy conditions (ie. “city”) to one of their assigned ports (“PortID”)
2. User specifies {UserID}.[login to view URL]:{PortID} in their browser
3. If more than X concurrent threads for PortID for the particular UserID, deny the request. The proxy controller should be able to limit the number of concurrent threads per port for each user
4. "[login to view URL]" selects working proxy from DB based on PortID conditions in #1
> If requested URL contains “google” but google != 1 for the proxy, then a new proxy is assigned
5. If request fails, new proxy matching conditions in #2 is assigned
6. Repeat #4 until the request is successful
7. "[login to view URL]" passes the response back to user's browser
Note that the proxy server should be able to:
- Intercept requests (ie. “[login to view URL]”) and change proxy based on it
- Query the DB for a proxy to use based on the user’s port conditions
- Forward user requests to the selected HTTPs/Socks4/Socks5 proxy from the DB
- Limit the number of concurrent threads to forward proxies and user's port
============================
DETAILED WORKFLOW
============================
1. User sets proxy criteria in the DB ("PortID")
> ie. PortID "1" for UserID "a698j64p" is set to country=US, city=New York, isp=Comcast, rotate_seconds=300
>> In the above, user created PortID where they only want proxies from Comcast ISP in New York, and the proxy should rotate every 5 minutes
2. User will configure HTTP(s) or Socks4/5 proxy in their browser that points to: {UserID}.[login to view URL]:{PortID}
> ie. [login to view URL]
3. If PortID for UserID has over X simultaneous threads/connections, deny it with an error (we want to limit the number of concurrent threads per port). Otherwise, continue to next step
4. "[login to view URL]" fetches PortID criteria from #1 and selects matching proxies in the DB
> ie. SELECT [login to view URL],proxy_ip,proxy_port
FROM lists
LEFT JOIN logs ON [login to view URL] = [login to view URL]
LEFT JOIN ports ON [login to view URL] = [login to view URL]
WHERE [login to view URL] LIKE "comcast" AND lists.total_fail_users < 3 AND lists.total_fail_reqs < 3 AND lists.current_threads < lists.max_threads AND ([login to view URL] IS NULL OR logs.last_used < (NOW() - INTERVAL 60 MINUTE) AND ports.userID="a698j64p" AND ports.port=1
SELECT [login to view URL],[login to view URL],[login to view URL] FROM lists
LEFT JOIN logs ON [login to view URL] = [login to view URL]
LEFT JOIN ports ON lists.port=[login to view URL]
WHERE [login to view URL] < 5 OR [login to view URL] IS NULL
WHERE:
- total_fail_users: # of users that encountered failure on the proxy
- total_fail_reqs: #of requests (across all users) that encountered failure on the proxy
- current_threads: To not overwhelm proxies, we might have to limit the number of concurrent threads connecting to it. This column will contain the current number of current threads (although I am not sure MySQL is the most optimal to use for this because of the massive amount of reads/writes required)
- last_used: When the proxy was last used by the user
5. "[login to view URL]" forwards GET/POST request (with all headers)
a) If proxy fails:
- "[login to view URL]" updates total_fail_reqs++ and total_fail_users++
- Add "last_used" for proxy with current timestamp
- Select different proxy and perform request again (user's connection should not drop)
> if no remaining proxies, output error message and continue retrying every X seconds
b) If proxy is a success, return response to user
- Reset total_fail_reqs and total_fail_users
- Add "last_used" for proxy with current timestamp
NOTE: Please include your intended stack and any similar projects in the bid.
ID Projekti: #18661026
Rreth projektit
7 profesionistë freelancer dërguan një ofertë mesatare prej $519 për këtë punë
Hi there, I’ve read your brief and can see that you’d like to done a project. My team has 8 years experience designing and developing mobile apps for iPhone and Android and web apps. I would approach your project by st Më shumë
i am linux administrator and having sound knowledge of ssh / putty / terminal to access files & directories inside linux vps. I have been using Shell Scripting with Sql for more then 20 Years of my career as developer Më shumë
Hello sir, I can help you with your project Linux Proxy Controller/Forwarder. I have the good experience in Linux, MySQL, Nginx, Shell Script, Squid Cache. Please see my profile i have delivered here 425 projects wi Më shumë
hello sir i am professional custom php development also following php frameworks Laravel CodeIgniter Symfony Zend Phalcon CakePHP Yii we can deliver you your project beyond your expectation . you can chat with me we ca Më shumë