{"record":{"id":"a1ce749b98261bbd","repo":"shadow1ng/fscan","slug":"oracle-error","errorCode":null,"errorMessage":"oracle error","messagePattern":"oracle error","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"plugins/services/oracle_raw.go","lineNumber":1807,"sourceCode":"\t\t\treturn err\n\t\t}\n\t\tif _, err = s.getByte(); err != nil {\n\t\t\treturn err\n\t\t}\n\t\tif _, err = s.getByte(); err != nil {\n\t\t\treturn err\n\t\t}\n\t}\n\treturn nil\n}\n\nfunc (s *oracleSession) hasError() bool {\n\treturn s.summary != nil && s.summary.retCode != 0 && s.summary.retCode != 1403\n}\n\nfunc (s *oracleSession) oracleError() error {\n\tif s.summary == nil {\n\t\treturn errors.New(\"oracle error\")\n\t}\n\tmsg := string(s.summary.errorMessage)\n\tif msg == \"\" {\n\t\tmsg = fmt.Sprintf(\"ORA-%05d\", s.summary.retCode)\n\t}\n\treturn fmt.Errorf(\"%s\", msg)\n}\n\nfunc oracleRefuseError(raw []byte) error {\n\tif len(raw) < 12 {\n\t\treturn errors.New(\"oracle connection refused\")\n\t}\n\tdataLen := int(binary.BigEndian.Uint16(raw[10:12]))\n\tif len(raw) < 12+dataLen {\n\t\treturn errors.New(\"oracle connection refused\")\n\t}\n\tmsg := string(raw[12 : 12+dataLen])\n\tcode := oracleExtractCode(msg)","sourceCodeStart":1789,"sourceCodeEnd":1825,"githubUrl":"https://github.com/shadow1ng/fscan/blob/95cc12e753bf43de7004e5aef42a9ffba3934303/plugins/services/oracle_raw.go#L1789-L1825","documentation":"Fallback in oracleSession.oracleError: the session has a non-zero retCode but no summary substructure was ever populated, so neither the server message text nor the ORA code is available; a generic 'oracle error' is returned.","triggerScenarios":"Thrown at plugins/services/oracle_raw.go:1807 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Log the raw TNS packets to see why the summary was never set","Verify the TNS protocol version negotiation succeeded before the failing call","Treat as a protocol-desync: reconnect and retry the Oracle session"],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"95cc12e753bf43de7004e5aef42a9ffba3934303","analyzedAt":"2026-09-06T17:07:30.094Z","contentChangedAt":"2026-09-06T17:07:30.094Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}