Skip to content

$PSSenderInfo.ConnectionString shouldn't contain 'http://localhost' in SSH-based remoting sessions. #11292

Closed

Description

In WinRM-based remoting sessions, $PSSenderInfo.ConnectionString contains the actual connection URL used.

In SSH-based remoting sessions it seems to contain the fixed value http://localhost, which is misleading. Conversely, SSH connection information is not provided.

Steps to reproduce

Make sure that SSH-based remoting is enabled on a test machine running a Unix-like OS (see https://docs.microsoft.com/en-us/powershell/scripting/learn/remoting/ssh-remoting-in-powershell-core)

Invoke-Command -Hostname (hostname) { $PSSenderInfo.ConnectionString } |
  Should -Not -Be 'http://localhost'

Expected behavior

The test should pass.

An ssh:-based URL should be reported.
(Not sure whether one is actually used, but some meaningful representation of the SSH connection should be used.)

Actual behavior

The test fails, because fixed string http://localhost is always reported.

Expected 'http://localhost' to be different from the actual value, 
but got the same value.

Environment data

PowerShell Core v7.0.0-preview.6

Activity

  1. added
    Issue-Question
    on Dec 8, 2019
  2. added
    WG-Remoting
    Issue-Enhancement
    and removed
    Issue-Question
    on Dec 9, 2019
  3. added
    Up-for-Grabs
    on Dec 9, 2019
  4. microsoft-github-policy-service commented on Nov 16, 2023

    @microsoft-github-policy-service
    Contributor

    This issue has not had any activity in 6 months, if this is a bug please try to reproduce on the latest version of PowerShell and reopen a new issue and reference this issue if this is still a blocker for you.

  5. microsoft-github-policy-service commented on Nov 16, 2023

    @microsoft-github-policy-service
    Contributor

    This issue has not had any activity in 6 months, if this is a bug please try to reproduce on the latest version of PowerShell and reopen a new issue and reference this issue if this is still a blocker for you.

  6. microsoft-github-policy-service commented on Nov 16, 2023

    @microsoft-github-policy-service
    Contributor

    This issue has not had any activity in 6 months, if this is a bug please try to reproduce on the latest version of PowerShell and reopen a new issue and reference this issue if this is still a blocker for you.

  7. added
    Resolution-No Activity
    on Nov 16, 2023
  8. microsoft-github-policy-service commented on Nov 23, 2023

    @microsoft-github-policy-service
    Contributor

    This issue has been marked as "No Activity" as there has been no activity for 6 months. It has been closed for housekeeping purposes.

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

    Issue-EnhancementResolution-No ActivityUp-for-GrabsWG-Remoting

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions