Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Starting a service with standard (no admin) user rights

Starting a service with standard (no admin) user rights

Scheduled Pinned Locked Moved C / C++ / MFC
question
4 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    Stefan Spenz
    wrote on last edited by
    #1

    Hi, using Vista with a standard user (no admin), I cannot start a service using Win32 with OpenSCManager, OpenService etc. How can I modify the user rights temporary to admin rights, so the functions work properly? Regards, Stefan

    _ H 2 Replies Last reply
    0
    • S Stefan Spenz

      Hi, using Vista with a standard user (no admin), I cannot start a service using Win32 with OpenSCManager, OpenService etc. How can I modify the user rights temporary to admin rights, so the functions work properly? Regards, Stefan

      _ Offline
      _ Offline
      _Superman_
      wrote on last edited by
      #2

      You can use the CreateProcessAsUser API to run a process admin and use OpenSCManager from within that process.

      «_Superman_»

      S 1 Reply Last reply
      0
      • _ _Superman_

        You can use the CreateProcessAsUser API to run a process admin and use OpenSCManager from within that process.

        «_Superman_»

        S Offline
        S Offline
        Stefan Spenz
        wrote on last edited by
        #3

        Could you provide me with a quick example? Sorry I'm not that into services and user access rights

        1 Reply Last reply
        0
        • S Stefan Spenz

          Hi, using Vista with a standard user (no admin), I cannot start a service using Win32 with OpenSCManager, OpenService etc. How can I modify the user rights temporary to admin rights, so the functions work properly? Regards, Stefan

          H Offline
          H Offline
          Hamid Taebi
          wrote on last edited by
          #4

          Running Process without Security Warning in Internet Explorer 7[^].

          Of one Essence is the human race thus has Creation put the base One Limb impacted is sufficient For all Others to feel the Mace (Saadi )

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups