SlideShare a Scribd company logo
1 of 1
Download to read offline
Step 1. Keep it Simple To get things started. Wily Corp wants to streamline file creation. They
often create files that are owned by root and the same set of permissions, but each time they do
this, it requires running three commands. Using the Kali Linux VM, create a script file named
filegen. sh that takes the filename as the argument (allowing the user to run the script as
filegen.sh FILENAME) and then accomplishes tasks: - Creates the file in the same directory as
the script - Sets the owner of the file to root: root - Changes the permissions of the file to U :
RWX , G : RW , O : R - Don't use sudo within the script Run the command as "filegen. sh
testfile" and provide output showing the script ran and a directory listing of the created file,
showing permissions and ownership.

More Related Content

More from AlanSmDDyerl

show code and all classes with full implementation for these Program S.pdf
show code and all classes with full implementation for these Program S.pdfshow code and all classes with full implementation for these Program S.pdf
show code and all classes with full implementation for these Program S.pdf
AlanSmDDyerl
 

More from AlanSmDDyerl (20)

Spinal Cord Review - Match the appropriate term to the description- Wr.pdf
Spinal Cord Review - Match the appropriate term to the description- Wr.pdfSpinal Cord Review - Match the appropriate term to the description- Wr.pdf
Spinal Cord Review - Match the appropriate term to the description- Wr.pdf
 
Soils are complex mixtures of totally inorganic materials- sterile- un.pdf
Soils are complex mixtures of totally inorganic materials- sterile- un.pdfSoils are complex mixtures of totally inorganic materials- sterile- un.pdf
Soils are complex mixtures of totally inorganic materials- sterile- un.pdf
 
So I need some python help! I'm working with a 7-segment display with.pdf
So I need some python help! I'm working with a 7-segment display with.pdfSo I need some python help! I'm working with a 7-segment display with.pdf
So I need some python help! I'm working with a 7-segment display with.pdf
 
Sketch a depositional sequence with its component parasequences- syste.pdf
Sketch a depositional sequence with its component parasequences- syste.pdfSketch a depositional sequence with its component parasequences- syste.pdf
Sketch a depositional sequence with its component parasequences- syste.pdf
 
Skeletal muscles are considered voluntary and are classified by their.pdf
Skeletal muscles are considered voluntary and are classified by their.pdfSkeletal muscles are considered voluntary and are classified by their.pdf
Skeletal muscles are considered voluntary and are classified by their.pdf
 
Shown here is a graph illustrating daty fiom the original Pulse Chase.pdf
Shown here is a graph illustrating daty fiom the original Pulse Chase.pdfShown here is a graph illustrating daty fiom the original Pulse Chase.pdf
Shown here is a graph illustrating daty fiom the original Pulse Chase.pdf
 
Since HIV has such a long window period- what implications does that h.pdf
Since HIV has such a long window period- what implications does that h.pdfSince HIV has such a long window period- what implications does that h.pdf
Since HIV has such a long window period- what implications does that h.pdf
 
Shown here is a transmission electron micrograph (TEM)- What is the mo.pdf
Shown here is a transmission electron micrograph (TEM)- What is the mo.pdfShown here is a transmission electron micrograph (TEM)- What is the mo.pdf
Shown here is a transmission electron micrograph (TEM)- What is the mo.pdf
 
Show that in general for any events E and F- Pr(EF)Pr(E)Pr(F)41.pdf
Show that in general for any events E and F- Pr(EF)Pr(E)Pr(F)41.pdfShow that in general for any events E and F- Pr(EF)Pr(E)Pr(F)41.pdf
Show that in general for any events E and F- Pr(EF)Pr(E)Pr(F)41.pdf
 
Sienna is 1 week old- Her mother- Jennifer- says that nursing is very.pdf
Sienna is 1 week old- Her mother- Jennifer- says that nursing is very.pdfSienna is 1 week old- Her mother- Jennifer- says that nursing is very.pdf
Sienna is 1 week old- Her mother- Jennifer- says that nursing is very.pdf
 
Shell script 3- (Network-sh) Network Script (Network-sh) will display.pdf
Shell script 3- (Network-sh) Network Script (Network-sh) will display.pdfShell script 3- (Network-sh) Network Script (Network-sh) will display.pdf
Shell script 3- (Network-sh) Network Script (Network-sh) will display.pdf
 
show code and all classes with full implementation for these Program S.pdf
show code and all classes with full implementation for these Program S.pdfshow code and all classes with full implementation for these Program S.pdf
show code and all classes with full implementation for these Program S.pdf
 
Species I has 2n-8 chromosomes and species II has 2n-14 chromosomes- W.pdf
Species I has 2n-8 chromosomes and species II has 2n-14 chromosomes- W.pdfSpecies I has 2n-8 chromosomes and species II has 2n-14 chromosomes- W.pdf
Species I has 2n-8 chromosomes and species II has 2n-14 chromosomes- W.pdf
 
Species I has 2n-8 chromosomes and species II has 2n-14 chromosomes- W (1).pdf
Species I has 2n-8 chromosomes and species II has 2n-14 chromosomes- W (1).pdfSpecies I has 2n-8 chromosomes and species II has 2n-14 chromosomes- W (1).pdf
Species I has 2n-8 chromosomes and species II has 2n-14 chromosomes- W (1).pdf
 
Sort the function by the structure of the digestive tract that produce.pdf
Sort the function by the structure of the digestive tract that produce.pdfSort the function by the structure of the digestive tract that produce.pdf
Sort the function by the structure of the digestive tract that produce.pdf
 
Some of the appeal of REITs as an investment choice include the follow.pdf
Some of the appeal of REITs as an investment choice include the follow.pdfSome of the appeal of REITs as an investment choice include the follow.pdf
Some of the appeal of REITs as an investment choice include the follow.pdf
 
Some apparently unrelated animals have organs with similar functions-.pdf
Some apparently unrelated animals have organs with similar functions-.pdfSome apparently unrelated animals have organs with similar functions-.pdf
Some apparently unrelated animals have organs with similar functions-.pdf
 
Solve on paper! Exercise 3- (0-3 Points) Apply the Composite Midpoin.pdf
Solve on paper!   Exercise 3- (0-3 Points) Apply the Composite Midpoin.pdfSolve on paper!   Exercise 3- (0-3 Points) Apply the Composite Midpoin.pdf
Solve on paper! Exercise 3- (0-3 Points) Apply the Composite Midpoin.pdf
 
Software Evolution Give four reasons why a software system that is use.pdf
Software Evolution Give four reasons why a software system that is use.pdfSoftware Evolution Give four reasons why a software system that is use.pdf
Software Evolution Give four reasons why a software system that is use.pdf
 
Sheridan Corporation has 42-500 shares of $10 par value common stock o.pdf
Sheridan Corporation has 42-500 shares of $10 par value common stock o.pdfSheridan Corporation has 42-500 shares of $10 par value common stock o.pdf
Sheridan Corporation has 42-500 shares of $10 par value common stock o.pdf
 

Recently uploaded

Spellings Wk 4 and Wk 5 for Grade 4 at CAPS
Spellings Wk 4 and Wk 5 for Grade 4 at CAPSSpellings Wk 4 and Wk 5 for Grade 4 at CAPS
Spellings Wk 4 and Wk 5 for Grade 4 at CAPS
AnaAcapella
 
SURVEY I created for uni project research
SURVEY I created for uni project researchSURVEY I created for uni project research
SURVEY I created for uni project research
CaitlinCummins3
 
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
中 央社
 

Recently uploaded (20)

VAMOS CUIDAR DO NOSSO PLANETA! .
VAMOS CUIDAR DO NOSSO PLANETA!                    .VAMOS CUIDAR DO NOSSO PLANETA!                    .
VAMOS CUIDAR DO NOSSO PLANETA! .
 
When Quality Assurance Meets Innovation in Higher Education - Report launch w...
When Quality Assurance Meets Innovation in Higher Education - Report launch w...When Quality Assurance Meets Innovation in Higher Education - Report launch w...
When Quality Assurance Meets Innovation in Higher Education - Report launch w...
 
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptxCOMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
COMMUNICATING NEGATIVE NEWS - APPROACHES .pptx
 
OS-operating systems- ch05 (CPU Scheduling) ...
OS-operating systems- ch05 (CPU Scheduling) ...OS-operating systems- ch05 (CPU Scheduling) ...
OS-operating systems- ch05 (CPU Scheduling) ...
 
Spellings Wk 4 and Wk 5 for Grade 4 at CAPS
Spellings Wk 4 and Wk 5 for Grade 4 at CAPSSpellings Wk 4 and Wk 5 for Grade 4 at CAPS
Spellings Wk 4 and Wk 5 for Grade 4 at CAPS
 
SURVEY I created for uni project research
SURVEY I created for uni project researchSURVEY I created for uni project research
SURVEY I created for uni project research
 
AIM of Education-Teachers Training-2024.ppt
AIM of Education-Teachers Training-2024.pptAIM of Education-Teachers Training-2024.ppt
AIM of Education-Teachers Training-2024.ppt
 
24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...
24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...
24 ĐỀ THAM KHẢO KÌ THI TUYỂN SINH VÀO LỚP 10 MÔN TIẾNG ANH SỞ GIÁO DỤC HẢI DƯ...
 
OSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & SystemsOSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & Systems
 
UChicago CMSC 23320 - The Best Commit Messages of 2024
UChicago CMSC 23320 - The Best Commit Messages of 2024UChicago CMSC 23320 - The Best Commit Messages of 2024
UChicago CMSC 23320 - The Best Commit Messages of 2024
 
The Liver & Gallbladder (Anatomy & Physiology).pptx
The Liver &  Gallbladder (Anatomy & Physiology).pptxThe Liver &  Gallbladder (Anatomy & Physiology).pptx
The Liver & Gallbladder (Anatomy & Physiology).pptx
 
An overview of the various scriptures in Hinduism
An overview of the various scriptures in HinduismAn overview of the various scriptures in Hinduism
An overview of the various scriptures in Hinduism
 
Graduate Outcomes Presentation Slides - English (v3).pptx
Graduate Outcomes Presentation Slides - English (v3).pptxGraduate Outcomes Presentation Slides - English (v3).pptx
Graduate Outcomes Presentation Slides - English (v3).pptx
 
DEMONSTRATION LESSON IN ENGLISH 4 MATATAG CURRICULUM
DEMONSTRATION LESSON IN ENGLISH 4 MATATAG CURRICULUMDEMONSTRATION LESSON IN ENGLISH 4 MATATAG CURRICULUM
DEMONSTRATION LESSON IN ENGLISH 4 MATATAG CURRICULUM
 
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文會考英文
 
Major project report on Tata Motors and its marketing strategies
Major project report on Tata Motors and its marketing strategiesMajor project report on Tata Motors and its marketing strategies
Major project report on Tata Motors and its marketing strategies
 
How To Create Editable Tree View in Odoo 17
How To Create Editable Tree View in Odoo 17How To Create Editable Tree View in Odoo 17
How To Create Editable Tree View in Odoo 17
 
Observing-Correct-Grammar-in-Making-Definitions.pptx
Observing-Correct-Grammar-in-Making-Definitions.pptxObserving-Correct-Grammar-in-Making-Definitions.pptx
Observing-Correct-Grammar-in-Making-Definitions.pptx
 
How to Manage Website in Odoo 17 Studio App.pptx
How to Manage Website in Odoo 17 Studio App.pptxHow to Manage Website in Odoo 17 Studio App.pptx
How to Manage Website in Odoo 17 Studio App.pptx
 
PSYPACT- Practicing Over State Lines May 2024.pptx
PSYPACT- Practicing Over State Lines May 2024.pptxPSYPACT- Practicing Over State Lines May 2024.pptx
PSYPACT- Practicing Over State Lines May 2024.pptx
 

Step 1- Keep it Simple To get things started- Wily Corp wants to strea.pdf

  • 1. Step 1. Keep it Simple To get things started. Wily Corp wants to streamline file creation. They often create files that are owned by root and the same set of permissions, but each time they do this, it requires running three commands. Using the Kali Linux VM, create a script file named filegen. sh that takes the filename as the argument (allowing the user to run the script as filegen.sh FILENAME) and then accomplishes tasks: - Creates the file in the same directory as the script - Sets the owner of the file to root: root - Changes the permissions of the file to U : RWX , G : RW , O : R - Don't use sudo within the script Run the command as "filegen. sh testfile" and provide output showing the script ran and a directory listing of the created file, showing permissions and ownership.