Skip to content

Release - Export functionality, SQLite non-strict handling, support for the enterprise module #575

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

Open
wants to merge 181 commits into
base: release
Choose a base branch
from

Conversation

modelorona
Copy link
Collaborator

@modelorona modelorona commented Aug 5, 2025

✨ Improvements

Export functionality for SQL databases, Elasticsearch, and MongoDB:

  • You can now export tables to either CSV or Excel! Please note there might be some edge cases in data formatting, so if anything is off please let us know! 😊

Backend sorting capability for the table headers

  • Better sorting with backend.

New UI and UX

  • Use of the new clidey/ux package.

Mock data generation

  • Mock data generation for tables is out! Use this feature to generate mock data for your tables for local testing.

🐛 Bug Fixes

SQLite handling for non-strict tables

  • The SQLite plugin has been modified to support non-strict tables instead of strict tables. This might revert in the future but we think this will be easier for people at the moment.🦥

Support for the WhoDB Enterprise module

  • We've now added our enterprise offering as a submodule instead of keeping it as a separate project. Ideally nothing should break for the community as this module is available only for contributors. 🚡

Table refresh issue

  • Issue where table refresh was broken.

Scrolling bug

  • Scrolling should be improved now.

Dependabot updates

  • Updated several dependencies including driver updates, so if you run into any issues, please let us know! 🔧

Thank you to everyone who contributed to this release! 🚀
Your feedback and support are invaluable.

dependabot bot and others added 30 commits June 7, 2025 01:14
Bumps [github.com/ClickHouse/clickhouse-go/v2](https://github.com/ClickHouse/clickhouse-go) from 2.34.0 to 2.36.0.
- [Release notes](https://github.com/ClickHouse/clickhouse-go/releases)
- [Changelog](https://github.com/ClickHouse/clickhouse-go/blob/main/CHANGELOG.md)
- [Commits](ClickHouse/clickhouse-go@v2.34.0...v2.36.0)

---
updated-dependencies:
- dependency-name: github.com/ClickHouse/clickhouse-go/v2
  dependency-version: 2.36.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
Bumps the npm_and_yarn group in /frontend with 1 update: [brace-expansion](https://github.com/juliangruber/brace-expansion).


Updates `brace-expansion` from 1.1.11 to 1.1.12
- [Release notes](https://github.com/juliangruber/brace-expansion/releases)
- [Commits](juliangruber/brace-expansion@1.1.11...v1.1.12)

---
updated-dependencies:
- dependency-name: brace-expansion
  dependency-version: 1.1.12
  dependency-type: indirect
  dependency-group: npm_and_yarn
...

Signed-off-by: dependabot[bot] <[email protected]>
- Wrap identifiers in double quotes in EscapeSpecificIdentifier
- Use proper escaping for table names in COUNT queries  
- Escape table and column names in CREATE TABLE statements
- Fixes "near '-': syntax error" with Chinese characters and special chars

Fixes #502

Co-authored-by: Anguel <[email protected]>
- Add full keyboard navigation to dropdown component (Enter, Space, Arrow keys, Escape)
- Implement proper ARIA attributes (aria-expanded, aria-haspopup, aria-labelledby)
- Add focus management and visual focus indicators
- Fix button components with proper aria-labels for screen readers
- Associate labels with inputs using htmlFor attributes
- Add keyboard support for password show/hide toggles
- Make sidebar hover-only interactions keyboard accessible
- Add semantic nav elements with proper ARIA roles
- Convert table pagination divs to accessible buttons
- Add keyboard support and ARIA labels for pagination

Fixes #357

Co-authored-by: Anguel <[email protected]>
- Add ariaLabel prop to IActionButtonProps interface
- Update ActionButton component to accept and use ariaLabel prop
- Maintain backwards compatibility with default fallback
- Fixes hardcoded "Action button" aria-label issue reported by jazzberry

Co-authored-by: Anguel <[email protected]>
…ar, and table components

- Fix dropdown focus loss on blur by adding proper blur/focus handlers with timeout management
- Fix sidebar submenu focus management by improving timeout handling and escape key behavior
- Add focus management to table pagination after page changes - focus returns to current/available page button

Addresses jazzberry AI accessibility report issues:
- Dropdown focus loss on blur (Medium severity)
- Sidebar submenu focus management issue (Medium severity) 
- Table Pagination focus management after page change (Low severity)

Co-authored-by: Anguel <[email protected]>
…agement

- Change main dropdown items from tabIndex={-1} to dynamic tabIndex based on focus state
- Update default item and no-items section to tabIndex={0} for proper keyboard event handling
- Ensures focused dropdown items can receive Enter/Space keydown events for selection
- Fixes issue where keyboard navigation worked but selection didn't

Co-authored-by: Anguel <[email protected]>
fix: improve accessibility across frontend components
Bumps [github.com/vektah/gqlparser/v2](https://github.com/vektah/gqlparser) from 2.5.27 to 2.5.28.
- [Release notes](https://github.com/vektah/gqlparser/releases)
- [Commits](vektah/gqlparser@v2.5.27...v2.5.28)

---
updated-dependencies:
- dependency-name: github.com/vektah/gqlparser/v2
  dependency-version: 2.5.28
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>
… + postgres since they're not using connection urls
…lidation

- Replace improper backslash escaping with PostgreSQL libpq standard (double single quotes, double backslashes)
- Add comprehensive validation for connection parameters to prevent injection attacks
- Validate against null bytes and dangerous control characters
- Fix extra options handling in gorm plugin to avoid URL escaping for PostgreSQL
- Add parameter key validation for extra options
- Ensure all connection parameters (hostname, username, password, database) are properly escaped and validated

Follows PostgreSQL libpq connection string standards for security and compatibility.

Co-authored-by: Anguel <[email protected]>
- Fix escapeConnectionParam to escape single quotes before backslashes
- Prevents security vulnerability identified by jazzberry-ai 
- Ensures proper PostgreSQL libpq connection string escaping

Co-authored-by: Anguel <[email protected]>
fix: Add proper identifier quoting for SQLite3 non-English characters
….com/vektah/gqlparser/v2-2.5.28

build(deps): bump github.com/vektah/gqlparser/v2 from 2.5.27 to 2.5.28 in /core
…npm_and_yarn-6ea9762674

build(deps): bump brace-expansion from 1.1.11 to 1.1.12 in /frontend in the npm_and_yarn group
Bumps [gorm.io/driver/clickhouse](https://github.com/go-gorm/clickhouse) from 0.6.1 to 0.7.0.
- [Commits](go-gorm/clickhouse@v0.6.1...v0.7.0)

---
updated-dependencies:
- dependency-name: gorm.io/driver/clickhouse
  dependency-version: 0.7.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <[email protected]>
…ation

- Fix insecure TLS configuration: only enable TLS when SSLMode is not "none" or "disable"
- Fix missing ReadOnly enforcement: set ClickHouse "readonly" setting when ReadOnly="enable"
- Ensure InsecureSkipVerify is only used for "relaxed" mode, not for "none"

Co-authored-by: Anguel <[email protected]>
….com/ClickHouse/clickhouse-go/v2-2.36.0

build(deps): bump github.com/ClickHouse/clickhouse-go/v2 from 2.34.0 to 2.36.0 in /core
…o/driver/clickhouse-0.7.0

build(deps): bump gorm.io/driver/clickhouse from 0.6.1 to 0.7.0 in /core
Replace vulnerable URL format DSN construction with secure key-value format.
The previous implementation using url.QueryEscape with string concatenation
allowed injection of DSN parameters through database names and other fields.

Security improvements:
- Use key-value DSN format ("host=... user=... dbname=...") instead of URL format
- Add parameter validation for extra options to prevent arbitrary DSN injection
- Remove manual string concatenation that enabled parameter injection
- Follow the same secure pattern as MySQL plugin implementation

Fixes critical SQL injection vulnerability where malicious database names
like "mydb;sslmode=disable" could bypass security settings.

Co-authored-by: Anguel <[email protected]>
Reverted PostgreSQL connection from key-value DSN format back to URL format as requested.
Changes include:
- Use postgresql:// URL scheme instead of key-value DSN
- Maintain url.QueryEscape for basic parameter escaping
- Handle ExtraOptions via url.Values encoding
- Remove isValidPostgresParam validation function

Co-authored-by: Anguel <[email protected]>
Replace vulnerable fmt.Sprintf DSN construction with Go's url.URL struct
to prevent parameter injection attacks through malicious database names.

- Use url.URL struct for proper component-specific escaping
- Replace url.QueryEscape with appropriate URL component encoding
- Maintain postgresql:// URL format as required
- Prevent injection of connection parameters like ;sslmode=disable

Fixes reported SQL injection vulnerability where crafted database names
could inject arbitrary PostgreSQL connection parameters.

Co-authored-by: Anguel <[email protected]>
Addresses PostgreSQL hostname injection vulnerability where malicious
hostnames containing URL-reserved characters like '@' could inject
connection parameters. Added validateHostname() function to reject
hostnames with URL-reserved characters before URL construction.

Attack vector blocked: evil.com:[email protected]

Co-authored-by: Anguel <[email protected]>
Add validateDatabase() function to prevent URL-encoded forward slashes 
and path traversal patterns in database names. This blocks the reported 
attack vector %2f..%2f..%2f and other similar injection attempts.

Security improvements:
- Block URL-encoded forward slashes (%2f, %2F)
- Block literal path traversal patterns (../, ..\)
- Block other problematic URL-encoded characters
- Maintain postgresql:// URL format as required

Co-authored-by: Anguel <[email protected]>
Add validation for Windows-specific path traversal patterns (`./` and `.\`) 
to prevent directory traversal attacks on Windows systems. This addresses
the security vulnerability where database names could contain current
directory references to access unauthorized paths.

Co-authored-by: Anguel <[email protected]>
Add validation to reject database names containing backtick characters
which could be used for SQL injection attacks in PostgreSQL connections.

Co-authored-by: Anguel <[email protected]>
- Enhanced validateDatabase function to handle path separator variations
- Added validation for ..// and .// patterns that could bypass security  
- Path normalization prevents attacks using double forward slashes
- Maintains all existing path traversal protections

Co-authored-by: Anguel <[email protected]>
claude bot and others added 4 commits August 20, 2025 19:18
- Fixed CodeQL warnings about potentially unsafe quoting
- Replaced fmt.Sprintf in all log statements with structured fields
- Prevents single quotes in values from breaking log formatting
- Follows best practices for logging user-provided data

Co-authored-by: Anguel <[email protected]>
Copy link

jazzberry-ai bot commented Aug 20, 2025

Bug Report

Name Severity Example test case Description
Information Disclosure Medium Requesting /config.json exposes the contents of the build/config.json file if it exists. The fileServer function in core/src/router/file_server.go allows direct access to files within the embedded "build" directory if the file extension is known. This can lead to information disclosure if sensitive files are accidentally included in the embedded file system.

Comments? Email us.

Copy link

jazzberry-ai bot commented Aug 20, 2025

Bug Report

Name Severity Example test case Description
Command Injection in build-backend.sh High 1. Modify the Git configuration to inject malicious code into the output of git describe or git rev-parse. For example, set git config --global core.hooksPath "/tmp/evil" and create an executable /tmp/evil/describe that outputs a command to be executed. 2. Run the build-backend.sh script. 3. The injected code will be executed during the build process. The build-backend.sh script uses shell commands (git describe, git rev-parse, date) to construct the LDFLAGS variable, which is then used in the go build command. This is vulnerable to command injection because the output of these commands is not properly sanitized before being included in the LDFLAGS. An attacker could exploit this vulnerability by injecting malicious code into the Git configuration or by compromising the commands themselves.

Comments? Email us.

Copy link

jazzberry-ai bot commented Aug 21, 2025

Bug Report

Name Severity Example test case Description
Unprotected GraphQL Introspection Medium Configure GraphQL endpoint at a path other than /api/ and send an introspection query in production mode. GraphQL introspection is not properly protected in production if the endpoint is not under /api/. This can reveal the entire schema.
Unauthenticated GetDatabase Operation Medium Send a GetDatabase GraphQL query with type=sqlite3 without authentication. The GetDatabase operation is allowed without authentication for SQLite databases, which could be exploited if database details can be influenced by the user.

Comments? Email us.

Copy link

jazzberry-ai bot commented Aug 21, 2025

Bug Report

| Name | Severity | Example test case | Description |
| SQL Injection in Raw Execute | Critical | Enter SELECT * FROM users; -- in the Raw Execute query editor | The RawExecute resolver directly executes user-provided SQL queries without sanitization, leading to SQL injection. |

Comments? Email us.

Copy link

jazzberry-ai bot commented Aug 21, 2025

Bug Report

Name Severity Example test case Description
Login Profile Credentials Overwrite Bypass Medium 1. Create a valid token with a specific Id. 2. Modify the Id in the token to a non-existent login profile ID. 3. Send a request with this modified token. The AuthMiddleware in core/src/auth/auth.go overwrites the user credentials with the login profile credentials if the Id matches. However, it does not check if a matching profile was actually found during the iteration of available login profiles. This allows a user to potentially bypass authentication or authorization by manipulating the Id in their token, causing the code to use the original credentials without verification, even if the profile ID no longer exists.

Comments? Email us.

Copy link

jazzberry-ai bot commented Aug 21, 2025

Bug Report

Name Severity Example test case Description
SQL Injection in storage unit name Critical Create a storage unit named test; DROP TABLE test;. Navigate to the storage unit in the UI. The application is vulnerable to SQL injection because it doesn't sanitize the storage unit name before using it in a SQL query. This allows an attacker to execute arbitrary SQL commands, potentially leading to data loss, privilege escalation, or other malicious actions.

Comments? Email us.

Copy link

jazzberry-ai bot commented Aug 21, 2025

Bug Report

Name Severity Example test case Description
SQL Injection in Raw Execute Critical Execute SELECT * FROM users WHERE username = 'admin' OR '1'='1'; in the Raw Execute page. The Raw Execute feature allows users to execute arbitrary SQL queries without proper sanitization, leading to SQL injection vulnerabilities. An attacker can use SQL injection to bypass security checks, access sensitive data, modify data, or even execute arbitrary code on the database server.

Comments? Email us.

feat(frontend): fix up authentication issue and sidebar hide schema for non support dbs and fix update
Copy link

jazzberry-ai bot commented Aug 22, 2025

Bug Report

Name Severity Example test case Description
Missing password hashing in login cookie Critical Inspect the cookie after logging in; the password is base64 encoded and directly readable. The login function stores user credentials (including the password) in a base64 encoded cookie without any hashing. This allows an attacker who gains access to the cookie to directly extract the user's credentials.

Comments? Email us.

Copy link

jazzberry-ai bot commented Aug 22, 2025

Bug Report

Name Severity Example test case Description
Authentication Bypass for UpdateSettings Critical Call the UpdateSettings GraphQL mutation without providing any authentication token. The isAllowed function in auth.go allows unauthenticated access to the UpdateSettings operation. Although the current implementation of UpdateSettings is limited, future changes could introduce vulnerabilities if sensitive settings can be modified without authentication.
Insecure Token Validation High Attempt to reuse a previously valid token. The isTokenValid function in auth.go validates tokens against a static list. This is vulnerable to replay attacks and lacks proper token revocation mechanisms.
Credentials Override Medium Manipulate the credentials.Id in a login request to match a different profile with higher privileges. The AuthMiddleware in auth.go overrides credentials based on the profileId. This could lead to privilege escalation if an attacker can manipulate the credentials.Id.
Introspection Query Enabled in Development Low Send an introspection query to the GraphQL endpoint in development mode. The isPublicRoute function in auth.go allows introspection queries in development mode, exposing the GraphQL schema.

Comments? Email us.

Copy link

jazzberry-ai bot commented Aug 22, 2025

Bug Report

Name Severity Example test case Description
SQL Injection in GetCreateTableQuery High Provide a malicious schema name (e.g., 'public; DROP TABLE users;') when creating a table. The GetCreateTableQuery function will construct a SQL query that, when executed, will drop the users table. The GetCreateTableQuery function in /root/whodb/core/src/plugins/postgres/add.go uses fmt.Sprintf to format the table name, which includes the schema and storage unit. If the schema or storage unit are taken from user input without proper validation, a malicious user can inject SQL commands, leading to potential data loss or unauthorized access.

Comments? Email us.

Copy link

jazzberry-ai bot commented Aug 22, 2025

Bug Report

Name Severity Example test case Description
EE Component Loading Error Medium Modify ee-imports.ts to simulate a failed dynamic import of the EE module (e.g., by changing the import path to a non-existent module). Then, attempt to load a page that uses an EE component. In frontend/src/config/ee-imports.ts, if the dynamic import of the EE module fails, the code attempts to access properties on a potentially null eeModule, which can lead to runtime errors like 'Cannot read properties of null'. A null check should be added before accessing properties of eeModule.

Comments? Email us.

Copy link

jazzberry-ai bot commented Aug 22, 2025

Bug Report

Name Severity Example test case Description
Potential SQL Injection Vulnerability in GORM Plugin (MySQL/MariaDB) High 1. Configure a storage unit with a MySQL or MariaDB database.
  1. Create a table with a column (e.g., id of type INT).
  2. Attempt to update a row using the UpdateStorageUnit function with a crafted value in the whereConditions map that contains malicious SQL code. For example, set values["id"] = "1 OR 1=1; --"|The executeUpdateWithWhereMap function in core/src/plugins/gorm/update.go uses string formatting to construct the WHERE clause for update queries in MySQL/MariaDB. While the column name is escaped, the value is passed directly to the Where function without proper sanitization. This could allow an attacker to inject malicious SQL code into the query, potentially leading to data breaches or unauthorized modifications. The fix would be to properly escape/sanitize the 'value' or find a way to build the query using GORM's query builder to ensure parameters are properly escaped.

Comments? Email us.

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.

2 participants