feat: rebranded from vpn-router to linux-manager.
This commit is contained in:
1 parent
8efe21bfa6
commit
85a1ffa21f
238 files changed
+5010
-3761
No files matched your search
@@ -3,10 +3,10 @@ import { useState, type FormEvent } from 'react'
|
||||
import { OPENVPN_PROTOCOLS, REMOTE_ACCESS_LABELS, type RemoteAccess, type RemoteAccessSystem } from './api.ts'
|
||||
import { routerAddressProblem } from './wireguard.ts'
|
||||
|
||||
/** An IPv4 network with its prefix length, as the router takes an address pool. */
|
||||
/** An IPv4 network with its prefix length, as the server takes an address pool. */
|
||||
const CIDR_PATTERN = /^(\d{1,3}\.){3}\d{1,3}\/\d{1,2}$/
|
||||
|
||||
/** A domain of IKEv2's DNS domains, as the router takes it, and the most domains. */
|
||||
/** A domain of IKEv2's DNS domains, as the server takes it, and the most domains. */
|
||||
const DOMAIN_PATTERN = /^[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?(\.[a-z0-9]([a-z0-9-]{0,61}[a-z0-9])?)*$/
|
||||
const DOMAINS_MAX = 16
|
||||
|
||||
@@ -17,9 +17,9 @@ function portProblem(text: string) {
|
||||
|
||||
/**
|
||||
* A dialog that edits the settings of one remote access system: whether it is enabled and its address pool, for
|
||||
* WireGuard wg0's address, for IKEv2 the DNS domains its clients resolve with the router's DNS, one per line, and the
|
||||
* WireGuard wg0's address, for IKEv2 the DNS domains its clients resolve with the server's DNS, one per line, and the
|
||||
* port, with OpenVPN's protocol. An enabled system needs its address. onSave sends
|
||||
* the section; the dialog closes when it succeeds and shows the router's message when it fails.
|
||||
* the section; the dialog closes when it succeeds and shows the server's message when it fails.
|
||||
*/
|
||||
export default function RemoteAccessDialog(props: {
|
||||
system: RemoteAccessSystem
|
||||
@@ -84,7 +84,7 @@ export default function RemoteAccessDialog(props: {
|
||||
autoComplete="off"
|
||||
error={addressProblem !== ''}
|
||||
helperText={addressProblem || (props.system === 'wireguard'
|
||||
? 'The router\'s address and prefix on the WireGuard network, such as 192.168.200.1/24.'
|
||||
? 'The server\'s address and prefix on the WireGuard network, such as 192.168.200.1/24.'
|
||||
: 'The IPv4 network the clients get their addresses from.')}
|
||||
onChange={(event) => setAddress(event.target.value)}
|
||||
/>
|
||||
@@ -96,7 +96,7 @@ export default function RemoteAccessDialog(props: {
|
||||
multiline
|
||||
minRows={2}
|
||||
error={domainsProblem !== ''}
|
||||
helperText={domainsProblem || 'The domains the clients resolve with the router\'s DNS, one per line.'}
|
||||
helperText={domainsProblem || 'The domains the clients resolve with the server\'s DNS, one per line.'}
|
||||
onChange={(event) => setDomains(event.target.value)}
|
||||
/>
|
||||
)}
|
||||
@@ -106,7 +106,7 @@ export default function RemoteAccessDialog(props: {
|
||||
value={port}
|
||||
autoComplete="off"
|
||||
error={portError !== ''}
|
||||
helperText={portError || 'A cloud firewall in front of the router must allow this port.'}
|
||||
helperText={portError || 'A cloud firewall in front of the server must allow this port.'}
|
||||
slotProps={{ htmlInput: { inputMode: 'numeric' } }}
|
||||
onChange={(event) => setPort(event.target.value.trim())}
|
||||
/>
|
||||
|
||||
Reference in new issue
Block a user