SlideShare a Scribd company logo
1 of 3
Download to read offline
Working with Apache Web Server
Time Required: 35 minutes
Objective: Explore basic settings and tasks in Apache Web Server.
Description: Without a doubt, youll run across Apache Web Server systems when conducting a
security test. Because Apache is a sophisticated, modular Web server, mastering its features and
options can take considerable time. Apaches layout varies, depending on the OS. For example,
Apache in Fedora Linux is different from Apache in Ubuntu Linux. In this activity, you explore
basic Apache Web Server commands and learn how to find and modify some configuration
options (called Apache directives). The goal of this activity is to configure a Web server with a
directory that requires authentication.
1.
Boot your computer into Linux with the Kali Linux DVD.
2.
Open a Terminal shell. At the command prompt, type apache2ctl start and press Enter. You can
safely ignore the Could not reliably determine the servers fully qualified domain name error.
3.
Start the Iceweasel Web browser. In the address bar, type localhost and press Enter. The Web
site displays instructions on how to manipulate the default apache configuration. Read over this
page.
4.
Open a Terminal shell. At the command prompt, type apache2ctl stop and press Enter.
5.
Now, well view the default apache configuration files. In the Terminal shell, type cd/etc/apache2
and press Enter to change directories. Then type grep Include apache2.conf and press Enter to
see a listing of files and directories where the Apache server searches for additional directives at
startup (see Figure 10-5). Note the next to last line, IncludeOptional sites-enabled/*.conf. This
directory is where Apache checks for Web site configuration files. You can add a Web site by
adding its configuration file in this directory without having to change the main configuration
file apache2.conf.
Figure 10-5
Viewing files and directories with an Include statement
Source: GNU GPL
6.
Type cd /etc/apache2/sites-enabled && ls and press Enter.
7.
Open the file in the gvim editor by typing gvim 000-default.conf and pressing Enter.
8.
Enter the following lines at the end of the file, below the line :
9.
Save your changes and exit the gvim editor by pressing Esc, typing :wq, and pressing Enter.
10.
In the Terminal shell, create a new directory by typing mkdir /var/www/html/restricted and
pressing Enter.
11.
Type cd /var/www/html/restricted to change to the directory you created in Step 12 and press
Enter. Then type touch secret.txt and press Enter to create a file in this directory.
12.
Next, you create the .htaccess file in the same directory. This file is the local directory
configuration file specified in apache2.conf by the AccessFileName directive. If .htaccess exists
in any Web site directory, Apache checks it first. In this .htaccess file, you point Apache to the
location of AuthUserFile (essentially, a password file). Type gvim.htaccess and press Enter.
Type the following for the files contents:
13.
Exit and save the file by pressing Esc and then pressing : (a colon). At the : prompt, type wq and
press Enter. In the Terminal shell, create a password file by typing htpasswd -c
/etc/apache2/.htpasswd tester and pressing Enter. When prompted, enter a password and confirm,
and then make note of the password. The .htaccess file you created in Step 12 tells Apache to
look in the .htpasswd file for the tester users password. You can run the command
cat/etc/apache2/.htpasswd to view the password hash for your new user.
14.
Restart Apache by typing apache2ctl restart and pressing Enter. In Iceweasel, go to
http://localhost/restricted, and enter the username tester and the password you confirmed in Step
13. What file is displayed? If you want to be prompted again for a password, youll have to close
and reopen your browser.
15.
See whether others in the class can access your restricted folder by having them enter
http://yourIPaddress/restricted in their browsers (replacing yourIPaddress with your IP address).
If necessary, type ifconfig eth0 and press Enter to find your IP address.
16.
Why is entering your credentials on a Web site not secured with SSL, such as this site, a
problem? What is the fix for this problem?
17.
Close the Terminal shell, exit Firefox, and log off Linux for the next activity.
Question 14 and 16

More Related Content

Similar to Working with Apache Web ServerTime Required 35 minutesObjective.pdf

Linux apache installation
Linux apache installationLinux apache installation
Linux apache installationDima Gomaa
 
Wamp & LAMP - Installation and Configuration
Wamp & LAMP - Installation and ConfigurationWamp & LAMP - Installation and Configuration
Wamp & LAMP - Installation and ConfigurationChetan Soni
 
Installation instruction of Testlink
Installation instruction of TestlinkInstallation instruction of Testlink
Installation instruction of Testlinkusha kannappan
 
Installing Lamp Stack on Ubuntu Instance
Installing Lamp Stack on Ubuntu InstanceInstalling Lamp Stack on Ubuntu Instance
Installing Lamp Stack on Ubuntu Instancekamarul kawnayeen
 
Apache installation and configurations
Apache installation and configurationsApache installation and configurations
Apache installation and configurationsNikhil Jain
 
Using aphace-as-proxy-server
Using aphace-as-proxy-serverUsing aphace-as-proxy-server
Using aphace-as-proxy-serverHARRY CHAN PUTRA
 
Apache windows
Apache windowsApache windows
Apache windowsmexxixxo
 
WP Sandbox Presentation WordCamp Toronto 2011
WP Sandbox Presentation WordCamp Toronto 2011WP Sandbox Presentation WordCamp Toronto 2011
WP Sandbox Presentation WordCamp Toronto 2011Alfred Ayache
 
Installing Hortonworks Hadoop for Windows
Installing Hortonworks Hadoop for WindowsInstalling Hortonworks Hadoop for Windows
Installing Hortonworks Hadoop for WindowsJonathan Bloom
 
Installing WordPress on AWS
Installing WordPress on AWSInstalling WordPress on AWS
Installing WordPress on AWSManish Jain
 

Similar to Working with Apache Web ServerTime Required 35 minutesObjective.pdf (20)

instaling
instalinginstaling
instaling
 
instaling
instalinginstaling
instaling
 
instaling
instalinginstaling
instaling
 
Its3 Drupal
Its3 DrupalIts3 Drupal
Its3 Drupal
 
Apache Web Server Setup 2
Apache Web Server Setup 2Apache Web Server Setup 2
Apache Web Server Setup 2
 
Linux apache installation
Linux apache installationLinux apache installation
Linux apache installation
 
Wamp & LAMP - Installation and Configuration
Wamp & LAMP - Installation and ConfigurationWamp & LAMP - Installation and Configuration
Wamp & LAMP - Installation and Configuration
 
Apache
ApacheApache
Apache
 
Installation instruction of Testlink
Installation instruction of TestlinkInstallation instruction of Testlink
Installation instruction of Testlink
 
Installing Lamp Stack on Ubuntu Instance
Installing Lamp Stack on Ubuntu InstanceInstalling Lamp Stack on Ubuntu Instance
Installing Lamp Stack on Ubuntu Instance
 
Apache installation and configurations
Apache installation and configurationsApache installation and configurations
Apache installation and configurations
 
Apache
ApacheApache
Apache
 
Using aphace-as-proxy-server
Using aphace-as-proxy-serverUsing aphace-as-proxy-server
Using aphace-as-proxy-server
 
Apache windows
Apache windowsApache windows
Apache windows
 
Installing lemp with ssl and varnish on Debian 9
Installing lemp with ssl and varnish on Debian 9Installing lemp with ssl and varnish on Debian 9
Installing lemp with ssl and varnish on Debian 9
 
WP Sandbox Presentation WordCamp Toronto 2011
WP Sandbox Presentation WordCamp Toronto 2011WP Sandbox Presentation WordCamp Toronto 2011
WP Sandbox Presentation WordCamp Toronto 2011
 
Installing Hortonworks Hadoop for Windows
Installing Hortonworks Hadoop for WindowsInstalling Hortonworks Hadoop for Windows
Installing Hortonworks Hadoop for Windows
 
Installing WordPress on AWS
Installing WordPress on AWSInstalling WordPress on AWS
Installing WordPress on AWS
 
Proxy
ProxyProxy
Proxy
 
Apache
ApacheApache
Apache
 

More from amikoenterprises

Within MySQL Workbench, create a new table. This table will be used .pdf
Within MySQL Workbench, create a new table. This table will be used .pdfWithin MySQL Workbench, create a new table. This table will be used .pdf
Within MySQL Workbench, create a new table. This table will be used .pdfamikoenterprises
 
Within the unethical leadership presentation, I talked a lot about t.pdf
Within the unethical leadership presentation, I talked a lot about t.pdfWithin the unethical leadership presentation, I talked a lot about t.pdf
Within the unethical leadership presentation, I talked a lot about t.pdfamikoenterprises
 
Write a C program to create two user-defined functions; first functi.pdf
Write a C program to create two user-defined functions; first functi.pdfWrite a C program to create two user-defined functions; first functi.pdf
Write a C program to create two user-defined functions; first functi.pdfamikoenterprises
 
Write a C# program that demonstrate your multi-level inheritance und.pdf
Write a C# program that demonstrate your multi-level inheritance und.pdfWrite a C# program that demonstrate your multi-level inheritance und.pdf
Write a C# program that demonstrate your multi-level inheritance und.pdfamikoenterprises
 
With reference to the above case, please answer all of the followi.pdf
With reference to the above case, please answer all of the followi.pdfWith reference to the above case, please answer all of the followi.pdf
With reference to the above case, please answer all of the followi.pdfamikoenterprises
 
WR Grace Company fue fundada por, s�, un hombre llamado WR Grace. Er.pdf
WR Grace Company fue fundada por, s�, un hombre llamado WR Grace. Er.pdfWR Grace Company fue fundada por, s�, un hombre llamado WR Grace. Er.pdf
WR Grace Company fue fundada por, s�, un hombre llamado WR Grace. Er.pdfamikoenterprises
 
without using truth table Unit I Logic and Proofs Question 1. Is.pdf
without using truth table  Unit I Logic and Proofs Question 1. Is.pdfwithout using truth table  Unit I Logic and Proofs Question 1. Is.pdf
without using truth table Unit I Logic and Proofs Question 1. Is.pdfamikoenterprises
 
William Short is chief executive officer (CEO) of Benton Memorial Ho.pdf
William Short is chief executive officer (CEO) of Benton Memorial Ho.pdfWilliam Short is chief executive officer (CEO) of Benton Memorial Ho.pdf
William Short is chief executive officer (CEO) of Benton Memorial Ho.pdfamikoenterprises
 
Word facilita el formato de texto usando negrita, cursiva y subrayad.pdf
Word facilita el formato de texto usando negrita, cursiva y subrayad.pdfWord facilita el formato de texto usando negrita, cursiva y subrayad.pdf
Word facilita el formato de texto usando negrita, cursiva y subrayad.pdfamikoenterprises
 
wo populations of beetles have different reproductive organs that ar.pdf
wo populations of beetles have different reproductive organs that ar.pdfwo populations of beetles have different reproductive organs that ar.pdf
wo populations of beetles have different reproductive organs that ar.pdfamikoenterprises
 
Wittes Tasty Fishes� Wittes Tasty Fishes� is an aquaculture compan.pdf
Wittes Tasty Fishes� Wittes Tasty Fishes� is an aquaculture compan.pdfWittes Tasty Fishes� Wittes Tasty Fishes� is an aquaculture compan.pdf
Wittes Tasty Fishes� Wittes Tasty Fishes� is an aquaculture compan.pdfamikoenterprises
 
Write the necessary SQL Queries for the following functions.A,Addi.pdf
Write the necessary SQL Queries for the following functions.A,Addi.pdfWrite the necessary SQL Queries for the following functions.A,Addi.pdf
Write the necessary SQL Queries for the following functions.A,Addi.pdfamikoenterprises
 
Write the necessary SQL Queries for the following functions.A. Add.pdf
Write the necessary SQL Queries for the following functions.A. Add.pdfWrite the necessary SQL Queries for the following functions.A. Add.pdf
Write the necessary SQL Queries for the following functions.A. Add.pdfamikoenterprises
 
Write the class named Student which has the following data members.pdf
Write the class named Student  which has the following data members.pdfWrite the class named Student  which has the following data members.pdf
Write the class named Student which has the following data members.pdfamikoenterprises
 
Write program in C language to sort the given array using merge sort.pdf
Write program in C language to sort the given array using merge sort.pdfWrite program in C language to sort the given array using merge sort.pdf
Write program in C language to sort the given array using merge sort.pdfamikoenterprises
 
Write notes on the following areas as related to tax investigations .pdf
Write notes on the following areas as related to tax investigations .pdfWrite notes on the following areas as related to tax investigations .pdf
Write notes on the following areas as related to tax investigations .pdfamikoenterprises
 
Write it in Assembly codeWrite it in Assembly codeWrite it in As.pdf
Write it in Assembly codeWrite it in Assembly codeWrite it in As.pdfWrite it in Assembly codeWrite it in Assembly codeWrite it in As.pdf
Write it in Assembly codeWrite it in Assembly codeWrite it in As.pdfamikoenterprises
 
Write MATLAB code to solve this summation in general, where you can .pdf
Write MATLAB code to solve this summation in general, where you can .pdfWrite MATLAB code to solve this summation in general, where you can .pdf
Write MATLAB code to solve this summation in general, where you can .pdfamikoenterprises
 
William es due�o de un solo barco. El barco vale 200 millones de d�l.pdf
William es due�o de un solo barco. El barco vale 200 millones de d�l.pdfWilliam es due�o de un solo barco. El barco vale 200 millones de d�l.pdf
William es due�o de un solo barco. El barco vale 200 millones de d�l.pdfamikoenterprises
 
write clear explanation please 4. Find the dimension and a basi.pdf
write clear explanation please 4. Find the dimension and a basi.pdfwrite clear explanation please 4. Find the dimension and a basi.pdf
write clear explanation please 4. Find the dimension and a basi.pdfamikoenterprises
 

More from amikoenterprises (20)

Within MySQL Workbench, create a new table. This table will be used .pdf
Within MySQL Workbench, create a new table. This table will be used .pdfWithin MySQL Workbench, create a new table. This table will be used .pdf
Within MySQL Workbench, create a new table. This table will be used .pdf
 
Within the unethical leadership presentation, I talked a lot about t.pdf
Within the unethical leadership presentation, I talked a lot about t.pdfWithin the unethical leadership presentation, I talked a lot about t.pdf
Within the unethical leadership presentation, I talked a lot about t.pdf
 
Write a C program to create two user-defined functions; first functi.pdf
Write a C program to create two user-defined functions; first functi.pdfWrite a C program to create two user-defined functions; first functi.pdf
Write a C program to create two user-defined functions; first functi.pdf
 
Write a C# program that demonstrate your multi-level inheritance und.pdf
Write a C# program that demonstrate your multi-level inheritance und.pdfWrite a C# program that demonstrate your multi-level inheritance und.pdf
Write a C# program that demonstrate your multi-level inheritance und.pdf
 
With reference to the above case, please answer all of the followi.pdf
With reference to the above case, please answer all of the followi.pdfWith reference to the above case, please answer all of the followi.pdf
With reference to the above case, please answer all of the followi.pdf
 
WR Grace Company fue fundada por, s�, un hombre llamado WR Grace. Er.pdf
WR Grace Company fue fundada por, s�, un hombre llamado WR Grace. Er.pdfWR Grace Company fue fundada por, s�, un hombre llamado WR Grace. Er.pdf
WR Grace Company fue fundada por, s�, un hombre llamado WR Grace. Er.pdf
 
without using truth table Unit I Logic and Proofs Question 1. Is.pdf
without using truth table  Unit I Logic and Proofs Question 1. Is.pdfwithout using truth table  Unit I Logic and Proofs Question 1. Is.pdf
without using truth table Unit I Logic and Proofs Question 1. Is.pdf
 
William Short is chief executive officer (CEO) of Benton Memorial Ho.pdf
William Short is chief executive officer (CEO) of Benton Memorial Ho.pdfWilliam Short is chief executive officer (CEO) of Benton Memorial Ho.pdf
William Short is chief executive officer (CEO) of Benton Memorial Ho.pdf
 
Word facilita el formato de texto usando negrita, cursiva y subrayad.pdf
Word facilita el formato de texto usando negrita, cursiva y subrayad.pdfWord facilita el formato de texto usando negrita, cursiva y subrayad.pdf
Word facilita el formato de texto usando negrita, cursiva y subrayad.pdf
 
wo populations of beetles have different reproductive organs that ar.pdf
wo populations of beetles have different reproductive organs that ar.pdfwo populations of beetles have different reproductive organs that ar.pdf
wo populations of beetles have different reproductive organs that ar.pdf
 
Wittes Tasty Fishes� Wittes Tasty Fishes� is an aquaculture compan.pdf
Wittes Tasty Fishes� Wittes Tasty Fishes� is an aquaculture compan.pdfWittes Tasty Fishes� Wittes Tasty Fishes� is an aquaculture compan.pdf
Wittes Tasty Fishes� Wittes Tasty Fishes� is an aquaculture compan.pdf
 
Write the necessary SQL Queries for the following functions.A,Addi.pdf
Write the necessary SQL Queries for the following functions.A,Addi.pdfWrite the necessary SQL Queries for the following functions.A,Addi.pdf
Write the necessary SQL Queries for the following functions.A,Addi.pdf
 
Write the necessary SQL Queries for the following functions.A. Add.pdf
Write the necessary SQL Queries for the following functions.A. Add.pdfWrite the necessary SQL Queries for the following functions.A. Add.pdf
Write the necessary SQL Queries for the following functions.A. Add.pdf
 
Write the class named Student which has the following data members.pdf
Write the class named Student  which has the following data members.pdfWrite the class named Student  which has the following data members.pdf
Write the class named Student which has the following data members.pdf
 
Write program in C language to sort the given array using merge sort.pdf
Write program in C language to sort the given array using merge sort.pdfWrite program in C language to sort the given array using merge sort.pdf
Write program in C language to sort the given array using merge sort.pdf
 
Write notes on the following areas as related to tax investigations .pdf
Write notes on the following areas as related to tax investigations .pdfWrite notes on the following areas as related to tax investigations .pdf
Write notes on the following areas as related to tax investigations .pdf
 
Write it in Assembly codeWrite it in Assembly codeWrite it in As.pdf
Write it in Assembly codeWrite it in Assembly codeWrite it in As.pdfWrite it in Assembly codeWrite it in Assembly codeWrite it in As.pdf
Write it in Assembly codeWrite it in Assembly codeWrite it in As.pdf
 
Write MATLAB code to solve this summation in general, where you can .pdf
Write MATLAB code to solve this summation in general, where you can .pdfWrite MATLAB code to solve this summation in general, where you can .pdf
Write MATLAB code to solve this summation in general, where you can .pdf
 
William es due�o de un solo barco. El barco vale 200 millones de d�l.pdf
William es due�o de un solo barco. El barco vale 200 millones de d�l.pdfWilliam es due�o de un solo barco. El barco vale 200 millones de d�l.pdf
William es due�o de un solo barco. El barco vale 200 millones de d�l.pdf
 
write clear explanation please 4. Find the dimension and a basi.pdf
write clear explanation please 4. Find the dimension and a basi.pdfwrite clear explanation please 4. Find the dimension and a basi.pdf
write clear explanation please 4. Find the dimension and a basi.pdf
 

Recently uploaded

Pharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfPharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfMahmoud M. Sallam
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
Biting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdfBiting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdfadityarao40181
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdfSoniaTolstoy
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
Final demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxFinal demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxAvyJaneVismanos
 
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17Celine George
 
Class 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfClass 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfakmcokerachita
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
internship ppt on smartinternz platform as salesforce developer
internship ppt on smartinternz platform as salesforce developerinternship ppt on smartinternz platform as salesforce developer
internship ppt on smartinternz platform as salesforce developerunnathinaik
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdfssuser54595a
 
Science 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its CharacteristicsScience 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its CharacteristicsKarinaGenton
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptxENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptxAnaBeatriceAblay2
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxGaneshChakor2
 

Recently uploaded (20)

Pharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfPharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdf
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
Biting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdfBiting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdf
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
Staff of Color (SOC) Retention Efforts DDSD
Staff of Color (SOC) Retention Efforts DDSDStaff of Color (SOC) Retention Efforts DDSD
Staff of Color (SOC) Retention Efforts DDSD
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
Final demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxFinal demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptx
 
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 
Class 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfClass 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdf
 
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdfTataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
internship ppt on smartinternz platform as salesforce developer
internship ppt on smartinternz platform as salesforce developerinternship ppt on smartinternz platform as salesforce developer
internship ppt on smartinternz platform as salesforce developer
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
 
Science 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its CharacteristicsScience 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its Characteristics
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptxENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
 

Working with Apache Web ServerTime Required 35 minutesObjective.pdf

  • 1. Working with Apache Web Server Time Required: 35 minutes Objective: Explore basic settings and tasks in Apache Web Server. Description: Without a doubt, youll run across Apache Web Server systems when conducting a security test. Because Apache is a sophisticated, modular Web server, mastering its features and options can take considerable time. Apaches layout varies, depending on the OS. For example, Apache in Fedora Linux is different from Apache in Ubuntu Linux. In this activity, you explore basic Apache Web Server commands and learn how to find and modify some configuration options (called Apache directives). The goal of this activity is to configure a Web server with a directory that requires authentication. 1. Boot your computer into Linux with the Kali Linux DVD. 2. Open a Terminal shell. At the command prompt, type apache2ctl start and press Enter. You can safely ignore the Could not reliably determine the servers fully qualified domain name error. 3. Start the Iceweasel Web browser. In the address bar, type localhost and press Enter. The Web site displays instructions on how to manipulate the default apache configuration. Read over this page. 4. Open a Terminal shell. At the command prompt, type apache2ctl stop and press Enter. 5. Now, well view the default apache configuration files. In the Terminal shell, type cd/etc/apache2 and press Enter to change directories. Then type grep Include apache2.conf and press Enter to see a listing of files and directories where the Apache server searches for additional directives at startup (see Figure 10-5). Note the next to last line, IncludeOptional sites-enabled/*.conf. This directory is where Apache checks for Web site configuration files. You can add a Web site by adding its configuration file in this directory without having to change the main configuration file apache2.conf. Figure 10-5 Viewing files and directories with an Include statement Source: GNU GPL 6.
  • 2. Type cd /etc/apache2/sites-enabled && ls and press Enter. 7. Open the file in the gvim editor by typing gvim 000-default.conf and pressing Enter. 8. Enter the following lines at the end of the file, below the line : 9. Save your changes and exit the gvim editor by pressing Esc, typing :wq, and pressing Enter. 10. In the Terminal shell, create a new directory by typing mkdir /var/www/html/restricted and pressing Enter. 11. Type cd /var/www/html/restricted to change to the directory you created in Step 12 and press Enter. Then type touch secret.txt and press Enter to create a file in this directory. 12. Next, you create the .htaccess file in the same directory. This file is the local directory configuration file specified in apache2.conf by the AccessFileName directive. If .htaccess exists in any Web site directory, Apache checks it first. In this .htaccess file, you point Apache to the location of AuthUserFile (essentially, a password file). Type gvim.htaccess and press Enter. Type the following for the files contents: 13. Exit and save the file by pressing Esc and then pressing : (a colon). At the : prompt, type wq and press Enter. In the Terminal shell, create a password file by typing htpasswd -c /etc/apache2/.htpasswd tester and pressing Enter. When prompted, enter a password and confirm, and then make note of the password. The .htaccess file you created in Step 12 tells Apache to look in the .htpasswd file for the tester users password. You can run the command cat/etc/apache2/.htpasswd to view the password hash for your new user. 14. Restart Apache by typing apache2ctl restart and pressing Enter. In Iceweasel, go to http://localhost/restricted, and enter the username tester and the password you confirmed in Step 13. What file is displayed? If you want to be prompted again for a password, youll have to close and reopen your browser. 15. See whether others in the class can access your restricted folder by having them enter http://yourIPaddress/restricted in their browsers (replacing yourIPaddress with your IP address).
  • 3. If necessary, type ifconfig eth0 and press Enter to find your IP address. 16. Why is entering your credentials on a Web site not secured with SSL, such as this site, a problem? What is the fix for this problem? 17. Close the Terminal shell, exit Firefox, and log off Linux for the next activity. Question 14 and 16