@dimzxzzx07/generator-ip
v1.0.0
Published
Real proxy IP generator with built-in checker - scans actual public IPs for open proxies
Maintainers
Readme
@dimzxzzx/generator-ip
| Badge | Status |
|-------|--------|
| NPM Version | |
| NPM Downloads |
|
| Node Version |
|
| License |
|
| TypeScript |
|
| Build |
|
Real Proxy IP Generator & Scanner - Find Working HTTP/HTTPS/SOCKS Proxies Fast
Installation • Quick Start • CLI Usage • API Docs • Examples • FAQ
Table of Contents
- What is This?
- Why Do You Need This?
- System Requirements & Performance
- Installation
- Quick Start
- Configuration
- CLI Usage
- API Reference
- Examples
- FAQ
- Troubleshooting
- License
What is This?
@dimzxzzx/generator-ip is a Node.js library and command-line tool that discovers real, working proxy servers by actively scanning public IP addresses. Unlike traditional proxy services that rely on pre-compiled lists or third-party APIs, this package performs live network scanning to find open proxy ports on the internet.
How It Works
- IP Generation - Generates random public IP addresses within specified country ranges (CIDR blocks)
- Port Scanning - Attempts connections on common proxy ports (8080, 3128, 80, 1080, etc.)
- Protocol Detection - Identifies proxy type (HTTP, HTTPS, SOCKS4, SOCKS5)
- Validation - Confirms the proxy actually works by routing test requests
- Caching - Stores working proxies in memory for immediate use
Core Capabilities
| Capability | Description | |------------|-------------| | Active Scanning | Probes live IP addresses, doesn't rely on outdated lists | | Geo-Targeting | Focus scanning on specific countries (ID, US, SG, JP, KR, CN) | | Multi-Protocol | Supports HTTP, HTTPS, SOCKS4, SOCKS5 | | Auto-Detection | Automatically identifies correct proxy type | | Response Timing | Measures latency of each discovered proxy | | Concurrent Scanning | Uses worker pool for high-speed discovery |
Why Do You Need This?
Use Cases
| Use Case | Description | |----------|-------------| | Web Scraping | Rotate IPs to avoid rate limiting and blocks | | Data Collection | Gather public data without revealing your identity | | API Testing | Test how your API behaves from different geographic locations | | Privacy Protection | Mask your real IP address when browsing | | Security Research | Study proxy behavior and network patterns | | Load Testing | Simulate traffic from multiple IP addresses | | Content Aggregation | Access geo-restricted content | | Bot Protection Testing | Verify your anti-bot measures work correctly |
Who Uses This
- Web Developers needing proxy rotation for scraping
- DevOps engineers testing infrastructure from multiple locations
- Security researchers analyzing network behavior
- Data scientists collecting public web data
- QA engineers testing geo-specific features
- Privacy-conscious users wanting anonymous browsing
Advantages Over Traditional Proxy Services
| Traditional Services | @dimzxzzx/generator-ip | |---------------------|------------------------| | Monthly subscription fees | Free (open source) | | Limited proxy lists | Unlimited discovery | | Outdated proxies | Real-time validation | | Fixed geographic locations | Customizable regions | | Rate limited | No artificial limits | | Dependency on providers | Self-contained |
System Requirements & Performance
Minimum Requirements (To Run Without Crashing)
| Component | Minimum | Recommended | |-----------|---------|-------------| | RAM | 512 MB | 1 GB | | CPU | 1 core @ 1.5 GHz | 2 cores @ 2.0 GHz | | Network Speed | 5 Mbps | 20 Mbps+ | | Node.js Version | 14.x | 18.x or higher | | Open File Limit | 1024 | 4096+ | | Disk Space | 100 MB | 500 MB |
Performance Tuning Guide
Memory Requirements Based on Concurrency
| Concurrency | Minimum RAM | Recommended RAM | Expected Proxies/Hour | |-------------|-------------|----------------|----------------------| | 50 | 256 MB | 512 MB | 50-100 | | 100 | 512 MB | 1 GB | 100-200 | | 150 | 768 MB | 1.5 GB | 150-300 | | 200 | 1 GB | 2 GB | 200-400 | | 300 | 1.5 GB | 3 GB | 300-500 |
Network Speed Impact on Discovery Rate
| Download Speed | Upload Speed | Scans/Second | Time to First Proxy | Stability | |----------------|--------------|--------------|---------------------|-----------| | 5 Mbps | 2 Mbps | 30-50 IP/s | 30-60 seconds | Poor | | 10 Mbps | 5 Mbps | 50-80 IP/s | 15-30 seconds | Fair | | 20 Mbps | 10 Mbps | 80-120 IP/s | 5-15 seconds | Good | | 50 Mbps | 20 Mbps | 120-180 IP/s | 2-10 seconds | Excellent | | 100 Mbps+ | 50 Mbps+ | 180-250 IP/s | 1-5 seconds | Optimal |
ISP and Network Considerations
Warning: ISP Throttling
Many ISPs (especially in Indonesia, India, and developing countries) implement traffic shaping that can severely impact proxy scanning:
| ISP Type | Expected Performance | Recommendation | |----------|---------------------|----------------| | Fiber Optic (Indihome, MyRepublic, Biznet) | Excellent (80-100% speed) | Use concurrency 150-200 | | Cable Internet (First Media, MNC Play) | Good (60-80% speed) | Use concurrency 100-150 | | ADSL (Speedy, Telkom) | Fair (40-60% speed) | Use concurrency 50-100 | | Mobile Data (Telkomsel, XL, Indosat) | Poor (20-40% speed) | Use concurrency 30-50 | | VPN/Proxy Connection | Unpredictable | Not recommended for scanning |
Signs of ISP Throttling:
- Scan speed suddenly drops after 30-60 seconds
- Many connection timeouts
- Error:
EMFILEorENFILE - Success rate drops to near 0%
Solutions for Throttled Connections:
# Reduce concurrency
generator-ip start --concurrency 50
# Increase timeout
generator-ip start --timeout 2000
# Use slower scan mode
generator-ip start --mode deep --timeout 3000
# Change region (sometimes different regions bypass throttling)
generator-ip start --region USOptimal Settings by Use Case
For Maximum Speed (High-end VPS)
generator-ip start \
--concurrency 250 \
--timeout 800 \
--mode fast \
--region SG \
--size 200For Stable Discovery (Home Internet)
generator-ip start \
--concurrency 80 \
--timeout 1500 \
--mode fast \
--region ID \
--size 100For Low Bandwidth (Mobile/Cellular)
generator-ip start \
--concurrency 30 \
--timeout 2000 \
--mode deep \
--region ALL \
--size 50For Maximum Success Rate (Slow but Reliable)
generator-ip start \
--concurrency 50 \
--timeout 3000 \
--mode deep \
--region ALL \
--size 100Monitoring Performance
To check if your system is performing optimally:
# Check real-time statistics
generator-ip stats --debug
# Monitor system resources (Linux)
htop
# Check network usage
nethogs
# Check open file limits
ulimit -nExpected Performance Metrics
Region Expected Hit Rate Average Time to First Proxy Proxies per Hour (100 concurrency) SG (Singapore) 0.3-0.8% 5-15 seconds 150-300 ID (Indonesia) 0.1-0.4% 10-30 seconds 100-200 US (United States) 0.2-0.6% 8-20 seconds 120-250 JP (Japan) 0.2-0.5% 10-25 seconds 100-200 KR (Korea) 0.1-0.3% 15-35 seconds 80-150 CN (China) 0.05-0.2% 30-60 seconds 50-100 ALL (Global) 0.01-0.05% 45-90 seconds 30-80
Memory Usage Breakdown
Component Memory per Instance Notes Base Node.js process 30-50 MB Minimum overhead Per active socket 2-5 KB 150 sockets = 300-750 KB Proxy cache (100 proxies) 1-2 MB Each proxy ~10-20 KB IP range cache 10-20 MB CIDR data structures Logging buffer 5-10 MB When debug enabled Total (idle) 80-100 MB No scanning active Total (scanning) 150-250 MB Active scanning Total (peak) 300-400 MB Maximum usage
Preventing Crashes
Linux/Unix Systems - Increase File Limits
# Check current limits
ulimit -n
# Increase temporarily (session)
ulimit -n 65535
# Make permanent (add to /etc/security/limits.conf)
* soft nofile 65535
* hard nofile 65535
# Apply changes
sysctl -pWindows Systems
# Check current limits
wmic os get TotalVisibleMemorySize
# Run Node with increased memory
node --max-old-space-size=2048 dist/cli.js startDocker Container Limits
# Dockerfile
FROM node:18-alpine
# Increase file limits
RUN ulimit -n 65535
# Set memory limit
CMD ["node", "--max-old-space-size=2048", "dist/cli.js"]# docker-compose.yml
services:
proxy-generator:
ulimits:
nofile:
soft: 65535
hard: 65535
mem_limit: 2gTroubleshooting Performance Issues
Problem Possible Cause Solution No proxies found after 5 minutes ISP blocking, wrong region Change region, reduce concurrency Error: EMFILE Too many open files Increase file limits, reduce concurrency Error: ECONNRESET Connection reset by peer Increase timeout, reduce concurrency High CPU usage (100%) Too many concurrent connections Reduce concurrency value Memory leak Socket not destroyed Update to latest version Slow scan speed (<10 IP/s) Network throttling Use deep mode, increase timeout Process kills itself Out of memory Reduce concurrency, increase RAM Socket hang up ISP interference Use VPN or different region
Installation
NPM
# Install as dependency
npm install @dimzxzzx/generator-ip
# Install globally for CLI
npm install -g @dimzxzzx/generator-ipYarn
yarn add @dimzxzzx/generator-ipPNPM
pnpm add @dimzxzzx/generator-ipQuick Start
Command Line
# Get a single working proxy from Indonesia
generator-ip get-one --region ID
# Get 5 working proxies from Singapore
generator-ip get-many 5 --region SG --timeout 1200
# Start continuous scanning
generator-ip start --region US --concurrency 150
# Check scanning statistics
generator-ip stats --debugJavaScript/TypeScript
import IPGenerator from '@dimzxzzx/generator-ip';
// Create generator instance
const generator = new IPGenerator({
country: 'ID',
timeout: 1200,
concurrency: 100,
scanMode: 'fast'
});
// Get one working proxy
const proxy = await generator.getOne();
console.log(`Found: ${proxy.ip}:${proxy.port} (${proxy.type})`);
// Get multiple proxies
const proxies = await generator.getMany(5);
proxies.forEach(p => {
console.log(`${p.ip}:${p.port} - ${p.responseTime}ms`);
});
// Clean up
generator.destroy();Configuration
Configuration Options
Option Type Default Description timeout number 1200 Connection timeout in milliseconds type string 'all' Proxy type: 'http', 'https', 'socks4', 'socks5', 'all' anonymous boolean false Only return anonymous proxies country string 'ID' Country code: ID, US, SG, JP, KR, CN, ALL maxPoolSize number 150 Maximum number of proxies to cache verify boolean true Verify proxies before returning debug boolean false Enable debug logging concurrency number 150 Number of concurrent scanning workers scanMode string 'fast' 'fast' (CONNECT only) or 'deep' (CONNECT + GET) targetCIDRs string[] null Custom CIDR ranges to scan
Environment Variables
# .env file
PROXY_TIMEOUT=1200
PROXY_COUNTRY=SG
PROXY_CONCURRENCY=200
PROXY_SCAN_MODE=fast
PROXY_DEBUG=trueCLI Usage
Commands
Command Description get-one Get a single valid proxy get-many Get multiple valid proxies stats Show generator statistics pool Show current proxy pool start Start continuous background scanning stop Stop background scanning
Options
Option Description -t, --timeout Connection timeout (default: 1200) -r, --region Country code: ID, US, SG, JP, KR, CN, ALL -m, --mode Scan mode: fast or deep -c, --concurrency Concurrent workers (default: 150) -s, --size Max pool size (default: 150) --type Proxy type: http, https, socks4, socks5, all --anonymous Only return anonymous proxies --debug Enable debug logging
CLI Examples
# Basic proxy discovery
generator-ip get-one --region ID
# Get 10 fast proxies from Singapore
generator-ip get-many 10 --region SG --timeout 1000 --mode fast
# Deep scan for high-quality proxies
generator-ip get-many 5 --region US --timeout 2000 --mode deep
# Continuous scanning with live progress
generator-ip start --region ID --concurrency 200 --size 100 --debug
# Check statistics
generator-ip stats --region SG
# View cached pool
generator-ip pool
# Get anonymous proxies only
generator-ip get-many 3 --region ALL --anonymous --type httpAPI Reference
IPGenerator Class
class IPGenerator extends EventEmitter {
constructor(config?: Partial<Config>);
// Methods
getOne(): Promise<Proxy | null>;
getMany(limit: number): Promise<Proxy[]>;
random(): Proxy;
getPool(): Proxy[];
getPoolSize(): number;
getStats(): GeneratorStats;
pause(): void;
resume(): void;
destroy(): void;
// Events
on('proxy-found', (proxy: Proxy) => void): this;
on('pool-updated', (size: number) => void): this;
}Proxy Interface
interface Proxy {
ip: string; // IP address
port: number; // Port number
type: string; // http, https, socks4, socks5
country?: string; // Country code
anonymous?: boolean; // Whether proxy hides your IP
lastChecked?: number; // Last verification timestamp
responseTime?: number; // Response time in milliseconds
}Config Interface
interface Config {
timeout: number; // Connection timeout (ms)
type: 'http' | 'https' | 'socks4' | 'socks5' | 'all';
anonymous: boolean; // Filter anonymous proxies
country: string; // Country code
maxPoolSize: number; // Maximum pool size
verify: boolean; // Verify before returning
debug: boolean; // Debug logging
concurrency: number; // Concurrent workers
scanMode: 'fast' | 'deep';
targetCIDRs?: string[];
}GeneratorStats Interface
interface GeneratorStats {
totalAttempts: number; // Total scan attempts
successCount: number; // Successful proxies found
hitRate: string; // Success rate percentage
poolSize: number; // Current pool size
activeSockets: number; // Active connections
region: string; // Current scanning region
scanMode: string; // Current scan mode
}Examples
Basic JavaScript Example
const IPGenerator = require('@dimzxzzx/generator-ip');
async function main() {
const generator = new IPGenerator({
country: 'SG',
timeout: 1000,
concurrency: 100
});
// Get a single proxy
const proxy = await generator.getOne();
if (proxy) {
console.log(`Proxy: ${proxy.ip}:${proxy.port}`);
console.log(`Type: ${proxy.type}`);
console.log(`Response: ${proxy.responseTime}ms`);
}
generator.destroy();
}
main();TypeScript Backend (Express.js)
import express, { Request, Response } from 'express';
import IPGenerator from '@dimzxzzx/generator-ip';
const app = express();
const generator = new IPGenerator({
country: 'ID',
timeout: 1200,
concurrency: 150,
debug: true
});
generator.startBackgroundGeneration();
app.get('/api/proxy/random', async (req: Request, res: Response) => {
try {
const proxy = await generator.getOne();
if (proxy) {
res.json({
success: true,
data: {
ip: proxy.ip,
port: proxy.port,
type: proxy.type,
responseTime: proxy.responseTime
}
});
} else {
res.status(404).json({ success: false, message: 'No proxy available' });
}
} catch (error) {
res.status(500).json({ success: false, error: error.message });
}
});
app.get('/api/proxy/list', async (req: Request, res: Response) => {
const limit = parseInt(req.query.limit as string) || 10;
const proxies = await generator.getMany(limit);
res.json({ success: true, count: proxies.length, data: proxies });
});
app.get('/api/proxy/stats', (req: Request, res: Response) => {
const stats = generator.getStats();
res.json({ success: true, stats });
});
app.listen(3000, () => {
console.log('Server running on port 3000');
});Java Backend (Spring Boot) - REST Client
// ProxyService.java
import org.springframework.stereotype.Service;
import org.springframework.web.reactive.function.client.WebClient;
import reactor.core.publisher.Mono;
@Service
public class ProxyService {
private final WebClient webClient;
public ProxyService() {
this.webClient = WebClient.builder()
.baseUrl("http://localhost:3000")
.build();
}
public Mono<ProxyResponse> getRandomProxy() {
return webClient.get()
.uri("/api/proxy/random")
.retrieve()
.bodyToMono(ProxyResponse.class);
}
public Mono<ProxyListResponse> getProxyList(int limit) {
return webClient.get()
.uri("/api/proxy/list?limit=" + limit)
.retrieve()
.bodyToMono(ProxyListResponse.class);
}
}
// ProxyResponse.java
public class ProxyResponse {
private boolean success;
private ProxyData data;
// getters and setters
}
// ProxyData.java
public class ProxyData {
private String ip;
private int port;
private String type;
private int responseTime;
// getters and setters
}Kotlin Backend (Ktor)
// ProxyClient.kt
import io.ktor.client.*
import io.ktor.client.engine.cio.*
import io.ktor.client.request.*
import io.ktor.client.statement.*
import kotlinx.serialization.Serializable
import kotlinx.serialization.json.Json
@Serializable
data class ProxyData(
val ip: String,
val port: Int,
val type: String,
val responseTime: Int
)
@Serializable
data class ProxyResponse(
val success: Boolean,
val data: ProxyData?
)
class ProxyClient {
private val client = HttpClient(CIO)
private val json = Json { ignoreUnknownKeys = true }
suspend fun getRandomProxy(): ProxyData? {
val response = client.get("http://localhost:3000/api/proxy/random")
val text = response.bodyAsText()
val result = json.decodeFromString<ProxyResponse>(text)
return result.data
}
suspend fun getProxyList(limit: Int): List<ProxyData> {
val response = client.get("http://localhost:3000/api/proxy/list?limit=$limit")
val text = response.bodyAsText()
// Parse response
return emptyList()
}
fun close() {
client.close()
}
}Flutter/Dart Backend
// proxy_service.dart
import 'dart:convert';
import 'package:http/http.dart' as http;
class ProxyData {
final String ip;
final int port;
final String type;
final int responseTime;
ProxyData({
required this.ip,
required this.port,
required this.type,
required this.responseTime,
});
factory ProxyData.fromJson(Map<String, dynamic> json) {
return ProxyData(
ip: json['ip'],
port: json['port'],
type: json['type'],
responseTime: json['responseTime'],
);
}
}
class ProxyService {
final String baseUrl;
ProxyService({this.baseUrl = 'http://localhost:3000'});
Future<ProxyData?> getRandomProxy() async {
try {
final response = await http.get(Uri.parse('$baseUrl/api/proxy/random'));
if (response.statusCode == 200) {
final data = jsonDecode(response.body);
if (data['success'] && data['data'] != null) {
return ProxyData.fromJson(data['data']);
}
}
return null;
} catch (e) {
print('Error getting proxy: $e');
return null;
}
}
Future<List<ProxyData>> getProxyList(int limit) async {
try {
final response = await http.get(
Uri.parse('$baseUrl/api/proxy/list?limit=$limit')
);
if (response.statusCode == 200) {
final data = jsonDecode(response.body);
if (data['success']) {
final List<dynamic> proxies = data['data'];
return proxies.map((p) => ProxyData.fromJson(p)).toList();
}
}
return [];
} catch (e) {
print('Error getting proxy list: $e');
return [];
}
}
Future<Map<String, dynamic>?> getStats() async {
try {
final response = await http.get(Uri.parse('$baseUrl/api/proxy/stats'));
if (response.statusCode == 200) {
return jsonDecode(response.body);
}
return null;
} catch (e) {
print('Error getting stats: $e');
return null;
}
}
}
// Usage
void main() async {
final service = ProxyService();
// Get random proxy
final proxy = await service.getRandomProxy();
if (proxy != null) {
print('Proxy: ${proxy.ip}:${proxy.port}');
}
// Get multiple proxies
final proxies = await service.getProxyList(5);
print('Found ${proxies.length} proxies');
// Get statistics
final stats = await service.getStats();
print('Stats: $stats');
}Docker Deployment
# Dockerfile
FROM node:18-alpine
WORKDIR /app
COPY package*.json ./
RUN npm install
COPY . .
RUN npm run build
# Increase file limits
RUN ulimit -n 65535
EXPOSE 3000
CMD ["node", "--max-old-space-size=2048", "dist/server.js"]# docker-compose.yml
version: '3.8'
services:
proxy-generator:
build: .
ports:
- "3000:3000"
environment:
- PROXY_TIMEOUT=1200
- PROXY_COUNTRY=SG
- PROXY_CONCURRENCY=150
- PROXY_DEBUG=true
ulimits:
nofile:
soft: 65535
hard: 65535
mem_limit: 2g
restart: unless-stoppedFAQ
General Questions
Q: What is a proxy and why would I need one?
A: A proxy server acts as an intermediary between your device and the internet. It masks your real IP address, allowing you to appear as if you're browsing from a different location. Common uses include web scraping, bypassing geo-restrictions, privacy protection, and load testing.
Q: Is this tool free?
A: Yes, @dimzxzzx/generator-ip is completely free and open source under the MIT license.
Q: Do I need an API key or subscription?
A: No. This tool does not rely on any external APIs or paid services. It performs active network scanning to discover proxies directly.
Q: How many proxies can I get?
A: Unlimited. The tool continuously scans and discovers new proxies. With optimal settings, you can find 100-500 working proxies per hour.
Q: Are the proxies anonymous?
A: Many discovered proxies are anonymous, but not all. Use the --anonymous flag to filter only anonymous proxies.
Q: How long do discovered proxies last?
A: Proxy lifespans vary from minutes to days. Free proxies are often unstable. The tool automatically verifies each proxy before returning it, ensuring you only get working ones.
Technical Questions
Q: Why am I not finding any proxies?
A: Possible reasons:
· ISP blocking or throttling · Wrong region selection (try SG or US) · Timeout too low (increase to 1500-2000ms) · Concurrency too high for your connection (reduce to 50-80) · Firewall blocking outbound connections
Q: What's the difference between fast and deep scan mode?
A:
· Fast mode: Only uses CONNECT method (faster, works for most proxies) · Deep mode: Tries CONNECT first, then falls back to GET (slower but higher success rate)
Q: How does the tool detect proxy type?
A: The tool analyzes the response headers from the proxy. HTTP proxies return HTTP status codes (200, 302, 301), while SOCKS proxies respond with SOCKS protocol handshake patterns.
Q: Can this tool detect elite/anonymous proxies?
A: Yes. The tool checks if the proxy adds identifying headers (X-Forwarded-For, Via). Proxies without these headers are marked as anonymous.
Q: What ports does the tool scan?
A: Priority ports: 8080, 3128, 80, 1080, 8118, 8000, 8888, 9999. Common ports also include 1081, 1085, 1086, 1087, 1088, 1089, 902, 903, 4145, 554.
Q: Can I scan custom IP ranges?
A: Yes. Use the targetCIDRs option in the config to specify custom CIDR blocks.
Q: Does this tool work on Windows?
A: Yes. The tool works on Windows, macOS, and Linux.
Q: Will my ISP block me for scanning?
A: Some ISPs may throttle or temporarily limit connections when detecting port scanning activity. Use moderate concurrency (50-100) to avoid detection.
Performance Questions
Q: How much RAM do I need?
A: Minimum 512 MB, recommended 1 GB. With 150 concurrency, expect 150-250 MB usage.
Q: What internet speed is required?
A: Minimum 5 Mbps, recommended 20 Mbps+. Faster speeds significantly improve discovery rates.
Q: Why is my scan speed slow (<30 IP/s)?
A: Possible causes:
· ISP throttling (reduce concurrency) · High latency connection (increase timeout) · CPU bottleneck (reduce concurrency) · Running on weak hardware (upgrade VPS)
Q: How can I increase discovery speed?
A:
· Use a VPS with good network (DigitalOcean, Linode, Vultr) · Choose SG or US region (best connectivity) · Set timeout to 800-1000ms · Use fast scan mode · Increase concurrency to 150-200
Q: Why does the tool crash with EMFILE error?
A: This means you've reached the system's open file limit. Increase the limit with ulimit -n 65535 on Linux/macOS.
Q: What VPS provider is best for scanning?
A:
· DigitalOcean (Singapore/San Francisco) - Good · Vultr (Tokyo/Singapore) - Excellent · Linode (Singapore/Tokyo) - Good · AWS (any region) - Excellent but expensive
Error Troubleshooting
Q: Error: connect ETIMEDOUT
A: The connection timed out. Increase timeout: --timeout 2000
Q: Error: connect ECONNREFUSED
A: The target port is closed or filtered. This is normal, no action needed.
Q: Error: EMFILE too many open files
A: Increase file limits: ulimit -n 65535
Q: Error: JavaScript heap out of memory
A: Increase Node.js memory: node --max-old-space-size=2048
Q: Error: socket hang up
A: The proxy closed the connection. Increase timeout or reduce concurrency.
Q: No output or stuck at 0%
A: Check your network connection. Try different region or reduce concurrency.
Integration Questions
Q: Can I use this in a production environment?
A: Yes. The tool is stable and production-ready. Use the programmatic API with proper error handling.
Q: How do I integrate with my existing scraper?
A: Use the getOne() or getMany() methods to obtain proxies, then configure your HTTP client to use them.
Q: Can I use this with Puppeteer/Playwright?
A: Yes. Pass the proxy to Puppeteer's --proxy-server argument.
Q: Does this work with Selenium?
A: Yes. Configure Selenium to use the proxy via ChromeOptions or FirefoxOptions.
Q: Can I run this as a microservice?
A: Yes. The Express.js example shows how to create a REST API for proxy distribution.
Q: Is there a WebSocket API?
A: The examples include a WebSocket server that streams newly discovered proxies in real-time.
Legal Questions
Q: Is proxy scanning legal?
A: Scanning public IP addresses is generally legal, but check your local laws. Using proxies to bypass security measures or access unauthorized content may violate terms of service.
Q: Can I use these proxies for illegal activities?
A: No. This tool is intended for legitimate purposes like web scraping, testing, and privacy protection.
Q: Will using this tool get my IP banned?
A: Some websites may rate-limit or block IPs that perform excessive scanning. Use responsibly and consider using a VPN.
Troubleshooting
Common Issues
Issue Cause Solution No proxies found after 5 minutes ISP blocking, wrong region Change region, reduce concurrency Error: EMFILE Too many open files Increase file limits, reduce concurrency Error: ECONNRESET Connection reset by peer Increase timeout, reduce concurrency High CPU usage (100%) Too many concurrent connections Reduce concurrency value Memory leak Socket not destroyed Update to latest version Slow scan speed (<10 IP/s) Network throttling Use deep mode, increase timeout Process kills itself Out of memory Reduce concurrency, increase RAM Socket hang up ISP interference Use VPN or different region
Debug Mode
# Enable debug logging
generator-ip get-one --region ID --debug
# Or in code
const generator = new IPGenerator({ debug: true });Logs Location
logs/
├── app.log # Application logs
├── error.log # Error logs only
└── debug.log # Debug information (when enabled)Recovery Procedures
- Stop the generator
generator-ip stop - Check logs for issues
tail -f logs/error.log - Reduce concurrency and retry
generator-ip start --concurrency 50 --region SG - Reset configuration
# Delete node_modules and reinstall rm -rf node_modules npm install
License
MIT License - See LICENSE file for details.
Created by Dimzxzzx
https://img.shields.io/badge/Telegram-@Dimzxzzx07-26A5E4?style=flat-square&logo=telegram https://img.shields.io/badge/GitHub-Dimzxzzx-181717?style=flat-square&logo=github
