{
  "WorkItem": {
    "AffectedComponent": {
      "Name": "",
      "DisplayName": ""
    },
    "ClosedComment": "fixed in changeset 32225.  The first binary release with this fix will be 1.8.3.13.",
    "ClosedDate": "2009-05-31T06:01:51.647-07:00",
    "CommentCount": 0,
    "Custom": null,
    "Description": "see discussion http://dotnetzip.codeplex.com/Thread/View.aspx?ThreadId=54120\nI've used DotNetZip v 1.7 in a .NET 2.0 application that store zip file in a share folder.\n \nOccasionally the zip created is not accessible... :(\nThe properties of that zip contain only the General Tab.\nThe Security Tab is not present and the client that access on this share folder can see this zip but access is denied...\n \nWorkaround: If I pass a FileStream to Save Method the permission are ok...otherwise... not.\n \nsometimes fails: \nUsing zip As New Ionic.Zip.ZipFile(FileName)\n  ....\n  zip.Save\nEnd Using\n \nworks:\nUsing fs as New FileStream(FileName, FileMode.CreateNew)\n    Using zip As New Ionic.Zip.ZipFile()\n        ...\n       zip.Save(fs)\n    End Using \nEnd Using",
    "LastUpdatedDate": "2013-05-16T05:32:25.947-07:00",
    "PlannedForRelease": "",
    "ReleaseVisibleToPublic": false,
    "Priority": {
      "Name": "Low",
      "Severity": 50,
      "Id": 1
    },
    "ProjectName": "DotNetZip",
    "ReportedDate": "2009-04-28T10:39:47.027-07:00",
    "Status": {
      "Name": "Closed",
      "Id": 4
    },
    "ReasonClosed": {
      "Name": "Unassigned"
    },
    "Summary": "File perms problem when saving to a share (put temp file in same folder as target)",
    "Type": {
      "Name": "Issue",
      "Id": 3
    },
    "VoteCount": 3,
    "Id": 7703
  },
  "FileAttachments": [],
  "Comments": [
    {
      "Message": "It's possible that this happens because the file is created in the user's temp folder and then moved into the final save folder.  I have noticed especially if you create a zip as an administrator, but save it to a common use folder, and then try to open the file as a regular user, the file does not inherit the permissions of the folder is was moved to.\r\n\r\nIt is possible that in the ZipFile.cs file, public void Save() method, using System.IO.File.Copy and then deleting the temp file will have better results, but I have not tested it.",
      "PostedDate": "2009-05-02T14:11:39.27-07:00",
      "Id": -2147483648
    },
    {
      "Message": "",
      "PostedDate": "2009-05-21T12:05:12.263-07:00",
      "Id": -2147483648
    },
    {
      "Message": "Without modifying the Zip source, the following helped us duct-tape it to work as expected in the Environment.SpecialFolder.CommonApplicationData folder:\r\n\r\nFileSecurity fileSecurity = File.GetAccessControl(archiveFile);\r\nfileSecurity.AddAccessRule(new FileSystemAccessRule(\"Everyone\",\tFileSystemRights.Modify,AccessControlType.Allow));\r\nFile.SetAccessControl(archiveFile, fileSecurity);\r\n\r\nPerhaps use the Environment.SpecialFolder.CommonApplicationData folder instead of the user-specific temp? Is there any harm in creating the temp file in the same folder as the destination? Most \"commercial\" zip utilities follow this method. ",
      "PostedDate": "2009-05-21T12:15:41.027-07:00",
      "Id": -2147483648
    },
    {
      "Message": "@mercdev, I think you're right.  The temp file should be created in the same folder as the end destination zipfile. I don't know why I didn't do it that way in the first place. ",
      "PostedDate": "2009-05-30T07:46:41.243-07:00",
      "Id": -2147483648
    },
    {
      "Message": "",
      "PostedDate": "2009-05-30T07:49:01.743-07:00",
      "Id": -2147483648
    },
    {
      "Message": "",
      "PostedDate": "2009-05-31T06:01:51.647-07:00",
      "Id": -2147483648
    },
    {
      "Message": "",
      "PostedDate": "2013-02-21T18:44:22.75-08:00",
      "Id": -2147483648
    },
    {
      "Message": "",
      "PostedDate": "2013-05-16T05:32:25.947-07:00",
      "Id": -2147483648
    }
  ]
}