CatalogGTFOBins

GTFO · Tool

gem

8 techniquesLinuxGTFOBinsGPL-3.0

inherit ← vi

File ReadFile WriteExecutionPrivilege EscalationLinux

This requires the name of an installed gem to be provided, e.g., `debug` is usually installed.

gem open debug
Evidence
Upstream reference
Environment
Local host
Compatibility
Linux reference. macOS compatibility has not been checked for this command and execution context.
Context
sudo
Native
inherit, from:vi

inherit ← vi

File ReadFile WriteExecutionLinux

This requires the name of an installed gem to be provided, e.g., `debug` is usually installed.

gem open debug
Evidence
Upstream reference
Environment
Local host
Compatibility
Linux reference. macOS compatibility has not been checked for this command and execution context.
Context
unprivileged
Native
inherit, from:vi

inherit ← ruby

File DownloadFile ReadFile WriteLibrary LoadReverse/Bind ShellExecutionFile UploadPrivilege EscalationLinux
gem build /path/to/script.rb
Evidence
Upstream reference
Environment
Local host
Compatibility
Linux reference. macOS compatibility has not been checked for this command and execution context.
Context
sudo
Native
inherit, from:ruby

inherit ← ruby

File DownloadFile ReadFile WriteLibrary LoadReverse/Bind ShellExecutionFile UploadLinux
gem build /path/to/script.rb
Evidence
Upstream reference
Environment
Local host
Compatibility
Linux reference. macOS compatibility has not been checked for this command and execution context.
Context
unprivileged
Native
inherit, from:ruby

inherit ← ruby

File DownloadFile ReadFile WriteLibrary LoadReverse/Bind ShellExecutionFile UploadPrivilege EscalationLinux
gem install --file /path/to/script.rb
Evidence
Upstream reference
Environment
Local host
Compatibility
Linux reference. macOS compatibility has not been checked for this command and execution context.
Context
sudo
Native
inherit, from:ruby

inherit ← ruby

File DownloadFile ReadFile WriteLibrary LoadReverse/Bind ShellExecutionFile UploadLinux
gem install --file /path/to/script.rb
Evidence
Upstream reference
Environment
Local host
Compatibility
Linux reference. macOS compatibility has not been checked for this command and execution context.
Context
unprivileged
Native
inherit, from:ruby

shell

ExecutionPrivilege EscalationLinux

This requires the name of an installed gem to be provided, e.g., `debug` is usually installed.

gem open -e '/bin/sh -s' debug
Evidence
Upstream reference
Environment
Local host
Compatibility
Linux reference. macOS compatibility has not been checked for this command and execution context.
Context
sudo
Native
shell
MITRE
T1059

shell

ExecutionLinux

This requires the name of an installed gem to be provided, e.g., `debug` is usually installed.

gem open -e '/bin/sh -s' debug
Evidence
Upstream reference
Environment
Local host
Compatibility
Linux reference. macOS compatibility has not been checked for this command and execution context.
Context
unprivileged
Native
shell
MITRE
T1059