{"record":{"id":"e52a0e2d82bf3a1c","repo":"XTLS/Xray-core","slug":"mldsa65seed-and-privatekey-can-not-be-the-same","errorCode":null,"errorMessage":"\"mldsa65Seed\" and \"privateKey\" can not be the same value: ","messagePattern":"\"mldsa65Seed\" and \"privateKey\" can not be the same value: ","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"infra/conf/transport_security.go","lineNumber":156,"sourceCode":"\t\tconfig.ShortIds = make([][]byte, len(c.ShortIds))\n\t\tfor i, s := range c.ShortIds {\n\t\t\tif len(s) > 16 {\n\t\t\t\treturn nil, errors.New(`too long \"shortIds[`, i, `]\": `, s)\n\t\t\t}\n\t\t\tconfig.ShortIds[i] = make([]byte, 8)\n\t\t\tif _, err = hex.Decode(config.ShortIds[i], []byte(s)); err != nil {\n\t\t\t\treturn nil, errors.New(`invalid \"shortIds[`, i, `]\": `, s)\n\t\t\t}\n\t\t}\n\t\tconfig.Dest = s\n\t\tconfig.Type = c.Type\n\t\tconfig.Xver = c.Xver\n\t\tconfig.ServerNames = c.ServerNames\n\t\tconfig.MaxTimeDiff = c.MaxTimeDiff\n\n\t\tif c.Mldsa65Seed != \"\" {\n\t\t\tif c.Mldsa65Seed == c.PrivateKey {\n\t\t\t\treturn nil, errors.New(`\"mldsa65Seed\" and \"privateKey\" can not be the same value: `, c.Mldsa65Seed)\n\t\t\t}\n\t\t\tif config.Mldsa65Seed, err = base64.RawURLEncoding.DecodeString(c.Mldsa65Seed); err != nil || len(config.Mldsa65Seed) != 32 {\n\t\t\t\treturn nil, errors.New(`invalid \"mldsa65Seed\": `, c.Mldsa65Seed)\n\t\t\t}\n\t\t}\n\n\t\tfor _, sn := range config.ServerNames {\n\t\t\tsn = strings.ToLower(sn)\n\t\t\tif strings.HasSuffix(sn, \".ru\") || strings.HasSuffix(sn, \".ir\") || strings.HasSuffix(sn, \".cn\") ||\n\t\t\t\tstrings.Contains(sn, \"apple\") || strings.Contains(sn, \"icloud\") || strings.Contains(sn, \"microsoft\") {\n\t\t\t\terrors.LogWarning(context.Background(), `REALITY: Choosing \"`, sn, `\" as the target will increase the likelihood of your server's IP being blocked by the GFW`)\n\t\t\t}\n\t\t}\n\n\t\tconfig.LimitFallbackUpload = new(reality.LimitFallback)\n\t\tconfig.LimitFallbackUpload.AfterBytes = c.LimitFallbackUpload.AfterBytes\n\t\tconfig.LimitFallbackUpload.BytesPerSec = c.LimitFallbackUpload.BytesPerSec\n\t\tconfig.LimitFallbackUpload.BurstBytesPerSec = c.LimitFallbackUpload.BurstBytesPerSec","sourceCodeStart":138,"sourceCodeEnd":174,"githubUrl":"https://github.com/XTLS/Xray-core/blob/7d214f8b094f75322fa3990f8aadad1c912f24f5/infra/conf/transport_security.go#L138-L174","documentation":"Error \"\"mldsa65Seed\" and \"privateKey\" can not be the same value: \" thrown in XTLS/Xray-core.","triggerScenarios":"Thrown at infra/conf/transport_security.go:156 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":"7d214f8b094f75322fa3990f8aadad1c912f24f5","analyzedAt":"2026-08-15T14:26:24.325Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}