Skip to content

fix forwarding a SSH agent in a Cygwin environment#29068

Merged
capnspacehook merged 7 commits intomasterfrom
capnspacehook/cygwin-ssh-agent
Aug 16, 2023
Merged

fix forwarding a SSH agent in a Cygwin environment#29068
capnspacehook merged 7 commits intomasterfrom
capnspacehook/cygwin-ssh-agent

Conversation

@capnspacehook
Copy link
Copy Markdown
Contributor

@capnspacehook capnspacehook commented Jul 13, 2023

Unsure of how to write a unit test this given that this bug is only reproducible on Windows with specific software installed.

Fixes #24823.

@github-actions github-actions Bot requested review from jakule and xacrimon July 13, 2023 18:14
Copy link
Copy Markdown
Contributor

@mdwn mdwn left a comment

Choose a reason for hiding this comment

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

I can't imagine what it took to debug this. Good work!

Comment thread lib/utils/agentconn/agent_windows.go
Comment thread lib/utils/agentconn/agent_windows.go Outdated
Comment thread lib/utils/agentconn/agent_windows.go Outdated
Comment thread lib/utils/agentconn/agent_windows.go
@capnspacehook capnspacehook requested a review from zmb3 July 13, 2023 20:34
Comment thread lib/utils/agentconn/agent_windows.go Outdated
Copy link
Copy Markdown
Collaborator

@r0mant r0mant left a comment

Choose a reason for hiding this comment

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

@capnspacehook Can you make a dev build and share with the customer to see if this fixes their issue?

Comment thread lib/utils/agentconn/agent_windows.go Outdated
Comment thread lib/utils/agentconn/agent_windows.go Outdated
}
psMatches := psLine.FindStringSubmatch(string(psOutput))
if len(psMatches) != 2 {
return 0, trace.Errorf("error reading Cygwin ps output")
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.

Adding more information here would be helpful. I don't think that we will be able to figure out what is wrong if someone send us only this error.

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.

Done

Comment thread lib/utils/agentconn/agent_windows.go Outdated
Comment thread lib/utils/agentconn/agent_windows.go
Comment thread lib/utils/agentconn/agent_windows.go
@xacrimon xacrimon removed their request for review July 19, 2023 17:26
@capnspacehook capnspacehook requested review from jakule and zmb3 July 19, 2023 18:05
@capnspacehook
Copy link
Copy Markdown
Contributor Author

@zmb3 @jakule can I get another review please?

@capnspacehook capnspacehook changed the title fix forwarding a SSH agent in a Cygwin env fix forwarding a SSH agent in a Cygwin environment Jul 28, 2023
@capnspacehook
Copy link
Copy Markdown
Contributor Author

Was finally able to get another build to the affected customer who confirmed the fix works!

@capnspacehook capnspacehook added this pull request to the merge queue Aug 16, 2023
Merged via the queue into master with commit b029928 Aug 16, 2023
@capnspacehook capnspacehook deleted the capnspacehook/cygwin-ssh-agent branch August 16, 2023 20:56
@public-teleport-github-review-bot
Copy link
Copy Markdown

@capnspacehook See the table below for backport results.

Branch Result
branch/v12 Create PR
branch/v13 Create PR

@zmb3
Copy link
Copy Markdown
Collaborator

zmb3 commented Aug 16, 2023

Nice job on this captain!

@capnspacehook
Copy link
Copy Markdown
Contributor Author

Thanks!

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.

Agent forwarding broken in tsh.exe

5 participants