Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19

Warning: Function ereg() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 4

Warning: Function split() is deprecated in ..../includes/class_postbit.php(345) : eval()'d code on line 19
2 questions
Results 1 to 8 of 8

Thread: 2 questions

  1. #1

    2 questions

    For someone to see the contents of a fle in a directory of yours, there must exist -read- and -execute- permissions on the directory?

    true
    false


    If one of your directories has just the -read- permission set, a user can see the list of files in that directory, but none of the attributes for those files?

    true
    false

  2. #2

    Re: 2 questions

    1. true

    2. true - I tried it, and I could tell the files existed but could not determine the attribute - permission denied messages poped up




  3. #3
    Moderator
    Good Guru
    Compunuts's Avatar
    Join Date
    May 2001
    Location
    California
    Posts
    3,935

    Re: 2 questions

    May be general Linux question are is more appropate for this type of questions rather than Techsupport. After all, you can't all IBM Techsupport and ask them, a computer use CPU, true or false... *

    Anyway ...

    1. True

    2. False ( You must have execute permission to be able to read what's inside for the directories, that's include yourself ).

    Code:
    [voyager raja]$ls -l
    drwx------ * *2 root * * root * * * * 4096 Jan *8 12:29 tux
    [voyager var]$ cd tux
    bash: cd: tux: Permission denied
    [voyager wwl60720]$ ls -l
    drw-r--r-- * *2 wwl60720 unixStud * * 4096 May *9 19:52 test
    [voyager wwl60720]$ cd test
    bash: cd: test: Permission denied
    [voyager wwl60720]$ chmod 755 test
    [voyager wwl60720]$ ls -l
    drwxr-xr-x * *2 wwl60720 unixStud * * 4096 May *9 19:52 test
    [voyager wwl60720]$ cd test
    [voyager test]$
    [voyager test]$ id -un
    wwl60720
    [voyager test]$ whoami
    wwl60720
    [voyager test]$

  4. #4
    Moderator
    Good Guru
    Compunuts's Avatar
    Join Date
    May 2001
    Location
    California
    Posts
    3,935

    Re: 2 questions


    I tried it, and I could tell the files existed but could not determine the attribute - permission denied messages poped up
    How do you know the files existed??

    Dont' tell me it's your sixth. sense .... ;D

  5. #5

    Re: 2 questions

    well Mr. Compunuts - i tried it! ll is aliased to ls -l and with the permissions set as Mr. Rookie suggested (well, at lest the xecutable bit was not set) you get this:

    Code:
    [pbharris@bugs ~]ll ~ann/ | grep test
    drwxrw-rw-  2 ann   ann     4.0k May 9 21:37 test
    [pbharris@bugs ~]ll ~ann/test/    
    ls: /home/ann/test/casd: Permission denied
    ls: /home/ann/test/casd2: Permission denied
    ls: /home/ann/test/casd3: Permission denied
    total 0
    [pbharris@bugs ~]
    I can tell the files exist, but i can't determine much about them

  6. #6
    Moderator
    Good Guru
    Compunuts's Avatar
    Join Date
    May 2001
    Location
    California
    Posts
    3,935

    Re: 2 questions

    Code:
    [pbharris@bugs ~]ll ~ann/ | grep test
    drwxrw-rw- * *2 ann * * *ann * * * * *4.0k May *9 21:37 test
    [pbharris@bugs ~]ll ~ann/test/ * * * 
    ls: /home/ann/test/casd: Permission denied
    ls: /home/ann/test/casd2: Permission denied
    ls: /home/ann/test/casd3: Permission denied
    [pbharris@bugs ~]
    Yours is set to "rw-". I thought Mr. Rookie wanted just "r--". I tried with only R and it won't even spit anything out ...
    :-/

    <edited> Done it after days later realizing that the tags are screwed up.... </edited>

  7. #7

    Re: 2 questions

    okay, you can't cd to it, but you can ls it. and ls just gives the permission denied errors.

    Code:
    gorn@flock % ls -ld a
    drw-r--r--  2 gorn   gorn     4096 May 10 10:10 a/
    ~
    gorn@flock % ls -l a
    /bin/ls: a/foo: Permission denied
    /bin/ls: a/bar: Permission denied
    /bin/ls: a/baz: Permission denied
    total 0
    ~
    gorn@flock %

  8. #8
    Moderator
    Good Guru
    Compunuts's Avatar
    Join Date
    May 2001
    Location
    California
    Posts
    3,935

    Re: 2 questions


    okay, you can't cd to it, but you can ls it. and ls just gives the permission denied errors.

    Code:
    gorn@flock % ls -ld a
    drw-r--r-- * 2 gorn * * gorn * * * * 4096 May 10 10:10 a/
    ~
    gorn@flock % ls -l a
    /bin/ls: a/foo: Permission denied
    gorn@flock %
    That's because you are the same owner as of your user ... Here we are talking about doing it to different owner's file/directory, I think.

Similar Threads

  1. just a few odd questions
    By 10Dedfish in forum Linux - General Topics
    Replies: 3
    Last Post: 09-15-2004, 03:49 AM
  2. CPU Questions
    By stryder144 in forum Linux - Hardware, Networking & Security
    Replies: 0
    Last Post: 06-27-2003, 08:31 PM
  3. KDE Questions
    By trickster in forum Linux - Software, Applications & Programming
    Replies: 2
    Last Post: 09-02-2002, 01:15 AM
  4. some questions on 2 hd's
    By in forum Linux - Hardware, Networking & Security
    Replies: 12
    Last Post: 01-25-2002, 09:14 AM
  5. DNS questions
    By agar in forum Linux - Hardware, Networking & Security
    Replies: 3
    Last Post: 12-03-2001, 10:57 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •