AdjustTokenPrivileges fails

putra

New Member
I am unable to impersonate the user to Administrator on Vista machine, I see that the credentails are being correctly passed to my executable.
I see that the AdjustTokenPrivileges fails with ERROR code 1300, the below is the error stach after AdjustTokenPrivileges fails is called

AdjustTokenPrivileges failed for SE_TCB_NAME
RunAs ERROR: error code = 514, message = Not all privileges or groups referenced are assigned to the caller.
RunAs ERROR: error code = 514, message = Not all privileges or groups referenced are assigned to the caller.
LoadUserProfile failed
ERROR: error code = 522, message = A required privilege is not held by the client.
RunAs ERROR: error code = 522, message = A required privilege is not held by the client.
CreateEnvironmentBlock failed


Please let me know if there are known issues with AdjustTokenPrevilages on Vista, the same code works on Windows 7 and XP
 

My Computer

My Computer

System One

  • Manufacturer/Model
    HP-Pavilion m9280.uk-a
    CPU
    2.30 gigahertz AMD Phenom 9600 Quad-Core
    Motherboard
    ASUSTek Computer INC. NARRA3 3.02
    Memory
    3582 Megabytes Usable Installed Memory (4 Gig)
    Graphics Card(s)
    ASUS NVIDIA Geforce GTS450
    Sound Card
    Realtek High Definition 7.1 Audio (HP drivers)
    Monitor(s) Displays
    HP w2408 24.0" (Dual monitor)
    Screen Resolution
    1920 * 1200, 1920 * 1200
    Hard Drives
    3*500 Gigabytes Usable Hard Drive Capacity
    Plus 2x USB (160Gig each) external HDD
    BluRay & DVD Weiters
    HL-DT-ST BD-RE GGW-H20L SCSI CdRom (Bluray RW) Device
    AlViDrv BDDVDROM SCSI CdRom (Blueray) Device
    TSSTcorp CDDVDW TS-H653N SCSI CdRom
    Internet Speed
    40 Meg
Back
Top