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

tsh scp doesn't recognize wildcard patterns #22748

Closed
Tracked by #22933
jakule opened this issue Mar 7, 2023 · 0 comments · Fixed by #23789
Closed
Tracked by #22933

tsh scp doesn't recognize wildcard patterns #22748

jakule opened this issue Mar 7, 2023 · 0 comments · Fixed by #23789
Assignees
Labels
bug regression scp sftp Issues related to Teleport's SFTP implementation

Comments

@jakule
Copy link
Contributor

jakule commented Mar 7, 2023

Expected behavior:

tsh scp user@node:~/*" . should copy all files from the remote server.

Current behavior:

Teleport returns

ERROR REPORT:
Original Error: *errors.errorString could not access remote path "/home/user/*": file does not exist
Stack Trace:
        github.com/gravitational/teleport/lib/sshutils/sftp/sftp.go:307 github.com/gravitational/teleport/lib/sshutils/sftp.(*Config).transfer
        github.com/gravitational/teleport/lib/sshutils/sftp/sftp.go:169 github.com/gravitational/teleport/lib/sshutils/sftp.(*Config).TransferFiles
        github.com/gravitational/teleport/lib/client/client.go:1898 github.com/gravitational/teleport/lib/client.(*NodeClient).TransferFiles
        github.com/gravitational/teleport/lib/client/api.go:2031 github.com/gravitational/teleport/lib/client.(*TeleportClient).TransferFiles
        github.com/gravitational/teleport/lib/client/api.go:1933 github.com/gravitational/teleport/lib/client.(*TeleportClient).SFTP
        github.com/gravitational/teleport/tool/tsh/tsh.go:3171 main.onSCP.func1
        github.com/gravitational/teleport/lib/client/api.go:507 github.com/gravitational/teleport/lib/client.RetryWithRelogin
        github.com/gravitational/teleport/tool/tsh/tsh.go:3170 main.onSCP
        github.com/gravitational/teleport/tool/tsh/tsh.go:1129 main.Run
        github.com/gravitational/teleport/tool/tsh/tsh.go:495 main.main
        runtime/proc.go:250 runtime.main
        runtime/asm_arm64.s:1172 runtime.goexit
User Message: could not access remote path "/home/user/*": file does not exist

Bug details:

  • Teleport version 11.x and above
  • Recreation steps
  • Debug logs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug regression scp sftp Issues related to Teleport's SFTP implementation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants