fix(ui): проверять диапазон AS в каталоге BGP
This commit is contained in:
1 parent
748a3c00ad
commit
2199950681
4 files changed
+36
-2
No files matched your search
+2
-1
@@ -2,10 +2,11 @@ import { z } from "zod"
|
||||
import { vxlanServersSchema } from "@/lib/vxlan-response"
|
||||
|
||||
const counter = z.number().int().nonnegative()
|
||||
const autonomousSystem = z.number().int().min(1).max(4294967295).nullable()
|
||||
export const bgpSessionSchema = z.object({
|
||||
id: z.string().trim().min(1), serverId: z.number().int().positive(),
|
||||
serverName: z.string(), serverSite: z.string(), serverCountry: z.string(),
|
||||
name: z.string(), peerIp: z.string(), remoteAs: counter.nullable(), localAs: counter.nullable(),
|
||||
name: z.string(), peerIp: z.string(), remoteAs: autonomousSystem, localAs: autonomousSystem,
|
||||
localId: z.string(), remoteId: z.string(), state: z.string().trim().min(1), type: z.enum(["eBGP", "iBGP", "Unknown"]),
|
||||
uptime: z.string().nullable(), holdTime: counter.nullable(), keepalive: counter.nullable(),
|
||||
prefixesRx: counter.nullable(), prefixesTx: counter.nullable(), inputMessages: counter.nullable(), outputMessages: counter.nullable(),
|
||||
|
||||
Reference in new issue
Block a user