BREAKING CHANGE(deps): upgrade major dependencies, migrate action.target to action.targets (array), adapt to SmartRequest API changes, and add RADIUS server support
This commit is contained in:
37
readme.md
37
readme.md
@@ -40,6 +40,11 @@ A comprehensive traffic routing solution that provides unified gateway capabilit
|
||||
- **DKIM, SPF, DMARC** authentication and verification
|
||||
- **Enterprise deliverability** with IP warmup and reputation management
|
||||
|
||||
### 📡 **RADIUS Server**
|
||||
- **MAC Authentication Bypass (MAB)** for network device authentication
|
||||
- **VLAN assignment** based on MAC address or OUI patterns
|
||||
- **RADIUS accounting** for session tracking and billing
|
||||
|
||||
### ⚡ **High Performance**
|
||||
- **Connection pooling** and efficient resource management
|
||||
- **Load balancing** with automatic failover
|
||||
@@ -79,7 +84,7 @@ const router = new DcRouter({
|
||||
match: { domains: ['example.com'], ports: [443] },
|
||||
action: {
|
||||
type: 'forward',
|
||||
target: { host: '192.168.1.10', port: 8080 },
|
||||
targets: [{ host: '192.168.1.10', port: 8080 }],
|
||||
tls: { mode: 'terminate', certificate: 'auto' }
|
||||
}
|
||||
}
|
||||
@@ -271,10 +276,10 @@ interface IRouteConfig {
|
||||
};
|
||||
action: {
|
||||
type: 'forward' | 'redirect' | 'serve';
|
||||
target?: {
|
||||
targets?: Array<{
|
||||
host: string;
|
||||
port: number | 'preserve' | ((context: any) => number);
|
||||
};
|
||||
}>;
|
||||
tls?: {
|
||||
mode: 'terminate' | 'passthrough';
|
||||
certificate?: 'auto' | string;
|
||||
@@ -640,15 +645,7 @@ const routes = [
|
||||
},
|
||||
action: {
|
||||
type: 'forward',
|
||||
target: {
|
||||
host: '192.168.1.20',
|
||||
port: (context) => {
|
||||
// Route based on path
|
||||
if (context.path.startsWith('/v1/')) return 8080;
|
||||
if (context.path.startsWith('/v2/')) return 8081;
|
||||
return 8080;
|
||||
}
|
||||
},
|
||||
targets: [{ host: '192.168.1.20', port: 8080 }],
|
||||
tls: {
|
||||
mode: 'terminate',
|
||||
certificate: 'auto'
|
||||
@@ -687,10 +684,7 @@ const tcpRoutes = [
|
||||
},
|
||||
action: {
|
||||
type: 'forward',
|
||||
target: {
|
||||
host: '192.168.1.30',
|
||||
port: 'preserve'
|
||||
},
|
||||
targets: [{ host: '192.168.1.30', port: 'preserve' }],
|
||||
security: {
|
||||
ipAllowList: ['192.168.1.0/24']
|
||||
}
|
||||
@@ -706,10 +700,7 @@ const tcpRoutes = [
|
||||
},
|
||||
action: {
|
||||
type: 'forward',
|
||||
target: {
|
||||
host: '192.168.1.40',
|
||||
port: 8443
|
||||
},
|
||||
targets: [{ host: '192.168.1.40', port: 8443 }],
|
||||
tls: {
|
||||
mode: 'passthrough'
|
||||
}
|
||||
@@ -893,7 +884,7 @@ const router = new DcRouter({
|
||||
match: { domains: ['example.com', 'www.example.com'], ports: [443] },
|
||||
action: {
|
||||
type: 'forward',
|
||||
target: { host: '192.168.1.10', port: 80 },
|
||||
targets: [{ host: '192.168.1.10', port: 80 }],
|
||||
tls: { mode: 'terminate', certificate: 'auto' }
|
||||
}
|
||||
},
|
||||
@@ -905,7 +896,7 @@ const router = new DcRouter({
|
||||
match: { domains: ['api.example.com'], ports: [443] },
|
||||
action: {
|
||||
type: 'forward',
|
||||
target: { host: '192.168.1.20', port: 8080 },
|
||||
targets: [{ host: '192.168.1.20', port: 8080 }],
|
||||
tls: { mode: 'terminate', certificate: 'auto' }
|
||||
}
|
||||
},
|
||||
@@ -916,7 +907,7 @@ const router = new DcRouter({
|
||||
match: { ports: [{ from: 8000, to: 8999 }] },
|
||||
action: {
|
||||
type: 'forward',
|
||||
target: { host: '192.168.1.30', port: 'preserve' },
|
||||
targets: [{ host: '192.168.1.30', port: 'preserve' }],
|
||||
security: { ipAllowList: ['192.168.0.0/16'] }
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user