{
  "WorkItem": {
    "AffectedComponent": {
      "Name": "",
      "DisplayName": ""
    },
    "ClosedComment": "",
    "ClosedDate": null,
    "CommentCount": 0,
    "Custom": null,
    "Description": "As I understand it, UAC elevation in Vista and Win 7 can be done by the application through its manifest file, or programmatically. \n \n Setting the UAC level in the manifest file can be done with a simple parameter change to one of the attributes: \n \n \n<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>\n<assembly xmlns=\"urn:schemas-microsoft-com:asm.v1\" manifestVersion=\"1.0\">\n   <assemblyIdentity version=\"1.0.0.0\"  name=\"MyFancyApp\" type=\"win32\"/>\n      <trustInfo xmlns=\"urn:schemas-microsoft-com:asm.v3\">\n      <security>\n         <requestedPrivileges>\n            <requestedExecutionLevel level=\"requireAdministrator\"/>\n         </requestedPrivileges>\n      </security>\n   </trustInfo>\n</assembly>\n \n \nThe manifest file can be exposed (file MyFancyApp.exe.manifest) or it can be embedded in the application exe.  I believe that for security purposes, the manifest must be embedded for an admin rights request to be granted.\n \nThe other way is to request it programmatically:\n \n  ProcessStartInfo proc = new ProcessStartInfo();                 proc.UseShellExecute = true;                 proc.WorkingDirectory = Directory.GetCurrentDirectory();                 proc.FileName = \"MyFancyApp.exe\";                 proc.Verb = \"runas\";                  Process.Start(proc);\n \nDoing this programmatically is useful if you need to elevate for a particular reason (e.g., adding files to a folder that requires admin rights to access) temporarily, and then later wanting to reduce the access level.\n \nWith dotNetZip, I couldn't figure out which manifest file to manipulate (nor could I find a manifest file), so I thought I'd try a programmatic UAC elevation.  Unfortunately, this didn't work.  It could be my problem (e.g., I'm doing it wrong), but I'm not sure.\n \nAs to elevating EXEs that are not Vista/Win7 -aware, I suppose you could inform the user (using written instructions sent via email) to right-click the exe and click, \"run as administrator\".  This will work.  Unfortunately, for my particular application, the self-extracting exe is being sent to a remote factory located half-way around the world where it is to be installed by someone who is neither computer literate nor a native English speaker, so anything I can do to reduce the level of user interaction is important.  Previously, the staff at this factory was having trouble copying files sent via email in a zip file and putting them into a particular folder on a PC in an assembly line environment.\n \n \n \nThanks,\n \n-Peter",
    "LastUpdatedDate": "2013-02-21T18:43:33.59-08:00",
    "PlannedForRelease": "",
    "ReleaseVisibleToPublic": false,
    "Priority": {
      "Name": "Low",
      "Severity": 50,
      "Id": 1
    },
    "ProjectName": "DotNetZip",
    "ReportedDate": "2010-04-23T15:41:38.95-07:00",
    "Status": {
      "Name": "Proposed",
      "Id": 1
    },
    "ReasonClosed": {
      "Name": "Unassigned"
    },
    "Summary": "Provide a way to specify that the SFX should request elevated perms on Vista/7",
    "Type": {
      "Name": "Issue",
      "Id": 3
    },
    "VoteCount": 2,
    "Id": 10704
  },
  "FileAttachments": [],
  "Comments": [
    {
      "Message": "I am having an issue, I run a self extractor which then opens my own installer (which requrest elevation) however after finishing all of the process windows says that the DotNetZip SFX archive may not have installed correctly \r\n\r\nI'm guessing it is because of this issue? ",
      "PostedDate": "2010-05-12T21:38:17.4-07:00",
      "Id": -2147483648
    },
    {
      "Message": "actually sorry, it is not specifically this, but rather needs to be set as compatible in the manifest file I believe ",
      "PostedDate": "2010-05-12T21:43:28.433-07:00",
      "Id": -2147483648
    },
    {
      "Message": "We're really interested in this issue.  Is there any update as to status?  We want to find a way so that Vista and Win7 users can download an SFX, click Run on the install box and have it actually unzip and run without them having to find the downloaded file and right-click and run as administrator.  They hate that!\r\n\r\nIt would be great if there was an option we could set to run the install line as an admin.  Any chance of that?  If not - what's a good workaround?  Otherwise, everything works great.  Thanks.",
      "PostedDate": "2010-07-30T16:50:33.78-07:00",
      "Id": -2147483648
    },
    {
      "Message": "",
      "PostedDate": "2013-02-21T18:43:33.59-08:00",
      "Id": -2147483648
    }
  ]
}