{"record":{"id":"3a445f1c754a4e93","repo":"txthinking/brook","slug":"it-is-recommended-to-use-brook-link-and-specify","errorCode":null,"errorMessage":"It is recommended to use brook link and specify --udpoverstream","messagePattern":"It is recommended to use brook link and specify --udpoverstream","errorType":"error_code","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cli/brook/main.go","lineNumber":1362,"sourceCode":"\t\t\t\t\treturn nil\n\t\t\t\t}\n\t\t\t\tif c.String(\"from\") == \"\" || c.String(\"to\") == \"\" || (c.String(\"server\") == \"\" && c.String(\"link\") == \"\") {\n\t\t\t\t\treturn cli.ShowSubcommandHelp(c)\n\t\t\t\t}\n\t\t\t\tvar link = \"\"\n\t\t\t\tif c.String(\"server\") != \"\" {\n\t\t\t\t\tkind := \"server\"\n\t\t\t\t\tif strings.HasPrefix(c.String(\"server\"), \"ws://\") {\n\t\t\t\t\t\tkind = \"wsserver\"\n\t\t\t\t\t}\n\t\t\t\t\tif strings.HasPrefix(c.String(\"server\"), \"wss://\") {\n\t\t\t\t\t\tkind = \"wssserver\"\n\t\t\t\t\t}\n\t\t\t\t\tif strings.HasPrefix(c.String(\"server\"), \"quic://\") {\n\t\t\t\t\t\tkind = \"quicserver\"\n\t\t\t\t\t}\n\t\t\t\t\tif kind == \"quicserver\" {\n\t\t\t\t\t\treturn errors.New(\"It is recommended to use brook link and specify --udpoverstream\")\n\t\t\t\t\t}\n\t\t\t\t\tv := url.Values{}\n\t\t\t\t\tv.Set(\"password\", c.String(\"password\"))\n\t\t\t\t\tlink = brook.Link(kind, c.String(\"server\"), v)\n\t\t\t\t}\n\t\t\t\tif c.String(\"link\") != \"\" {\n\t\t\t\t\tlink = c.String(\"link\")\n\t\t\t\t}\n\t\t\t\tkind, _, v, err := brook.ParseLink(link)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn err\n\t\t\t\t}\n\t\t\t\tif s := v.Get(\"clientHKDFInfo\"); s != \"\" {\n\t\t\t\t\tbrook.ClientHKDFInfo = []byte(s)\n\t\t\t\t}\n\t\t\t\tif s := v.Get(\"serverHKDFInfo\"); s != \"\" {\n\t\t\t\t\tbrook.ServerHKDFInfo = []byte(s)\n\t\t\t\t}","sourceCodeStart":1344,"sourceCodeEnd":1380,"githubUrl":"https://github.com/txthinking/brook/blob/5cd13ef3b1fb574e88ebf2c1b5d95f2ebe1342c8/cli/brook/main.go#L1344-L1380","documentation":"Not a runtime failure but an intentional configuration rejection in the connect subcommand: a plain quic:// server address was supplied without --udpoverstream, and this build/policy requires QUIC servers to run UDP-over-stream, so the command aborts before dialing. It fires whenever kind == \"quicserver\" and the user did not set --udpoverstream (the recommended alternative is passing a full brook link that specifies it).","triggerScenarios":"Thrown at cli/brook/main.go:1362 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Re-run using a brook link that includes --udpoverstream, e.g. pass --link instead of --server","Add --udpoverstream to the connect command alongside the quic:// server","If UDP-over-stream is not required, use a non-QUIC server kind (ws://, wss://, or plain server)"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"5cd13ef3b1fb574e88ebf2c1b5d95f2ebe1342c8","analyzedAt":"2026-09-06T04:35:00.432Z","contentChangedAt":"2026-09-06T04:35:00.432Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}