CWE-619

Dangling Database Cursor ('Cursor Injection')

Medium

Description

If a database cursor is not closed properly, then it could become accessible to other users while retaining the same privileges that were originally assigned, leaving the cursor "dangling."

Potential Impact

How to Fix

Implementation

Close cursors immediately after access to them is complete. Ensure that you close cursors if exceptions occur.

Related Weaknesses

References

View on MITRE CWE Database →

Need Help Fixing This Vulnerability?

Our security experts can help you identify and remediate CWE-619 vulnerabilities in your codebase.

Get Security Assessment