package main

import (
    "fmt"
"github.com/contester/runlib/win32"
    "syscall"
"unsafe"
)
var PATH  string = "C:\\Program Files (x86)\\Vistara\\Agent\\utils\\1.exe"
var kernel32       = syscall.NewLazyDLL("kernel32.dll")
var procCreatePipe = kernel32.NewProc("CreatePipe")

func main() {
var hToken syscall.Handle  
    
var sI syscall.StartupInfo
       var pI syscall.ProcessInformation

      argv := syscall.StringToUTF16Ptr(PATH)
err := CreatePipe(&readhandle, &writehandle, &SA, 10485760)
fmt.Println("ERROR  ", err)

    BRESULT := win32.CreateProcessAsUser(
hToken,
        nil,
        argv,
        nil,
        nil,
        true,
        0,
        nil,
        nil,
        &sI,
        &pI)

    fmt.Printf("Return: %d\n", BRESULT)
}

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to