none
Win32_NetworkLoginProfile objects with Description "Network login profile settings for on " RRS feed

  • Question

  • BACKGROUND:

    When I query the CimInstance Win32_NetworkLoginProfile in Powershell, I sometimes get a profile listing with nothing but a description that says: "Network login profile settings for  on ".  

    That is, in some output of queries on Win32_NetworkLoginProfile, I see one or more profiles for user " " on " ", with no Caption, Name, LastLogon, or other profile-specific properties.

    The documentation for Win32_NetworkLoginProfile says that the Win32_NetworkLoginProfile Description (read-only string) property is a textual description of the current object and is inherited from CIM_Setting (https://msdn.microsoft.com/en-us/library/aa394221(v=vs.85).aspx).

    The documentation for CIM_Setting says that its Description property is just the read-only description of the current object (https://msdn.microsoft.com/en-us/library/aa388461(v=vs.85).aspx).  A query on CIM_Setting gets the same output with the same curious description.

    A more Windows-experienced colleague has determined by testing that this output represents deleted profiles.
    It's one thing to have a single one of these no-name, no-properties objects show up.  
    But my colleague got output with no fewer than five of them.  Even just two looks to me like a case of duplicate objects!

    So...

    QUESTIONS:

    1. What exactly *are* these objects (see below sample)?
    2. Are they in fact duplicate objects if we see more than one of them?  
    3. And if they are not duplicates, then how do I see what distinguishes them?
    4. How would I delete one of these no-name objects in a script meant to delete some set of network login profiles, or should I even bother?
    5. Is this slippery no-name object something a Bad Guy could exploit, and if so how?

    SAMPLE QUERY/OUTPUT:

    PS C:\scripts> Get-CimInstance Win32_NetworkLoginProfile | where description -eq "Network login profile settings for  on " | select *


    Caption               :
    Description           : Network login profile settings for  on
    SettingID             :
    AccountExpires        :
    AuthorizationFlags    :
    BadPasswordCount      :
    CodePage              :
    Comment               :
    CountryCode           :
    Flags                 :
    FullName              :
    HomeDirectory         :
    HomeDirectoryDrive    :
    LastLogoff            :
    LastLogon             :
    LogonHours            :
    LogonServer           :
    MaximumStorage        :
    Name                  :
    NumberOfLogons        :
    Parameters            :
    PasswordAge           :
    PasswordExpires       :
    PrimaryGroupId        :
    Privileges            :
    Profile               :
    ScriptPath            :
    UnitsPerWeek          :
    UserComment           :
    UserId                :
    UserType              :
    Workstations          :
    PSComputerName        :
    CimClass              : root/cimv2:Win32_NetworkLoginProfile
    CimInstanceProperties : {Caption, Description, SettingID, AccountExpires...}
    CimSystemProperties   : Microsoft.Management.Infrastructure.CimSystemProperties

    (Note:  I'm very new at PowerShell and very rusty at Windows.)


    • Moved by Bill_Stewart Friday, January 26, 2018 2:48 PM User answered own question in first post
    Tuesday, November 28, 2017 5:19 PM

All replies

  • Not a PowerShell question.  You clearly have some issues with your systems that you need to fix.


    \_(ツ)_/

    Tuesday, November 28, 2017 6:46 PM
  • Thank you JRV.

    Assuming you're correct, which unfortunately I don't know how to check:

    1.  How would I remove those "profiles" using PowerShell?

    2.  What forum do I need to ask my non-PowerShell questions in?


    Tuesday, November 28, 2017 7:44 PM
  • If you don't know how to troubleshoot platform problems you can either contact MS support or contact a consultant.  Forums are not here to help you fix broken systems and talking you through troubleshooting your system is beyond the scope of this forum.

    I will make one suggestion but how to execute this and move forward is up to you to discover.

    Start with the registry.


    \_(ツ)_/

    Tuesday, November 28, 2017 7:55 PM
  • Thank you.  I will look in the registry.

    FWIW, I know how to troubleshoot very well, even in Windows, despite my UNIX heritage.  And my questions are not novice questions.  I did my reading homework, then checked with more knowledgeable local colleagues, then reached out to you.  Is this not how the forums work?


    Tuesday, November 28, 2017 8:18 PM
  • Then do the troubleshooting.  The issue is not a scripting issue. WMI returns what it sees.  Either filter out the bad profiles or fix the cause.  We cannot help you fix your system.


    \_(ツ)_/

    Tuesday, November 28, 2017 8:51 PM