grc - Privilege Escalation
ID: privesc-grc
Severity: high
Author: daffainfo
Tags: code,linux,grc,privesc,local
Description
Section titled “Description”grc is a command-line utility that enhances the output of other commands with color and style. It is commonly used to improve the readability of command output by adding color highlighting and formatting. grc can be configured to work with various commands and is often used to make log files and command output easier to interpret.
YAML Source
Section titled “YAML Source”id: privesc-grc
info: name: grc - Privilege Escalation author: daffainfo severity: high description: | grc is a command-line utility that enhances the output of other commands with color and style. It is commonly used to improve the readability of command output by adding color highlighting and formatting. grc can be configured to work with various commands and is often used to make log files and command output easier to interpret. reference: - https://gtfobins.github.io/gtfobins/grc/ metadata: verified: true max-request: 3 tags: code,linux,grc,privesc,local
self-contained: truecode: - engine: - sh - bash source: | whoami
- engine: - sh - bash source: | grc --pty whoami
- engine: - sh - bash source: | sudo grc --pty whoami
matchers-condition: and matchers: - type: word part: code_1_response words: - "root" negative: true
- type: dsl dsl: - 'contains(code_2_response, "root")' - 'contains(code_3_response, "root")' condition: or# digest: 4b0a00483046022100aa0da4fa9606716a03728fdacb92e4385d04bc0491115d887e3292bfea3835f10221009606e7d51f737fcd360e1ba6df9e915c3660f422919f7c9c97cf7b8fb7d19e40:922c64590222798bb761d5b6d8e72950Guide to check the vulnerabilities
Section titled “Guide to check the vulnerabilities”This template is used to detect vulnerabilities in web applications. It can be used with the Nuclei tool to scan for specific patterns or behaviors.
$ nuclei -u "URL" -t "code/privilege-escalation/linux/binary/privesc-grc.yaml"