{"record":{"id":"8b0224e69ac445a2","repo":"micro/go-micro","slug":"err-mdns-support-for-dns-requests-with-high-tru","errorCode":null,"errorMessage":"[ERR] mdns: support for DNS requests with high truncated bit not implemented: %v","messagePattern":"\\[ERR\\] mdns: support for DNS requests with high truncated bit not implemented: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"internal/util/mdns/server.go","lineNumber":242,"sourceCode":"\t\t// over multicast).  Multicast DNS messages received with an OPCODE other\n\t\t// than zero MUST be silently ignored.\"  Note: OpcodeQuery == 0\n\t\treturn fmt.Errorf(\"mdns: received query with non-zero Opcode %v: %v\", query.Opcode, *query)\n\t}\n\tif query.Rcode != 0 {\n\t\t// \"In both multicast query and multicast response messages, the Response\n\t\t// Code MUST be zero on transmission.  Multicast DNS messages received with\n\t\t// non-zero Response Codes MUST be silently ignored.\"\n\t\treturn fmt.Errorf(\"mdns: received query with non-zero Rcode %v: %v\", query.Rcode, *query)\n\t}\n\n\t// TODO(reddaly): Handle \"TC (Truncated) Bit\":\n\t//    In query messages, if the TC bit is set, it means that additional\n\t//    Known-Answer records may be following shortly.  A responder SHOULD\n\t//    record this fact, and wait for those additional Known-Answer records,\n\t//    before deciding whether to respond.  If the TC bit is clear, it means\n\t//    that the querying host has no additional Known Answers.\n\tif query.Truncated {\n\t\treturn fmt.Errorf(\"[ERR] mdns: support for DNS requests with high truncated bit not implemented: %v\", *query)\n\t}\n\n\tvar unicastAnswer, multicastAnswer []dns.RR\n\n\t// Handle each question\n\tfor _, q := range query.Question {\n\t\tmrecs, urecs := s.handleQuestion(q)\n\t\tmulticastAnswer = append(multicastAnswer, mrecs...)\n\t\tunicastAnswer = append(unicastAnswer, urecs...)\n\t}\n\n\t// See section 18 of RFC 6762 for rules about DNS headers.\n\tresp := func(unicast bool) *dns.Msg {\n\t\t// 18.1: ID (Query Identifier)\n\t\t// 0 for multicast response, query.Id for unicast response\n\t\tid := uint16(0)\n\t\tif unicast {\n\t\t\tid = query.Id","sourceCodeStart":224,"sourceCodeEnd":260,"githubUrl":"https://github.com/micro/go-micro/blob/24529f140421a11a33b6999ab7944f2021cfd69c/internal/util/mdns/server.go#L224-L260","documentation":"When a query has the TC (truncation) bit set, the sender indicates more Known-Answer records will follow and the responder should wait before answering. This implementation does not support that; it returns an error instead of partially handling the truncated message.","triggerScenarios":"parsePacket receiving a query larger than one packet with query.Truncated == true, typically when a client packs many questions/known-answers exceeding the UDP payload.","commonSituations":"Clients with very large service lists issuing oversized mDNS queries; networks with small MTU forcing truncation; other mDNS implementations with large known-answer lists.","solutions":["Reduce the number of questions/known-answers per query on the client side","Await follow-up packets — but note this server won't aggregate them; send separate smaller queries instead","Upgrade or patch the mDNS implementation to buffer truncated queries"],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":"if err := srv.handleQuery(query, from); err != nil {\n    if strings.Contains(err.Error(), \"truncated bit not implemented\") {\n        // wait briefly for follow-up packets, or drop; do not fail the server\n        log.Debugf(\"dropped truncated query from %v\", from)\n        return nil\n    }\n    return err\n}","preventionTips":["Keep mDNS queries small (few questions/known-answers per packet)","Avoid clients that emit oversized multi-packet queries on this network","Track upstream support for TC-bit aggregation before relying on large queries"],"tags":["mdns","dns","unimplemented"],"backgroundTag":"dns-truncated-not-implemented","analyzedSha":"24529f140421a11a33b6999ab7944f2021cfd69c","analyzedAt":"2026-09-01T02:52:24.923Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-08T05:18:18.240Z"}