mirror of
https://github.com/carlospolop/hacktricks
synced 2024-11-15 01:17:36 +00:00
73 lines
3.8 KiB
Markdown
73 lines
3.8 KiB
Markdown
# 9042/9160 - Pentesting Cassandra
|
|
|
|
{% hint style="success" %}
|
|
Learn & practice AWS Hacking:<img src="/.gitbook/assets/arte.png" alt="" data-size="line">[**HackTricks Training AWS Red Team Expert (ARTE)**](https://training.hacktricks.xyz/courses/arte)<img src="/.gitbook/assets/arte.png" alt="" data-size="line">\
|
|
Learn & practice GCP Hacking: <img src="/.gitbook/assets/grte.png" alt="" data-size="line">[**HackTricks Training GCP Red Team Expert (GRTE)**<img src="/.gitbook/assets/grte.png" alt="" data-size="line">](https://training.hacktricks.xyz/courses/grte)
|
|
|
|
<details>
|
|
|
|
<summary>Support HackTricks</summary>
|
|
|
|
* Check the [**subscription plans**](https://github.com/sponsors/carlospolop)!
|
|
* **Join the** 💬 [**Discord group**](https://discord.gg/hRep4RUj7f) or the [**telegram group**](https://t.me/peass) or **follow** us on **Twitter** 🐦 [**@hacktricks\_live**](https://twitter.com/hacktricks\_live)**.**
|
|
* **Share hacking tricks by submitting PRs to the** [**HackTricks**](https://github.com/carlospolop/hacktricks) and [**HackTricks Cloud**](https://github.com/carlospolop/hacktricks-cloud) github repos.
|
|
|
|
</details>
|
|
{% endhint %}
|
|
|
|
## Basic Information
|
|
|
|
**Apache Cassandra** is 'n **hoogliks skalbare**, **hoë-prestasie** verspreide databasis wat ontwerp is om **groot hoeveelhede data** oor baie **kommoditeitsbedieners** te hanteer, wat **hoë beskikbaarheid** bied sonder 'n **enkele punt van mislukking**. Dit is 'n tipe **NoSQL-databasis**.
|
|
|
|
In verskeie gevalle mag jy vind dat Cassandra **enige geloofsbriewe** aanvaar (aangesien daar geen geconfigureer is nie) en dit kan potensieel 'n aanvaller toelaat om die databasis te **op te som**.
|
|
|
|
**Standaardpoort:** 9042,9160
|
|
```
|
|
PORT STATE SERVICE REASON
|
|
9042/tcp open cassandra-native Apache Cassandra 3.10 or later (native protocol versions 3/v3, 4/v4, 5/v5-beta)
|
|
9160/tcp open cassandra syn-ack
|
|
```
|
|
## Opname
|
|
|
|
### Handmatig
|
|
```bash
|
|
pip install cqlsh
|
|
cqlsh <IP>
|
|
#Basic info enumeration
|
|
SELECT cluster_name, thrift_version, data_center, partitioner, native_protocol_version, rack, release_version from system.local;
|
|
#Keyspace enumeration
|
|
SELECT keyspace_name FROM system.schema_keyspaces;
|
|
desc <Keyspace_name> #Decribe that DB
|
|
desc system_auth #Describe the DB called system_auth
|
|
SELECT * from system_auth.roles; #Retreive that info, can contain credential hashes
|
|
SELECT * from logdb.user_auth; #Can contain credential hashes
|
|
SELECT * from logdb.user;
|
|
SELECT * from configuration."config";
|
|
```
|
|
### Geoutomatiseerd
|
|
|
|
Daar is nie veel opsies hier nie en nmap verkry nie veel inligting nie
|
|
```bash
|
|
nmap -sV --script cassandra-info -p <PORT> <IP>
|
|
```
|
|
### [**Brute force**](../generic-methodologies-and-resources/brute-force.md#cassandra)
|
|
|
|
### **Shodan**
|
|
|
|
`port:9160 Cluster`\
|
|
`port:9042 "Ongeldige of nie-ondersteunde protokolweergawe"`
|
|
|
|
{% hint style="success" %}
|
|
Leer & oefen AWS Hacking:<img src="/.gitbook/assets/arte.png" alt="" data-size="line">[**HackTricks Training AWS Red Team Expert (ARTE)**](https://training.hacktricks.xyz/courses/arte)<img src="/.gitbook/assets/arte.png" alt="" data-size="line">\
|
|
Leer & oefen GCP Hacking: <img src="/.gitbook/assets/grte.png" alt="" data-size="line">[**HackTricks Training GCP Red Team Expert (GRTE)**<img src="/.gitbook/assets/grte.png" alt="" data-size="line">](https://training.hacktricks.xyz/courses/grte)
|
|
|
|
<details>
|
|
|
|
<summary>Support HackTricks</summary>
|
|
|
|
* Check the [**subscription plans**](https://github.com/sponsors/carlospolop)!
|
|
* **Join the** 💬 [**Discord group**](https://discord.gg/hRep4RUj7f) or the [**telegram group**](https://t.me/peass) or **follow** us on **Twitter** 🐦 [**@hacktricks\_live**](https://twitter.com/hacktricks\_live)**.**
|
|
* **Share hacking tricks by submitting PRs to the** [**HackTricks**](https://github.com/carlospolop/hacktricks) and [**HackTricks Cloud**](https://github.com/carlospolop/hacktricks-cloud) github repos.
|
|
|
|
</details>
|
|
{% endhint %}
|