Skip to content

Adds fail-safe for search fileless fetch payloads and updates the docs accordingly#21548

Open
msutovsky-r7 wants to merge 2 commits into
rapid7:masterfrom
msutovsky-r7:feat/payloads/fetch_payload_failsafe
Open

Adds fail-safe for search fileless fetch payloads and updates the docs accordingly#21548
msutovsky-r7 wants to merge 2 commits into
rapid7:masterfrom
msutovsky-r7:feat/payloads/fetch_payload_failsafe

Conversation

@msutovsky-r7

@msutovsky-r7 msutovsky-r7 commented Jun 7, 2026

Copy link
Copy Markdown
Contributor

The shell-search variant of fileless fetch payloads has been proved to be not fully reliable across all systems as there are systems (dockers, fresh systems with low resources, access as very low-privileged user,..) where the anonymous file handles either don't exist or existing user does not have permission to write the payload into them. This PR mentions this in fetch payload documentation and adds fail-safe mechanism, which defaults to standard fetch payload if no available file handle is found.

@msutovsky-r7 msutovsky-r7 changed the title WIP: adds fail-safe for search fileless fetch payloads and updates the docs accordingly Adds fail-safe for search fileless fetch payloads and updates the docs accordingly Jun 10, 2026
@msutovsky-r7 msutovsky-r7 marked this pull request as ready for review June 10, 2026 14:14
@dwelch-r7 dwelch-r7 added the rn-fix release notes fix label Jun 10, 2026
cmd << '; then $f'
cmd << '; FOUND=1'
cmd << '; break'
cmd << '; exit 1'

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what's the reason for this change here?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When the shell-search fails, it should exit the loop and execute the fail-safe fetch command. If there would be only break and shell-search would succeed, it would execute fail-safe regardless. To avoid too much of additional code, the shell-search exits when executed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug payload rn-fix release notes fix

Projects

Status: Todo

Development

Successfully merging this pull request may close these issues.

2 participants