Special permission Exercises

Source: Internet
Author: User

[[Email protected] ~]# useradd stu[[email protected]~]#suStu[[email protected] root]$Cat/etc/ShadowCat:/etc/Shadow: Insufficient permissions [[email protected] root]$ Exitexit[[email protected]~]#Cat/etc/shadowroot:$1$HDJWFMDL $hfgaq.eq1pwrodjv7jqmn1:16330:0:99999:7::: Bin:*:16325:0:99999:7: ::d Aemon:*:16325:0:99999:7::: adm:*:16325:0:99999:7:::LP:*:16325:0:99999:7:::Sync:*:16325:0:99999:7:: : Shutdown:*:16325:0:99999:7:: : Halt:*:16325:0:99999:7:: : Mail:*:16325:0:99999:7:: : News:*:16325:0:99999:7:: : UUCP:*:16325:0:99999:7:: : operator:*:16325:0:99999:7:: : Games:*:16325:0:99999:7:: : Gopher:*:16325:0:99999:7:::FTP:*:16325:0:99999:7:: : Nobody:*:16325:0:99999:7:: : NSCD:!!:16325:0:99999:7:: : VCSA:!!:16325:0:99999:7::: RPC:!!:16325:0:99999:7:: : Mailnull:!!:16325:0:99999:7:: : Smmsp:!!:16325:0:99999:7: ::p Cap:!!:16325:0:99999:7: ::d bus:!!:16325:0:99999:7:: : Avahi:!!:16325:0:99999:7:: : sshd:!!:16325:0:99999:7:: : Rpcuser:!!:16325:0:99999:7:: : Nfsnobody:!!:16325:0:99999:7:: : Haldaemon:!!:16325:0:99999:7::: Avahi-autoipd:!!:16325:0:99999:7::: XFS:!!:16325:0:99999:7:: : Stu:!!:16357:0:99999:7::: [[email protected]~]#ls-l/etc/Shadow-R--------1Root root889 Ten- -  -: -/etc/Shadow[[email protected]~]# sl-l/usr/bin/passwd-Bash:sl:command not found[[email protected]~]#ls-l/usr/bin/passwd-rwsr-xr-x1Root root19904  -- on- -/usr/bin/passwd[[Email protected]~]#ls-l/usr/bin/Locate-rwx--s--x1Root Slocate22280  the- the-Geneva/usr/bin/Locate[[Email protected]~]# LL/tmp Total0[[Email protected]~]#ls-LD/TMPDRWXRWXRWT4Root root4096 Ten- -  -: $/Tmp[[email protected]~]# CD/Tmp[[email protected] tmp]#TouchTest[[email protected] tmp]# ll Total4-rw-r--r--1Root root0 Ten- -  +: +Test[[email protected] tmp]#chmod 777Test[[email protected] tmp]# ll Total4-rwxrwxrwx1Root root0 Ten- -  +: +Test[[email protected] tmp]#suStu[[email protected] tmp]$ ll Total4-rwxrwxrwx1Root root0 Ten- -  +: +Test[[email protected] tmp]$RMTestRM: Could not delete "test": Operation not allowed [[email protected] tmp]$ Exitexit[[email protected] tmp]# ll Total4-rwxrwxrwx1Root root0 Ten- -  +: +Test[[email protected] tmp]#RMTestRM: Do you want to delete the generic empty file "test"?Y[[email protected] tmp]# ll Total0[email protected] tmp]#suStu[[email protected] tmp]$TouchTest1[[email protected] tmp]$chmod 777Test1[[email protected] tmp]$ ll Total4-rwxrwxrwx1Stu Stu0 Ten- -  +: atTest1[[email protected] tmp]$ exitexit[[email protected] tmp]# useradd stu2[[email protected] tmp]#suStu2[[email protected] tmp]$ ll Total4-rwxrwxrwx1Stu Stu0 Ten- -  +: atTest1[[email protected] tmp]$RMtest1RM: Unable to delete "Test1": Operation not allowed [[email protected] tmp]$ Exitexit[[email protected] tmp]# ll Total4-rwxrwxrwx1Stu Stu0 Ten- -  +: atTest1[[email protected] tmp]#RMtest1RM: Do you want to delete the generic empty file "Test1"?Y[[email protected] tmp]# ll Total0[email protected] tmp]# umask0022[email protected] tmp]#TouchTest[[email protected] tmp]# ll Total4-rw-r--r--1Root root0 Ten- -  +: -Test[[email protected] tmp]#chmod 4755test;ll Test-rwsr-xr-x1Root root0 Ten- -  +: -Test[[email protected] tmp]#chmod 6755test;ll Test-rwsr-sr-x1Root root0 Ten- -  +: -Test[[email protected] tmp]#chmod 1755test;ll Test-rwxr-xr-t1Root root0 Ten- -  +: -Test[[email protected] tmp]#chmod 7666test;ll Test-rwsrwsrwt1Root root0 Ten- -  +: -Test[[email protected] tmp]#

Special permission Exercises

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.