Skip to content

Conversation

@GeekMasher
Copy link
Contributor

This PR is to add support for Postgres SQL Injection sinks

Requires this PR merging first:

Pull Request checklist

All query authors

Internal query authors only

  • Autofixes generated based on these changes are valid, only needed if this PR makes significant changes to .ql, .qll, or .qhelp files. See the documentation (internal access required).
  • Changes are validated at scale (internal access required).
  • Adding a new query? Consider also adding the query to autofix.

@github-actions github-actions bot added the Rust Pull requests that update Rust code label Jan 20, 2025
geoffw0
geoffw0 previously approved these changes Jan 20, 2025
Copy link
Contributor

@geoffw0 geoffw0 left a comment

Choose a reason for hiding this comment

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

LGTM, great to have models for this SQL implementation.

@geoffw0
Copy link
Contributor

geoffw0 commented Jan 20, 2025

The test failures:

+| main.rs:11:25:11:37 | //... | Missing result: sql-sink |
...

I think these will go away if you merge main into the branch, now that the dependency #18535 is in main.

-| file://:0:0:0:0 | [summary param] 0 in lang:alloc::::crate::fmt::format | file://:0:0:0:0 | [summary] to write: ReturnValue in lang:alloc::::crate::fmt::format | MaD:14 |
...
+| file://:0:0:0:0 | [summary param] 0 in lang:alloc::::crate::fmt::format | file://:0:0:0:0 | [summary] to write: ReturnValue in lang:alloc::::crate::fmt::format | MaD:24 |
...

We're aware of this issue, it's a problem with the amount of data we're including in test outputs. I think @hvitved has an idea how to solve it.

@GeekMasher GeekMasher marked this pull request as ready for review January 20, 2025 16:10
@GeekMasher
Copy link
Contributor Author

@geoffw0 it doesn't seem to have worked. The postgres tests are passing now but the file://:0:0:0:0 tests aren't. Anything I can do from my end?

@geoffw0
Copy link
Contributor

geoffw0 commented Jan 20, 2025

Anything I can do from my end?

You can work around it by accepting the results from CI into your .expected file. That should allow us to merge this pull request.

@GeekMasher
Copy link
Contributor Author

@geoffw0 Seems that worked! Let me know if you need any other changes before merging

Copy link
Contributor

@geoffw0 geoffw0 left a comment

Choose a reason for hiding this comment

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

Nope, all LGTM.

@geoffw0 geoffw0 merged commit ab9ab0e into github:main Jan 21, 2025
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Rust Pull requests that update Rust code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants