Select the types of activity you want to include in your feed.
Enforce minimum port 1024
Disallow privileged ports by updating schemas, pkl defs, server handlers, and UI validation. Applied to API lexicons, cf-sandbox endpoints, and ExposePortModal.
···2929 "type": "integer",
3030 "description": "The port number to expose.",
3131 "maximum": 65535,
3232- "minimum": 1
3232+ "minimum": 1024
3333 },
3434 "description": {
3535 "type": "string",
+1-1
apps/api/lexicons/sandbox/unexposePort.json
···2929 "type": "integer",
3030 "description": "The port number to unexpose.",
3131 "maximum": 65535,
3232- "minimum": 1
3232+ "minimum": 1024
3333 }
3434 }
3535 }
+1-1
apps/api/pkl/defs/port/defs.pkl
···1010 ["port"] = new IntegerType {
1111 type = "integer"
1212 description = "The port number."
1313- minimum = 1
1313+ minimum = 1024
1414 maximum = 65535
1515 }
1616 ["description"] = new StringType {
+2-2
apps/api/pkl/defs/sandbox/defs.pkl
···6565 type = "array"
6666 items = new IntegerType {
6767 type = "integer"
6868- minimum = 1
6868+ minimum = 1024
6969 maximum = 65535
7070 }
7171 maxLength = 100
···159159 type = "array"
160160 items = new IntegerType {
161161 type = "integer"
162162- minimum = 1
162162+ minimum = 1024
163163 maximum = 65535
164164 }
165165 maxLength = 100
+1-1
apps/api/pkl/defs/sandbox/exposePort.pkl
···2525 ["port"] = new IntegerType {
2626 type = "integer"
2727 description = "The port number to expose."
2828- minimum = 1
2828+ minimum = 1024
2929 maximum = 65535
3030 }
3131 ["description"] = new StringType {
+1-1
apps/api/pkl/defs/sandbox/unexposePort.pkl
···2525 ["port"] = new IntegerType {
2626 type = "integer"
2727 description = "The port number to unexpose."
2828- minimum = 1
2828+ minimum = 1024
2929 maximum = 65535
3030 }
3131 }
···99 port: z.coerce
1010 .number({ error: "Port is required" })
1111 .int()
1212- .min(1, "Port must be between 1 and 65535")
1313- .max(65535, "Port must be between 1 and 65535"),
1212+ .min(1024, "Port must be between 1024 and 65535")
1313+ .max(65535, "Port must be between 1024 and 65535"),
1414 description: z.string(),
1515});
1616