> For the complete documentation index, see [llms.txt](https://hacking-notes.jord4n.pro/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://hacking-notes.jord4n.pro/de/privesc/cron-jobs/cron-expression-calculator.md).

# Cron-Ausdrucksrechner

Suche nach einem Cron-Ausdruck wie `* * * * *`, `*/5 * * * *`, `0 0 * * *`oder `@reboot` um seinen Zeitplan und Pentest-Notizen zu lesen.

## Cron Finder

<table data-view="cards" data-full-width="true" data-search="true"><thead><tr><th>Ausdruck</th><th>Bedeutung</th><th>Typische Verwendung</th><th>Notizen überprüfen</th></tr></thead><tbody><tr><td><code>* * * * *</code></td><td>Jede Minute</td><td>Schnell wiederkehrende Aufgabe</td><td>Sehr wertvoll für PrivEsc, wenn das Skript beschreibbar ist.</td></tr><tr><td><code>*/2 * * * *</code></td><td>Alle 2 Minuten</td><td>Polling-Aufgabe</td><td>Verwende pspy, um die Ausführung zu beobachten.</td></tr><tr><td><code>*/5 * * * *</code></td><td>Alle 5 Minuten</td><td>Health Checks, Sync-Jobs</td><td>Befehls-Pfad und beschreibbare Ziele prüfen.</td></tr><tr><td><code>*/10 * * * *</code></td><td>Alle 10 Minuten</td><td>Wartungsauftrag</td><td>Auf relative Pfade und unsichere PATH-Variable achten.</td></tr><tr><td><code>*/15 * * * *</code></td><td>Alle 15 Minuten</td><td>Geplanter Sync</td><td>Logs und Skript-Eigentümerschaft prüfen.</td></tr><tr><td><code>*/30 * * * *</code></td><td>Alle 30 Minuten</td><td>Periodische Bereinigung</td><td>Löschbefehle und Platzhalter überprüfen.</td></tr><tr><td><code>0 * * * *</code></td><td>Stündlich</td><td>Stündlicher Auftrag</td><td>Auch `/etc/cron.hourly` prüfen.</td></tr><tr><td><code>30 * * * *</code></td><td>Zur Minute 30 jeder Stunde</td><td>Stündlicher Versatz</td><td>Um die halbe Stunde herum überwachen.</td></tr><tr><td><code>0 */2 * * *</code></td><td>Alle 2 Stunden</td><td>Batch-Aufgabe</td><td>Skripte in Backup- und Sync-Verzeichnissen prüfen.</td></tr><tr><td><code>0 0 * * *</code></td><td>Jeden Tag um Mitternacht</td><td>Tägliche Rotation</td><td>`/etc/cron.daily` und Backup-Skripte prüfen.</td></tr><tr><td><code>30 2 * * *</code></td><td>Jeden Tag um 02:30</td><td>Nächtliche Wartung</td><td>Häufiger Zeitpunkt für Root-Backup-Jobs.</td></tr><tr><td><code>0 6 * * *</code></td><td>Jeden Tag um 06:00</td><td>Morgenauftrag</td><td>Skripte zur Berichtserstellung und Bereinigung prüfen.</td></tr><tr><td><code>0 0 * * 0</code></td><td>Jeden Sonntag um Mitternacht</td><td>Wöchentlicher Auftrag</td><td>`/etc/cron.weekly` prüfen.</td></tr><tr><td><code>0 0 * * 1</code></td><td>Jeden Montag um Mitternacht</td><td>Wöchentlicher Auftrag</td><td>Skripte für die Geschäftswochen prüfen.</td></tr><tr><td><code>0 0 1 * *</code></td><td>Erster Tag jedes Monats</td><td>Monatsberichte</td><td>`/etc/cron.monthly` prüfen.</td></tr><tr><td><code>0 0 1 1 *</code></td><td>Jedes Jahr am 1. Januar um Mitternacht</td><td>Jahresaufgabe</td><td>Seltene Ausführung, kann aber als Root laufen.</td></tr><tr><td><code>0 9-17 * * 1-5</code></td><td>Stündlich von 09:00 bis 17:00, Montag bis Freitag</td><td>Automatisierung während der Geschäftszeiten</td><td>Von Admin-Jobs verwendete skripte des Benutzers prüfen.</td></tr><tr><td><code>*/15 9-17 * * 1-5</code></td><td>Alle 15 Minuten während der Geschäftszeiten</td><td>Polling während der Bürozeiten</td><td>Gutes Zeitfenster für pspy.</td></tr><tr><td><code>0 0,12 * * *</code></td><td>Um Mitternacht und mittags</td><td>Zweimal täglicher Auftrag</td><td>Kommagetrennte Stunden.</td></tr><tr><td><code>0 3 * * 1,3,5</code></td><td>Um 03:00 am Montag, Mittwoch und Freitag</td><td>Geplanter Batch</td><td>Übereinstimmung des Wochentags prüfen.</td></tr><tr><td><code>@reboot</code></td><td>Beim Systemstart</td><td>Startskript</td><td>Persistenz und beschreibbare Startbefehle überprüfen.</td></tr><tr><td><code>@hourly</code></td><td>Einmal pro Stunde</td><td>Stündliche Abkürzung</td><td>Entspricht `0 * * * *`.</td></tr><tr><td><code>@daily</code></td><td>Einmal pro Tag</td><td>Tägliche Abkürzung</td><td>Entspricht `0 0 * * *`.</td></tr><tr><td><code>@weekly</code></td><td>Einmal pro Woche</td><td>Wöchentliche Abkürzung</td><td>Entspricht `0 0 * * 0`.</td></tr><tr><td><code>@monthly</code></td><td>Einmal pro Monat</td><td>Monatliche Abkürzung</td><td>Entspricht `0 0 1 * *`.</td></tr><tr><td><code>@yearly</code></td><td>Einmal pro Jahr</td><td>Jährliche Abkürzung</td><td>Entspricht `0 0 1 1 *`.</td></tr></tbody></table>

## Feldrechner

```
* * * * *
| | | | |
| | | | +-- Wochentag: 0-7, Sonntag ist 0 oder 7
| | | +---- Monat: 1-12
| | +------ Tag des Monats: 1-31
| +-------- Stunde: 0-23
+---------- Minute: 0-59
```

| Operator | Bedeutung       | Beispiel                                     |
| -------- | --------------- | -------------------------------------------- |
| `*`      | Beliebiger Wert | `* * * * *` jede Minute                      |
| `,`      | Werteliste      | `0 0,12 * * *` Mitternacht und mittags       |
| `-`      | Bereich         | `0 9-17 * * *` jede Stunde von 09 bis 17 Uhr |
| `/`      | Schritt         | `*/5 * * * *` alle 5 Minuten                 |

## Aufzählungsbefehle

```bash
crontab -l
cat /etc/crontab
ls -la /etc/cron.*
find /etc/cron* -type f -exec ls -la {} \; 2>/dev/null
find /var/spool/cron -type f -exec ls -la {} \; 2>/dev/null
systemctl list-timers --all
```

## Privesc-Checkliste

| Prüfen                                              | Warum es wichtig ist                               |
| --------------------------------------------------- | -------------------------------------------------- |
| Beschreibbares Skript, das als Root ausgeführt wird | Direkter Pfad zur privilegierten Befehlsausführung |
| Relativer Befehls-Pfad                              | PATH-Hijacking kann das ausgeführte Binary steuern |
| Platzhalter in beschreibbaren Verzeichnissen        | Option-Injection gegen Werkzeuge wie `tar`         |
| Cron-Verzeichnis mit Schreibrechten für alle        | File Planting oder Skriptersetzung                 |
| Root-Job verarbeitet Benutzerdateien                | Parser- oder Befehlsinjektion über Eingabedateien  |
| Fehlende vollständige Pfade                         | Vom Umfeld abhängiges Verhalten                    |
| Logs zeigen den Zeitplan                            | Hilft bei Zeitvalidierung und Beweissicherung      |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://hacking-notes.jord4n.pro/de/privesc/cron-jobs/cron-expression-calculator.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
