Directories unexpectedly are installed with rwx permissions for the owner only

VERIFIED FIXED in M16

Status

Core Graveyard
Installer: XPInstall Engine
P3
normal
VERIFIED FIXED
18 years ago
2 years ago

People

(Reporter: Jimmy Lee, Assigned: dbragg)

Tracking

({pp})

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [PDT-])

(Reporter)

Description

18 years ago
Build: 1999-11-15-20-M11(Linux)

1. From http://jimbob/trigger2.html, trigger
   http://jimbob/jars/f_adddirfile_permissions.xpi

////////////////////////////////////////////////////////////////////////////////
//
// f_adddirfile_permissions.js
//
// Functional test
// 	• This test installs 4 text files (smrtupdt1.txt, smrtupdt2.txt,
//        smrtupdt3.txt, and smrtupdt4.txt) that have different file permissions
//           smrtupdt1.txt = r--r--r--
//           smrtupdt2.txt = rw-rw-rw-
//	     smrtupdt3.txt = rwxrwxrwx
//	     smrtupdt4.txt = r-xr-xr-x
// 	• addDirectory is used to add various directories which contain files
//        and/or subdirectories with specific permissions.  The directories,
//        /100r, /100rw, /100rx, and /100rwx each contain 100 files.
//           /100r
//	     /100rw
//           /100rx
//           /100rwx
//	     /perms
//              smrtupdt1.txt = r--r--r--
//              smrtupdt2.txt = rw-rw-rw-
//	        smrtupdt3.txt = rwxrwxrwx
//	        smrtupdt4.txt = r-xr-xr-x
//              /readexecute
//                 smrtupdt1.txt = r--r--r--
//                 smrtupdt2.txt = rw-rw-rw-
//	           smrtupdt3.txt = rwxrwxrwx
//	           smrtupdt4.txt = r-xr-xr-x
//		   /readwrite
//                    smrtupdt1.txt = r--r--r--
//                    smrtupdt2.txt = rw-rw-rw-
//	              smrtupdt3.txt = rwxrwxrwx
//	              smrtupdt4.txt = r-xr-xr-x
//
//
// ~ XPInstall QA
//   November 19, 1999
//
////////////////////////////////////////////////////////////////////////////////

var regName1 = "100r";
var regName2 = "100rw";
var regName3 = "100rx";
var regName4 = "100rwx";
var regName5 = "perms";
vi = "1.1.1.1";
var jarSrc1 = "smrtupdt1.txt";
var jarSrc2 = "smrtupdt2.txt";
var jarSrc3 = "smrtupdt3.txt";
var jarSrc4 = "smrtupdt4.txt";

startInstall("Functional: f_adddirfile_permissions", "permissions", vi, 1);
f = getFolder("Program");

s1 = addFile("smrt1", vi, jarSrc1, f, jarSrc1, true);
logComment("addFile smrtupdt1.txt returns = " + s1);

s2 = addFile("smrt2", "1.1.1.2", jarSrc2, f, jarSrc2, true);
logComment("addFile smrtupdt2.txt returns = " + s2);

s3 = addFile("smrt3", "1.1.1.3", jarSrc3, f, jarSrc3, true);
logComment("addFile smrtupdt3.txt returns = " + s3);

s4 = addFile("smrt4", "1.1.1.4", jarSrc4, f, jarSrc4, true);
logComment("addFile smrtupdt4.txt returns = " + s4);

err1 = addDirectory(regName1, vi, "100r", f, "100r", true);
logComment("addDirectory 100r returns = " + err1);

err2 = addDirectory(regName2, vi, "100rw", f, "100rw", true);
logComment("addDirectory 100rw returns = " + err2);

err3 = addDirectory(regName3, vi, "100rx", f, "100rx", true);
logComment("addDirectory 100rx returns = " + err3);

err4 = addDirectory(regName4, vi, "100rwx", f, "100rwx", true);
logComment("addDirectory 100rwx returns = " + err4);

err5 = addDirectory(regName5, vi, "perms", f, "perms", true);
logComment("addDirectory perms returns = " + err5);

if (0 == getLastError())
	finalizeInstall();
else
	abortInstall();

RESULT:
Files and directories are installed.  The version registry looks correct.  The
Install.log looks correct.  The installed files maintain the proper permissions.
All directories are installed with read, write, execute (rwx) permissions for
the owner only.

EXPECTED RESULT:
Directories are installed with rwxr-xr-x permissions.  This matches the default
from the system level.
Summary: [PP]Directories unexpectedly are installed with rwx permissions for the owner only → [beta][PP]Directories unexpectedly are installed with rwx permissions for the owner only
Target Milestone: M13
Is this a filespec problem (and thus passed on to dougt or shaver), or an
XPInstall problem (and thus probably sgehani)?

Comment 2

18 years ago
Filespec, I believe. We merely ask filespec to create the subdirs if they don't
exist when installing files.

Comment 3

18 years ago
Bulk move of XPInstall (component to be deleted) bugs to Installer: XPInstall
Engine
Target Milestone: M13 → M14

Updated

18 years ago
Assignee: cathleen → dougt

Comment 4

18 years ago
reassign to dougt, will get fixed when xpinstall is ported to use nsIFile.

Updated

18 years ago
Keywords: pp

Comment 5

18 years ago
moving to m15
Target Milestone: M14 → M15

Comment 6

18 years ago
Due to Beta indication in Summary, putting beta1 into keyword field.
Keywords: beta1

Updated

18 years ago
Whiteboard: [PDT-]

Comment 7

18 years ago
pdt notes that ought to be release noted if not fixed

Comment 8

18 years ago
now the permissions are 755.
Status: NEW → RESOLVED
Last Resolved: 18 years ago
Resolution: --- → FIXED
(Reporter)

Comment 9

18 years ago
Build 2000-02-09-14-M14(LINUX)

I'm still getting the same results as I had described under RESULT.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---

Updated

18 years ago
Summary: [beta][PP]Directories unexpectedly are installed with rwx permissions for the owner only → Directories unexpectedly are installed with rwx permissions for the owner only

Comment 10

18 years ago
over to dbragg, he is going to intergrate nsIFile.
Assignee: dougt → dbragg
Status: REOPENED → NEW

Comment 11

18 years ago
moving to M16
Target Milestone: M15 → M16

Comment 12

18 years ago
[dougt@y 100r]$ pwd
/builds/dougt/mozilla/dist/bin/100r
[dougt@y 100r]$ ls -al . | more
total 408
drwxr-xr-x   2 dougt    wheel        4096 Apr 23 21:54 .
drwxr-xr-x  15 dougt    wheel        4096 Apr 23 21:54 ..

marking as fixed.
Status: NEW → RESOLVED
Last Resolved: 18 years ago18 years ago
Resolution: --- → FIXED
(Reporter)

Comment 13

18 years ago
Build: 2000-04-27-09-M16(LINUX)

Done.
Status: RESOLVED → VERIFIED
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.