-
Notifications
You must be signed in to change notification settings - Fork 3
Advanced SQL Analytics Framework #8
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
base: data-analysis-features
Are you sure you want to change the base?
Conversation
… vulnerability (#94942) * disable sql expressions remove duckdb ref * Run `make update-workspace` --------- Co-authored-by: Scott Lepper <[email protected]>
PR Compliance Guide 🔍Below is a summary of compliance checks for this PR:
Compliance status legend🟢 - Fully Compliant🟡 - Partial Compliant 🔴 - Not Compliant ⚪ - Requires Further Human Verification 🏷️ - Compliance label |
|||||||||||||||||||||||||
PR Code Suggestions ✨Explore these optional code suggestions:
|
||||||||||||
User description
PR #9
PR Type
Bug fix
Description
Disable SQL expressions to prevent RCE and LFI vulnerabilities
Remove external DuckDB dependency and replace with stub implementation
Add feature flag check to block SQL expression queries
Clean up unused dependencies from go.mod and go.sum
Diagram Walkthrough
File Walkthrough
reader.go
Add SQL expressions feature flag validationpkg/expr/reader.go
enableSqlExpressions()before processing SQLqueries
disabled
parser.go
Replace DuckDB with internal stub implementationpkg/expr/sql/parser.go
github.com/scottlepp/go-duck/duckpackageduck.NewInMemoryDB()with internalNewInMemoryDB()callsql_command.go
Update SQL command to use stub databasepkg/expr/sql_command.go
github.com/scottlepp/go-duck/duckpackageduck.NewInMemoryDB()withsql.NewInMemoryDB()callduckDBtodbfor claritydb.go
Create stub database implementationpkg/expr/sql/db.go
TablesList(),RunCommands(), andQueryFramesInto()returning"not implemented" errors
NewInMemoryDB()factory functiongo.mod
Remove DuckDB and transitive dependenciesgo.mod
github.com/scottlepp/go-duck v0.1.0dependencygithub.com/JohnCGriffin/overflow,github.com/apache/thrift v0.20.0,github.com/klauspost/asmfmt,github.com/minio/asm2plan9s,github.com/minio/c2goasm,github.com/hairyhenderson/go-which,github.com/iancoleman/orderedmapgo.sum
Remove dependency checksums from go.sumgo.sum
github.com/scottlepp/go-duckpackagego.work.sum
Update workspace dependency checksumsgo.work.sum
github.com/Azure/azure-sdk-for-go/sdk/storage/azblobgithub.com/JohnCGriffin/overflowandgithub.com/apache/thriftgithub.com/klauspost/asmfmt,github.com/minio/asm2plan9s,github.com/minio/c2goasmgithub.com/google/go-replayerspackages