Skip to content

mintty osc 52 paste over Windows ssh no response #1301

Open

Description

@theimpostor

In a mintty console on the local machine, if I print the osc 52 paste terminal sequence I see the expected response echoed to the terminal:

# In Windows 11 mintty session
# Clipboard contents are 'hello world'

$ echo -e "\e]52;;?\e\\"

$ 52;;aGVsbG8gd29ybGQ=

# response is correct
$ echo aGVsbG8gd29ybGQ= | base64 -d
hello world

However if I ssh into a linux machine I get no response written to the console:

# Same mintty session, ssh into linux

❯ echo -e "\e]52;;?\e\\"

# no response
❯

Using mintty 3.7.6, cygwin 3.5.4, Windows 11. TERM=mintty in both environments. .minttyrc contents:

Term=mintty
AllowSetSelection=true
AllowPasteSelection=true
StatusLine=yes
BellType=0

How can I debug this further?

Activity

  1. mintty commented on Nov 30, 2024

    @mintty
    Owner

    Works here. Are you sure you put something into the Windows clipboard? If you copy to some X11 clipboard on the remote side, that's not what mintty would respond.

  2. theimpostor commented on Nov 30, 2024

    @theimpostor
    Author
  3. mintty commented on Dec 1, 2024

    @mintty
    Owner

    That might explain it. You shouldn't use Windows tools in a terminal! I haven't tried but it likely blocks certain escape sequences (same with wsl.exe, that's why wslbridge exists).

  4. changed the title [-]mintty osc 52 paste over ssh no response[/-] [+]mintty osc 52 paste over Windows ssh no response[/+] on Dec 1, 2024
  5. theimpostor commented on Dec 1, 2024

    @theimpostor
    Author

    Looks like ssh.exe was the culprit - I tried with cygwin openssh and paste worked. Thanks!

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions