Skip to content

Should Get-Item Cert:\ return an object #6258

Closed

Description

Calling Get-Item on the root of a provider should return an item.

it does for these commands:

Get-Item C:\
Get-Item HKLM:\

But not for this command

Get-Item Cert:\

Behaviour is the same as it was in 5.1. I suspect it has always been this way.

I am only creating this issue because I corrected a test in #6256 for #6245 that was malformed. It then started to fail on the assumption that Get-Item would give it an object in that case. I adjusted the test to no longer check the Cert:\ path.

Steps to reproduce

Get-Item Cert:\
Get-Item C:\
Get-Item HKLM:\

Expected behavior


Name : CurrentUser

Name : LocalMachine

    Directory:


Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d--hs-        2/25/2018   5:48 PM                C:\

    Hive:


Name                           Property
----                           --------
HKEY_LOCAL_MACHINE

Actual behavior

    Directory:


Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d--hs-        2/25/2018   5:48 PM                C:\

    Hive:


Name                           Property
----                           --------
HKEY_LOCAL_MACHINE

Environment data

> $PSVersionTable
Name                           Value
----                           -----
PSVersion                      6.0.0
PSEdition                      Core
GitCommitId                    v6.0.0
OS                             Microsoft Windows 10.0.16299
Platform                       Win32NT
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1
WSManStackVersion              3.0

Activity

  1. added
    Issue-Discussionthe issue may not have a clear classification yet. The issue may generate an RFC or may be reclassif
    WG-Engine-Providersbuilt-in PowerShell providers such as FileSystem, Certificates, Registry, etc.
    on Feb 28, 2018
  2. 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.

  3. 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.

  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 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-Discussionthe issue may not have a clear classification yet. The issue may generate an RFC or may be reclassifResolution-No ActivityIssue has had no activity for 6 months or moreWG-Engine-Providersbuilt-in PowerShell providers such as FileSystem, Certificates, Registry, etc.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions