Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug(workers): Create worker-led panics on invalid token #2388

Merged
merged 2 commits into from
Aug 24, 2022

Conversation

irenarindos
Copy link
Collaborator

Fix panic if invalid token is passed:

% boundary workers create worker-led -worker-generated-auth-token=bogus
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x2 addr=0x8 pc=0x10533ce24]

goroutine 1 [running]:
github.com/hashicorp/boundary/internal/cmd/commands/workerscmd.executeExtraWorkerLedActionsImpl(0x14000b6cfc0?, 0x0?, 0x10535e532?, {0x0?, 0x0?}, 0x18?, 0xc0fb18?, {0x0?, 0x14000c0fb88?, 0x1044c4f20?})
	/boundary/internal/cmd/commands/workerscmd/worker-led_funcs.go:67 +0x84

@irenarindos irenarindos requested a review from jefferai August 24, 2022 18:07
@irenarindos irenarindos changed the title Check for error before returning result bug(workers): Create worker-led panics on invalid token Aug 24, 2022
@github-actions github-actions bot added the core label Aug 24, 2022
Copy link
Collaborator

@louisruch louisruch left a comment

Choose a reason for hiding this comment

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

@irenarindos irenarindos requested a review from louisruch August 24, 2022 18:14
Copy link
Collaborator

@louisruch louisruch left a comment

Choose a reason for hiding this comment

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

LGTM

@irenarindos irenarindos merged commit b43e61c into main Aug 24, 2022
@irenarindos irenarindos deleted the irindos-fix-workerled-error branch August 24, 2022 18:43
@irenarindos irenarindos added this to the 0.10.3 milestone Aug 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants