Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: fix theoretical sql injection #1238

Merged
merged 1 commit into from
Jan 23, 2025
Merged

Conversation

MichaelMraka
Copy link
Contributor

Secure Coding Practices Checklist GitHub Link

Secure Coding Checklist

  • Input Validation
  • Output Encoding
  • Authentication and Password Management
  • Session Management
  • Access Control
  • Cryptographic Practices
  • Error Handling and Logging
  • Data Protection
  • Communication Security
  • System Configuration
  • Database Security
  • File Management
  • Memory Management
  • General Coding Practices

Copy link

jira-linking bot commented Jan 22, 2025

Commits missing Jira IDs:
2abc5d2

Copy link
Member

@psegedy psegedy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fails with

>       cur.execute("select id from repo where url = %s", repository[1].repo_url)
E       TypeError: not all arguments converted during string formatting

I think psycopg expects parameters as tuple, shouldn't it be something like

cur.execute("select id from repo where url = %s", (repository[1].repo_url,))

@codecov-commenter
Copy link

codecov-commenter commented Jan 22, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 62.07%. Comparing base (5a56460) to head (2abc5d2).
Report is 183 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1238      +/-   ##
==========================================
- Coverage   62.98%   62.07%   -0.92%     
==========================================
  Files          70       90      +20     
  Lines        6800     6826      +26     
==========================================
- Hits         4283     4237      -46     
- Misses       2517     2580      +63     
- Partials        0        9       +9     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@psegedy psegedy merged commit 1aeb122 into RedHatInsights:master Jan 23, 2025
7 of 9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants