{"record":{"id":"24378d227b11c362","repo":"goharbor/harbor","slug":"network-port-should-be-less-than-65535","errorCode":null,"errorMessage":"network port should be less than 65535","messagePattern":"network port should be less than 65535","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/lib/config/metadata/type.go","lineNumber":117,"sourceCode":"\treturn parseInt(str)\n}\n\n// PortType ...\ntype PortType struct {\n\tIntType\n}\n\nfunc (t *PortType) validate(str string) error {\n\tval, err := strconv.Atoi(str)\n\tif err != nil {\n\t\treturn err\n\t}\n\tif val < 0 {\n\t\treturn fmt.Errorf(\"network port should be greater than 0\")\n\t}\n\n\tif val > 65535 {\n\t\treturn fmt.Errorf(\"network port should be less than 65535\")\n\t}\n\n\treturn err\n}\n\n// LdapScopeType - The LDAP scope is a int type, but its is limit to 0, 1, 2\ntype LdapScopeType struct {\n\tIntType\n}\n\n// validate - Verify the range is limited\nfunc (t *LdapScopeType) validate(str string) error {\n\tif str == \"0\" || str == \"1\" || str == \"2\" {\n\t\treturn nil\n\t}\n\treturn fmt.Errorf(\"invalid scope, should be %d, %d or %d\",\n\t\tcommon.LDAPScopeBase,\n\t\tcommon.LDAPScopeOnelevel,","sourceCodeStart":99,"sourceCodeEnd":135,"githubUrl":"https://github.com/goharbor/harbor/blob/7b2fd08cc568955cca339afeefab27372840d936/src/lib/config/metadata/type.go#L99-L135","documentation":"Error \"network port should be less than 65535\" thrown in goharbor/harbor.","triggerScenarios":"Thrown at src/lib/config/metadata/type.go:117 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"7b2fd08cc568955cca339afeefab27372840d936","analyzedAt":"2026-08-16T00:00:10.961Z","schemaVersion":2},"datasetVersion":"2026-08-16T03:17:38.424Z"}