{"record":{"id":"d5ae3d5e4cbecc92","repo":"ory/hydra","slug":"base64-loader-disabled","errorCode":null,"errorMessage":"base64 loader disabled","messagePattern":"base64 loader disabled","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"oryx/osx/file.go","lineNumber":191,"sourceCode":"\t\t\treturn nil, errors.Wrap(err, \"unable to read the file\")\n\t\t}\n\tcase \"http\", \"https\":\n\t\tif o.disableHTTPLoader {\n\t\t\treturn nil, errors.New(\"http(s) loader disabled\")\n\t\t}\n\t\tresp, err := o.hc.Get(parsed.String())\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"unable to load remote file\")\n\t\t}\n\t\tdefer resp.Body.Close()\n\n\t\tbytes, err = io.ReadAll(resp.Body)\n\t\tif err != nil {\n\t\t\treturn nil, errors.Wrap(err, \"unable to read the HTTP response body\")\n\t\t}\n\tcase \"base64\":\n\t\tif o.disableBase64Loader {\n\t\t\treturn nil, errors.New(\"base64 loader disabled\")\n\t\t}\n\n\t\tif o.disableResilientBase64Loader {\n\t\t\tbytes, err = o.base64enc.DecodeString(strings.TrimPrefix(source, \"base64://\"))\n\t\t\tif err != nil {\n\t\t\t\treturn nil, errors.Wrap(err, \"unable to base64 decode the location\")\n\t\t\t}\n\t\t\treturn bytes, nil\n\t\t}\n\n\t\tfor _, enc := range []*base64.Encoding{\n\t\t\tbase64.StdEncoding,\n\t\t\tbase64.URLEncoding,\n\t\t\tbase64.RawURLEncoding,\n\t\t\tbase64.RawStdEncoding,\n\t\t} {\n\t\t\tbytes, err = enc.DecodeString(strings.TrimPrefix(source, \"base64://\"))\n\t\t\tif err == nil {","sourceCodeStart":173,"sourceCodeEnd":209,"githubUrl":"https://github.com/ory/hydra/blob/4174065ffb052799890f7480f5360a877a67ffc1/oryx/osx/file.go#L173-L209","documentation":"Returned by readFile when the source URL scheme is base64:// but the Base64 loader was explicitly turned off via WithDisabledBase64Loader. It is a policy guard, not a decoding failure: the input itself may be valid, the loader is simply disallowed in this configuration.","triggerScenarios":"Thrown at oryx/osx/file.go:191 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Remove the WithDisabledBase64Loader option if base64 sources are expected","Provide the file content via an allowed scheme (plain path, file://, http(s)://) instead of base64://","If embedding data is required, pass the decoded bytes directly rather than as a URL source"],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"4174065ffb052799890f7480f5360a877a67ffc1","analyzedAt":"2026-09-03T14:52:41.581Z","contentChangedAt":"2026-09-03T14:52:41.581Z","schemaVersion":2},"datasetVersion":"2026-09-10T17:17:09.494Z"}