SqlMembershipProvider - SID or GUID

Discussion in 'ASP .Net Security' started by msnews.microsoft.com, Dec 20, 2005.

  1. Hi gurus,

    I have an aspnet web service running under windows integrated security.
    When a client calls on my web service, I have access to the authenticated
    user's SID from the (this.User.Identity as WindowsIdentity).User.Value
    property.

    I want to use the SqlMembershipProvider to store Role/User data. The
    'aspnet_Users" table defines the user's ID as guid so I can't use SID. How
    do I get a Guid from the SID?

    Thanks a lot in advance.
    msnews.microsoft.com, Dec 20, 2005
    #1
    1. Advertising

  2. I'm not sure how exactly this fits in with the membership provider, but you
    can definitely translate from an AD user's SID to their GUID using the
    TranslateName API or the DsCrackNames API. You would call either of them
    via p/invoke. You can also do an LDAP query with System.DirectoryServices.

    Joe K.

    "msnews.microsoft.com" <> wrote in message
    news:...
    > Hi gurus,
    >
    > I have an aspnet web service running under windows integrated security.
    > When a client calls on my web service, I have access to the authenticated
    > user's SID from the (this.User.Identity as WindowsIdentity).User.Value
    > property.
    >
    > I want to use the SqlMembershipProvider to store Role/User data. The
    > 'aspnet_Users" table defines the user's ID as guid so I can't use SID. How
    > do I get a Guid from the SID?
    >
    > Thanks a lot in advance.
    >
    Joe Kaplan \(MVP - ADSI\), Dec 21, 2005
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Isky

    Can convert group SID to name

    Isky, Dec 1, 2005, in forum: ASP .Net
    Replies:
    0
    Views:
    1,652
  2. picayunish

    OT: for Sid

    picayunish, Dec 13, 2003, in forum: HTML
    Replies:
    2
    Views:
    423
    picayunish
    Dec 13, 2003
  3. Nospam
    Replies:
    3
    Views:
    601
    Brian Wakem
    May 31, 2006
  4. LittlePython

    Converting binary sid's to a hex string

    LittlePython, Jun 7, 2006, in forum: Python
    Replies:
    2
    Views:
    1,209
    LittlePython
    Jun 9, 2006
  5. Replies:
    3
    Views:
    438
    Steve
    Aug 27, 2007
Loading...

Share This Page