SlideShare a Scribd company logo
1 of 6
Using the application code in W1 Assignment 3, you will
further examine the potential for attack and defense in the areas
of input validation, access control, and session management.
Click here to access the code (you will need to modify the code
based on the questions below).
Create a report in a 2- to 3-page Microsoft Word document
addressing the following:
· Locate the PHP code for validating the user's login
information. Use the variables defined there to restrict the
content page to only those who have successfully logged into
the system.
· Describe how the session is managed from page to page in the
application. How long is the session active by default? What
conditions will end the session?
· Identify the form validation rules that need to be put in place
for the login form and the registration form. What format should
the data have? What is the maximum length of each item?
Identify the necessary functions in JavaScript and PHP to create
these validation rules and list them in your report.
Note: You will write the functions for the form validation in W3
Assignment 2, so the more you prepare now the simpler that
exercise will be.
Support your responses with examples.
Cite any sources in APA format.
RUNNING HEAD: The PHP Code 1
The PHP Code
Brandon Whitley
South University Online
ITS4221
April 7, 2015
Introduction
PHP is a server-side scripting language, which is specially
designed for development of websites. It is also used as a
general purpose programming language. PHP was originally
created in 1994, by Rasmus Randorf and was successfully
installed in over 240 million websites. Originally, PHP stood
for Personal Home page but is nowadays used to refer to
HypertextPreprocessor. The code can easily be used with a
combination of other engines or be mixed with HTML,
(Turland, 2011). This paper examines the potential for attack
and defense in the areas of input validation, access control and
session management.
Locate the PHP code for validating the user's login information.
Use the variables defined there to restrict the content page to
only those who have successfully logged into the system.
The PHP code used for validating user’s login information is
‘config.php’. First, the common code is executed to connection
to the database and for the session to start, the ‘common.php’
variable is required. At the top of the page, the process of
ensuring that the user is either logged in or out takes place. If
the user is not logged in, they are redirected to the log in page
with the header ‘location: login.php’. With this, it is crucial as
it permits only the accounts owner to view details in his or her
account and no trespass to other users’ account. The content in
the page is highly restricted to only those who have successfully
logged into the system. The variables used in PHP are presented
using the dollar sign followed by the name of the variable,
which is case sensitive. Variables used are: $var, $4site and
$tayte among others. In case the user enters a wrong email
address, the filter option displays certain information to
validate the codes and accept the sign in attempts.
Describe how the session is managed from page to page in the
application. How long is the session active by default? What
conditions will end the session?
Genuine account users will have all the information required for
log in details and provide them on time. Delays in this case, are
not flagged off, and the account may be suspended for a while
until further verifications are made by the rightful owner. After
the user enters the CAPTCHA code correctly, a database table is
designed to necessitate storage of the username, password,
account creation time, number r of log in attempts and last
logged in IP address. These are very crucial in determining who
logged in last in the system, (Tyson, 2014). The session is
active by default for a maximum of twenty four hours before
any sign out attempts are noted. This is the maximum amount of
time the account is expected to remain inactive before the
default pages are restored, for the purpose of data security.
Identify the form validation rules that need to be put in place
for the login form and the registration form. What format should
the data have? What is the maximum length of each item?
Identify the necessary functions in JavaScript and PHP to create
these validation rules and list them in your report.
By default, the validation framework expects the user to key in
information into selected or marked fields. Validation rules are
specified per action for example, the ‘action class’ where the
java class name of the action element is specified. Secondly, the
XML file is required to be placed in the class path (Leon,
2001). This is the same location as the action class where rules
are further specified using validators. The maximum length for
each item is six characters and the format entirely depends on
the data types used. Examples of validators are: field validators
and non-field validators.
References
Turland, M. (2011). PHP Master. London: Cengage learning.
Tyson, S. (2014). Decode the PHP Codes. New York:
Cambridge University Press.
Leon, A. (2001). Core PHP Programming. California: CRC
Press.
As you progress through the course, you will need a good
understanding of the files in this folder. There is guidance
below
on the database used for the login/registration application and a
list of files included. Pay attention to what files
should and should not be modified. Each modifiable file has
notes for code that should not be edited.
It is recommended that you view these files using Notepad++
(http://notepad-plus-plus.org/) or similar editor.
Database Structure:
email (Primary Key) - varchar(50) // Email address
fname - varchar(30) // First name
lname - varchar(30) // Last name
pw - varchar(20) // Password
id - varchar(50) // Session ID (Unix time value for valid
session)
Files:
// DO NOT EDIT:
index.html // Redirect page to index.php
index.php // Sets up application page
include/view.html // Result if login is successful and navigation
link is clicked - This is a test page
include/header.html // This sets the visual display of the page -
Review content for testing and validation rules
include/desc.html // This is the default page when no navigation
is active
// MODIFY AS NEEDED
include/main.js // This is the main JavaScript for the application
- you will add validation rules here
include/main.php // This is the main script of the application -
you will add validation and modifications here
Using the application code in W1 Assignment 3, you will
further examine the potential for attack and defense in the areas
of input validation, access control, and session management.
Click here to access the code (you will need to modify the code
based on the questions below).
Create a report in a 2- to 3-page Microsoft Word document
addressing the following:
· Locate the PHP code for validating the user's login
information. Use the variables defined there to restrict the
content page to only those who have successfully logged into
the system.
· Describe how the session is managed from page to page in the
application. How long is the session active by default? What
conditions will end the session?
· Identify the form validation rules that need to be put in place
for the login form and the registration form. What format should
the data have? What is the maximum length of each item?
Identify the necessary functions in JavaScript and PHP to create
these validation rules and list them in your report.
Note: You will write the functions for the form validation in W3
Assignment 2, so the more you prepare now the simpler that
exercise will be.
Support your responses with examples.
Cite any sources in APA format.

More Related Content

Similar to Using the application code in W1 Assignment 3, you will further ex.docx

Nt1330 Week 1 Case Study Of EAP.pdfNt1330 Week 1 Case Study Of EAP
Nt1330 Week 1 Case Study Of EAP.pdfNt1330 Week 1 Case Study Of EAPNt1330 Week 1 Case Study Of EAP.pdfNt1330 Week 1 Case Study Of EAP
Nt1330 Week 1 Case Study Of EAP.pdfNt1330 Week 1 Case Study Of EAPEvelyn Donaldson
 
Crime Reporting System.pptx
Crime Reporting System.pptxCrime Reporting System.pptx
Crime Reporting System.pptxPenilVora
 
Data Security String Manipulation by Random Value in Hypertext Preprocessor
Data Security String Manipulation by Random Value in Hypertext PreprocessorData Security String Manipulation by Random Value in Hypertext Preprocessor
Data Security String Manipulation by Random Value in Hypertext Preprocessorijtsrd
 
6 Week / Month Industrial Training in Hoshiarpur Punjab- PHP Project Report
6 Week / Month Industrial Training in Hoshiarpur Punjab- PHP Project Report 6 Week / Month Industrial Training in Hoshiarpur Punjab- PHP Project Report
6 Week / Month Industrial Training in Hoshiarpur Punjab- PHP Project Report c-tac
 
Authentication and Single Sing on
Authentication and Single Sing onAuthentication and Single Sing on
Authentication and Single Sing onguest648519
 
Chapter 1.Web Techniques_Notes.pptx
Chapter 1.Web Techniques_Notes.pptxChapter 1.Web Techniques_Notes.pptx
Chapter 1.Web Techniques_Notes.pptxShitalGhotekar
 
Medical Store Management System Software Engineering 1
Medical Store Management System Software Engineering 1Medical Store Management System Software Engineering 1
Medical Store Management System Software Engineering 1hani2253
 
Practical operability techniques for teams - Matthew Skelton - Agile in the C...
Practical operability techniques for teams - Matthew Skelton - Agile in the C...Practical operability techniques for teams - Matthew Skelton - Agile in the C...
Practical operability techniques for teams - Matthew Skelton - Agile in the C...Skelton Thatcher Consulting Ltd
 
Medical Store Management System Software Engineering Project
Medical Store Management System Software Engineering ProjectMedical Store Management System Software Engineering Project
Medical Store Management System Software Engineering Projecthani2253
 
Building enterprise web applications with spring 3
Building enterprise web applications with spring 3Building enterprise web applications with spring 3
Building enterprise web applications with spring 3Abdelmonaim Remani
 
IT 145 FINAL PROJECT GUIDELINES / TUTORIALOUTLET DOT COM
IT 145 FINAL PROJECT GUIDELINES / TUTORIALOUTLET DOT COMIT 145 FINAL PROJECT GUIDELINES / TUTORIALOUTLET DOT COM
IT 145 FINAL PROJECT GUIDELINES / TUTORIALOUTLET DOT COMalbert0061
 
1. Create and call a function to � Open a text file for storing the.pdf
1. Create and call a function to � Open a text file for storing the.pdf1. Create and call a function to � Open a text file for storing the.pdf
1. Create and call a function to � Open a text file for storing the.pdfagaramjareld
 
Php and web forms
Php and web formsPhp and web forms
Php and web formssana mateen
 

Similar to Using the application code in W1 Assignment 3, you will further ex.docx (20)

Nt1330 Week 1 Case Study Of EAP.pdfNt1330 Week 1 Case Study Of EAP
Nt1330 Week 1 Case Study Of EAP.pdfNt1330 Week 1 Case Study Of EAPNt1330 Week 1 Case Study Of EAP.pdfNt1330 Week 1 Case Study Of EAP
Nt1330 Week 1 Case Study Of EAP.pdfNt1330 Week 1 Case Study Of EAP
 
Job portal
Job portalJob portal
Job portal
 
Yeshwanth - Resume
Yeshwanth - ResumeYeshwanth - Resume
Yeshwanth - Resume
 
BMS-PPT-7viyvv.pptx
BMS-PPT-7viyvv.pptxBMS-PPT-7viyvv.pptx
BMS-PPT-7viyvv.pptx
 
Crime Reporting System.pptx
Crime Reporting System.pptxCrime Reporting System.pptx
Crime Reporting System.pptx
 
2 . web app s canners
2 . web app s canners2 . web app s canners
2 . web app s canners
 
Data Security String Manipulation by Random Value in Hypertext Preprocessor
Data Security String Manipulation by Random Value in Hypertext PreprocessorData Security String Manipulation by Random Value in Hypertext Preprocessor
Data Security String Manipulation by Random Value in Hypertext Preprocessor
 
6 Week / Month Industrial Training in Hoshiarpur Punjab- PHP Project Report
6 Week / Month Industrial Training in Hoshiarpur Punjab- PHP Project Report 6 Week / Month Industrial Training in Hoshiarpur Punjab- PHP Project Report
6 Week / Month Industrial Training in Hoshiarpur Punjab- PHP Project Report
 
Authentication and Single Sing on
Authentication and Single Sing onAuthentication and Single Sing on
Authentication and Single Sing on
 
Chapter 1.Web Techniques_Notes.pptx
Chapter 1.Web Techniques_Notes.pptxChapter 1.Web Techniques_Notes.pptx
Chapter 1.Web Techniques_Notes.pptx
 
Medical Store Management System Software Engineering 1
Medical Store Management System Software Engineering 1Medical Store Management System Software Engineering 1
Medical Store Management System Software Engineering 1
 
Practical operability techniques for teams - Matthew Skelton - Agile in the C...
Practical operability techniques for teams - Matthew Skelton - Agile in the C...Practical operability techniques for teams - Matthew Skelton - Agile in the C...
Practical operability techniques for teams - Matthew Skelton - Agile in the C...
 
Medical Store Management System Software Engineering Project
Medical Store Management System Software Engineering ProjectMedical Store Management System Software Engineering Project
Medical Store Management System Software Engineering Project
 
Building enterprise web applications with spring 3
Building enterprise web applications with spring 3Building enterprise web applications with spring 3
Building enterprise web applications with spring 3
 
IT 145 FINAL PROJECT GUIDELINES / TUTORIALOUTLET DOT COM
IT 145 FINAL PROJECT GUIDELINES / TUTORIALOUTLET DOT COMIT 145 FINAL PROJECT GUIDELINES / TUTORIALOUTLET DOT COM
IT 145 FINAL PROJECT GUIDELINES / TUTORIALOUTLET DOT COM
 
1. Create and call a function to � Open a text file for storing the.pdf
1. Create and call a function to � Open a text file for storing the.pdf1. Create and call a function to � Open a text file for storing the.pdf
1. Create and call a function to � Open a text file for storing the.pdf
 
Bitrix Intranet Portal
Bitrix Intranet PortalBitrix Intranet Portal
Bitrix Intranet Portal
 
student supervision system
student supervision systemstudent supervision system
student supervision system
 
Php and web forms
Php and web formsPhp and web forms
Php and web forms
 
User stories through Five W's technique
User stories through Five W's  techniqueUser stories through Five W's  technique
User stories through Five W's technique
 

More from dickonsondorris

Copyright © eContent Management Pty Ltd. Health Sociology Revi.docx
Copyright © eContent Management Pty Ltd. Health Sociology Revi.docxCopyright © eContent Management Pty Ltd. Health Sociology Revi.docx
Copyright © eContent Management Pty Ltd. Health Sociology Revi.docxdickonsondorris
 
Copyright © Pearson Education 2010 Digital Tools in Toda.docx
Copyright © Pearson Education 2010 Digital Tools in Toda.docxCopyright © Pearson Education 2010 Digital Tools in Toda.docx
Copyright © Pearson Education 2010 Digital Tools in Toda.docxdickonsondorris
 
Copyright © Jen-Wen Lin 2018 1 STA457 Time series .docx
Copyright © Jen-Wen Lin 2018   1 STA457 Time series .docxCopyright © Jen-Wen Lin 2018   1 STA457 Time series .docx
Copyright © Jen-Wen Lin 2018 1 STA457 Time series .docxdickonsondorris
 
Copyright © John Wiley & Sons, Inc. All rights reserved..docx
Copyright © John Wiley & Sons, Inc. All rights reserved..docxCopyright © John Wiley & Sons, Inc. All rights reserved..docx
Copyright © John Wiley & Sons, Inc. All rights reserved..docxdickonsondorris
 
Copyright © by The McGraw-Hill Companies, Inc. The Aztec Accou.docx
Copyright © by The McGraw-Hill Companies, Inc. The Aztec Accou.docxCopyright © by The McGraw-Hill Companies, Inc. The Aztec Accou.docx
Copyright © by The McGraw-Hill Companies, Inc. The Aztec Accou.docxdickonsondorris
 
Copyright © Cengage Learning. All rights reserved. CHAPTE.docx
Copyright © Cengage Learning.  All rights reserved. CHAPTE.docxCopyright © Cengage Learning.  All rights reserved. CHAPTE.docx
Copyright © Cengage Learning. All rights reserved. CHAPTE.docxdickonsondorris
 
Copyright © by Holt, Rinehart and Winston. All rights reserved.docx
Copyright © by Holt, Rinehart and Winston. All rights reserved.docxCopyright © by Holt, Rinehart and Winston. All rights reserved.docx
Copyright © by Holt, Rinehart and Winston. All rights reserved.docxdickonsondorris
 
Copyright © 2020 by Jones & Bartlett Learning, LLC, an Ascend .docx
Copyright © 2020 by Jones & Bartlett Learning, LLC, an Ascend .docxCopyright © 2020 by Jones & Bartlett Learning, LLC, an Ascend .docx
Copyright © 2020 by Jones & Bartlett Learning, LLC, an Ascend .docxdickonsondorris
 
Copyright © 2019, American Institute of Certified Public Accou.docx
Copyright © 2019, American Institute of Certified Public Accou.docxCopyright © 2019, American Institute of Certified Public Accou.docx
Copyright © 2019, American Institute of Certified Public Accou.docxdickonsondorris
 
Copyright © 2018 Pearson Education, Inc. All Rights ReservedChild .docx
Copyright © 2018 Pearson Education, Inc. All Rights ReservedChild .docxCopyright © 2018 Pearson Education, Inc. All Rights ReservedChild .docx
Copyright © 2018 Pearson Education, Inc. All Rights ReservedChild .docxdickonsondorris
 
Copyright © 2018 Pearson Education, Inc. C H A P T E R 6.docx
Copyright © 2018 Pearson Education, Inc. C H A P T E R  6.docxCopyright © 2018 Pearson Education, Inc. C H A P T E R  6.docx
Copyright © 2018 Pearson Education, Inc. C H A P T E R 6.docxdickonsondorris
 
Copyright © 2018 Capella University. Copy and distribution o.docx
Copyright © 2018 Capella University. Copy and distribution o.docxCopyright © 2018 Capella University. Copy and distribution o.docx
Copyright © 2018 Capella University. Copy and distribution o.docxdickonsondorris
 
Copyright © 2018 Pearson Education, Inc.C H A P T E R 3.docx
Copyright © 2018 Pearson Education, Inc.C H A P T E R  3.docxCopyright © 2018 Pearson Education, Inc.C H A P T E R  3.docx
Copyright © 2018 Pearson Education, Inc.C H A P T E R 3.docxdickonsondorris
 
Copyright © 2018 by Steven Levitsky and Daniel.docx
Copyright © 2018 by Steven Levitsky and Daniel.docxCopyright © 2018 by Steven Levitsky and Daniel.docx
Copyright © 2018 by Steven Levitsky and Daniel.docxdickonsondorris
 
Copyright © 2017, 2014, 2011 Pearson Education, Inc. All Right.docx
Copyright © 2017, 2014, 2011 Pearson Education, Inc. All Right.docxCopyright © 2017, 2014, 2011 Pearson Education, Inc. All Right.docx
Copyright © 2017, 2014, 2011 Pearson Education, Inc. All Right.docxdickonsondorris
 
Copyright © 2017 Wolters Kluwer Health Lippincott Williams.docx
Copyright © 2017 Wolters Kluwer Health  Lippincott Williams.docxCopyright © 2017 Wolters Kluwer Health  Lippincott Williams.docx
Copyright © 2017 Wolters Kluwer Health Lippincott Williams.docxdickonsondorris
 
Copyright © 2016, 2013, 2010 Pearson Education, Inc. All Right.docx
Copyright © 2016, 2013, 2010 Pearson Education, Inc. All Right.docxCopyright © 2016, 2013, 2010 Pearson Education, Inc. All Right.docx
Copyright © 2016, 2013, 2010 Pearson Education, Inc. All Right.docxdickonsondorris
 
Copyright © 2017 by University of Phoenix. All rights rese.docx
Copyright © 2017 by University of Phoenix. All rights rese.docxCopyright © 2017 by University of Phoenix. All rights rese.docx
Copyright © 2017 by University of Phoenix. All rights rese.docxdickonsondorris
 
Copyright © 2016 John Wiley & Sons, Inc.Copyright © 20.docx
Copyright © 2016 John Wiley & Sons, Inc.Copyright © 20.docxCopyright © 2016 John Wiley & Sons, Inc.Copyright © 20.docx
Copyright © 2016 John Wiley & Sons, Inc.Copyright © 20.docxdickonsondorris
 
Copyright © 2016 Pearson Education, Inc. .docx
Copyright © 2016 Pearson Education, Inc.                    .docxCopyright © 2016 Pearson Education, Inc.                    .docx
Copyright © 2016 Pearson Education, Inc. .docxdickonsondorris
 

More from dickonsondorris (20)

Copyright © eContent Management Pty Ltd. Health Sociology Revi.docx
Copyright © eContent Management Pty Ltd. Health Sociology Revi.docxCopyright © eContent Management Pty Ltd. Health Sociology Revi.docx
Copyright © eContent Management Pty Ltd. Health Sociology Revi.docx
 
Copyright © Pearson Education 2010 Digital Tools in Toda.docx
Copyright © Pearson Education 2010 Digital Tools in Toda.docxCopyright © Pearson Education 2010 Digital Tools in Toda.docx
Copyright © Pearson Education 2010 Digital Tools in Toda.docx
 
Copyright © Jen-Wen Lin 2018 1 STA457 Time series .docx
Copyright © Jen-Wen Lin 2018   1 STA457 Time series .docxCopyright © Jen-Wen Lin 2018   1 STA457 Time series .docx
Copyright © Jen-Wen Lin 2018 1 STA457 Time series .docx
 
Copyright © John Wiley & Sons, Inc. All rights reserved..docx
Copyright © John Wiley & Sons, Inc. All rights reserved..docxCopyright © John Wiley & Sons, Inc. All rights reserved..docx
Copyright © John Wiley & Sons, Inc. All rights reserved..docx
 
Copyright © by The McGraw-Hill Companies, Inc. The Aztec Accou.docx
Copyright © by The McGraw-Hill Companies, Inc. The Aztec Accou.docxCopyright © by The McGraw-Hill Companies, Inc. The Aztec Accou.docx
Copyright © by The McGraw-Hill Companies, Inc. The Aztec Accou.docx
 
Copyright © Cengage Learning. All rights reserved. CHAPTE.docx
Copyright © Cengage Learning.  All rights reserved. CHAPTE.docxCopyright © Cengage Learning.  All rights reserved. CHAPTE.docx
Copyright © Cengage Learning. All rights reserved. CHAPTE.docx
 
Copyright © by Holt, Rinehart and Winston. All rights reserved.docx
Copyright © by Holt, Rinehart and Winston. All rights reserved.docxCopyright © by Holt, Rinehart and Winston. All rights reserved.docx
Copyright © by Holt, Rinehart and Winston. All rights reserved.docx
 
Copyright © 2020 by Jones & Bartlett Learning, LLC, an Ascend .docx
Copyright © 2020 by Jones & Bartlett Learning, LLC, an Ascend .docxCopyright © 2020 by Jones & Bartlett Learning, LLC, an Ascend .docx
Copyright © 2020 by Jones & Bartlett Learning, LLC, an Ascend .docx
 
Copyright © 2019, American Institute of Certified Public Accou.docx
Copyright © 2019, American Institute of Certified Public Accou.docxCopyright © 2019, American Institute of Certified Public Accou.docx
Copyright © 2019, American Institute of Certified Public Accou.docx
 
Copyright © 2018 Pearson Education, Inc. All Rights ReservedChild .docx
Copyright © 2018 Pearson Education, Inc. All Rights ReservedChild .docxCopyright © 2018 Pearson Education, Inc. All Rights ReservedChild .docx
Copyright © 2018 Pearson Education, Inc. All Rights ReservedChild .docx
 
Copyright © 2018 Pearson Education, Inc. C H A P T E R 6.docx
Copyright © 2018 Pearson Education, Inc. C H A P T E R  6.docxCopyright © 2018 Pearson Education, Inc. C H A P T E R  6.docx
Copyright © 2018 Pearson Education, Inc. C H A P T E R 6.docx
 
Copyright © 2018 Capella University. Copy and distribution o.docx
Copyright © 2018 Capella University. Copy and distribution o.docxCopyright © 2018 Capella University. Copy and distribution o.docx
Copyright © 2018 Capella University. Copy and distribution o.docx
 
Copyright © 2018 Pearson Education, Inc.C H A P T E R 3.docx
Copyright © 2018 Pearson Education, Inc.C H A P T E R  3.docxCopyright © 2018 Pearson Education, Inc.C H A P T E R  3.docx
Copyright © 2018 Pearson Education, Inc.C H A P T E R 3.docx
 
Copyright © 2018 by Steven Levitsky and Daniel.docx
Copyright © 2018 by Steven Levitsky and Daniel.docxCopyright © 2018 by Steven Levitsky and Daniel.docx
Copyright © 2018 by Steven Levitsky and Daniel.docx
 
Copyright © 2017, 2014, 2011 Pearson Education, Inc. All Right.docx
Copyright © 2017, 2014, 2011 Pearson Education, Inc. All Right.docxCopyright © 2017, 2014, 2011 Pearson Education, Inc. All Right.docx
Copyright © 2017, 2014, 2011 Pearson Education, Inc. All Right.docx
 
Copyright © 2017 Wolters Kluwer Health Lippincott Williams.docx
Copyright © 2017 Wolters Kluwer Health  Lippincott Williams.docxCopyright © 2017 Wolters Kluwer Health  Lippincott Williams.docx
Copyright © 2017 Wolters Kluwer Health Lippincott Williams.docx
 
Copyright © 2016, 2013, 2010 Pearson Education, Inc. All Right.docx
Copyright © 2016, 2013, 2010 Pearson Education, Inc. All Right.docxCopyright © 2016, 2013, 2010 Pearson Education, Inc. All Right.docx
Copyright © 2016, 2013, 2010 Pearson Education, Inc. All Right.docx
 
Copyright © 2017 by University of Phoenix. All rights rese.docx
Copyright © 2017 by University of Phoenix. All rights rese.docxCopyright © 2017 by University of Phoenix. All rights rese.docx
Copyright © 2017 by University of Phoenix. All rights rese.docx
 
Copyright © 2016 John Wiley & Sons, Inc.Copyright © 20.docx
Copyright © 2016 John Wiley & Sons, Inc.Copyright © 20.docxCopyright © 2016 John Wiley & Sons, Inc.Copyright © 20.docx
Copyright © 2016 John Wiley & Sons, Inc.Copyright © 20.docx
 
Copyright © 2016 Pearson Education, Inc. .docx
Copyright © 2016 Pearson Education, Inc.                    .docxCopyright © 2016 Pearson Education, Inc.                    .docx
Copyright © 2016 Pearson Education, Inc. .docx
 

Recently uploaded

Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxthorishapillay1
 
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
 
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,Virag Sontakke
 
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxHistory Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxsocialsciencegdgrohi
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentInMediaRes1
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxiammrhaywood
 
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
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationnomboosow
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon AUnboundStockton
 
Painted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaPainted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaVirag Sontakke
 
Presiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsPresiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsanshu789521
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfSumit Tiwari
 
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxEPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxRaymartEstabillo3
 
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
 
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...M56BOOKSTORE PRODUCT/SERVICE
 

Recently uploaded (20)

Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptx
 
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
 
ESSENTIAL of (CS/IT/IS) class 06 (database)
ESSENTIAL of (CS/IT/IS) class 06 (database)ESSENTIAL of (CS/IT/IS) class 06 (database)
ESSENTIAL of (CS/IT/IS) class 06 (database)
 
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🔝
 
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
 
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxHistory Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media Component
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.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
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communication
 
OS-operating systems- ch04 (Threads) ...
OS-operating systems- ch04 (Threads) ...OS-operating systems- ch04 (Threads) ...
OS-operating systems- ch04 (Threads) ...
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon A
 
Painted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of IndiaPainted Grey Ware.pptx, PGW Culture of India
Painted Grey Ware.pptx, PGW Culture of India
 
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
 
Presiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsPresiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha elections
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
 
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxEPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.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
 
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
 

Using the application code in W1 Assignment 3, you will further ex.docx

  • 1. Using the application code in W1 Assignment 3, you will further examine the potential for attack and defense in the areas of input validation, access control, and session management. Click here to access the code (you will need to modify the code based on the questions below). Create a report in a 2- to 3-page Microsoft Word document addressing the following: · Locate the PHP code for validating the user's login information. Use the variables defined there to restrict the content page to only those who have successfully logged into the system. · Describe how the session is managed from page to page in the application. How long is the session active by default? What conditions will end the session? · Identify the form validation rules that need to be put in place for the login form and the registration form. What format should the data have? What is the maximum length of each item? Identify the necessary functions in JavaScript and PHP to create these validation rules and list them in your report. Note: You will write the functions for the form validation in W3 Assignment 2, so the more you prepare now the simpler that exercise will be. Support your responses with examples. Cite any sources in APA format. RUNNING HEAD: The PHP Code 1
  • 2. The PHP Code Brandon Whitley South University Online ITS4221 April 7, 2015 Introduction PHP is a server-side scripting language, which is specially designed for development of websites. It is also used as a general purpose programming language. PHP was originally created in 1994, by Rasmus Randorf and was successfully installed in over 240 million websites. Originally, PHP stood for Personal Home page but is nowadays used to refer to HypertextPreprocessor. The code can easily be used with a combination of other engines or be mixed with HTML, (Turland, 2011). This paper examines the potential for attack and defense in the areas of input validation, access control and session management. Locate the PHP code for validating the user's login information. Use the variables defined there to restrict the content page to only those who have successfully logged into the system. The PHP code used for validating user’s login information is ‘config.php’. First, the common code is executed to connection to the database and for the session to start, the ‘common.php’ variable is required. At the top of the page, the process of ensuring that the user is either logged in or out takes place. If the user is not logged in, they are redirected to the log in page with the header ‘location: login.php’. With this, it is crucial as it permits only the accounts owner to view details in his or her account and no trespass to other users’ account. The content in
  • 3. the page is highly restricted to only those who have successfully logged into the system. The variables used in PHP are presented using the dollar sign followed by the name of the variable, which is case sensitive. Variables used are: $var, $4site and $tayte among others. In case the user enters a wrong email address, the filter option displays certain information to validate the codes and accept the sign in attempts. Describe how the session is managed from page to page in the application. How long is the session active by default? What conditions will end the session? Genuine account users will have all the information required for log in details and provide them on time. Delays in this case, are not flagged off, and the account may be suspended for a while until further verifications are made by the rightful owner. After the user enters the CAPTCHA code correctly, a database table is designed to necessitate storage of the username, password, account creation time, number r of log in attempts and last logged in IP address. These are very crucial in determining who logged in last in the system, (Tyson, 2014). The session is active by default for a maximum of twenty four hours before any sign out attempts are noted. This is the maximum amount of time the account is expected to remain inactive before the default pages are restored, for the purpose of data security. Identify the form validation rules that need to be put in place for the login form and the registration form. What format should the data have? What is the maximum length of each item? Identify the necessary functions in JavaScript and PHP to create these validation rules and list them in your report. By default, the validation framework expects the user to key in information into selected or marked fields. Validation rules are specified per action for example, the ‘action class’ where the java class name of the action element is specified. Secondly, the XML file is required to be placed in the class path (Leon, 2001). This is the same location as the action class where rules are further specified using validators. The maximum length for each item is six characters and the format entirely depends on
  • 4. the data types used. Examples of validators are: field validators and non-field validators. References Turland, M. (2011). PHP Master. London: Cengage learning. Tyson, S. (2014). Decode the PHP Codes. New York: Cambridge University Press. Leon, A. (2001). Core PHP Programming. California: CRC Press. As you progress through the course, you will need a good understanding of the files in this folder. There is guidance below on the database used for the login/registration application and a list of files included. Pay attention to what files should and should not be modified. Each modifiable file has notes for code that should not be edited. It is recommended that you view these files using Notepad++ (http://notepad-plus-plus.org/) or similar editor. Database Structure: email (Primary Key) - varchar(50) // Email address fname - varchar(30) // First name lname - varchar(30) // Last name pw - varchar(20) // Password id - varchar(50) // Session ID (Unix time value for valid session) Files: // DO NOT EDIT: index.html // Redirect page to index.php index.php // Sets up application page
  • 5. include/view.html // Result if login is successful and navigation link is clicked - This is a test page include/header.html // This sets the visual display of the page - Review content for testing and validation rules include/desc.html // This is the default page when no navigation is active // MODIFY AS NEEDED include/main.js // This is the main JavaScript for the application - you will add validation rules here include/main.php // This is the main script of the application - you will add validation and modifications here Using the application code in W1 Assignment 3, you will further examine the potential for attack and defense in the areas of input validation, access control, and session management. Click here to access the code (you will need to modify the code based on the questions below). Create a report in a 2- to 3-page Microsoft Word document addressing the following: · Locate the PHP code for validating the user's login information. Use the variables defined there to restrict the content page to only those who have successfully logged into the system. · Describe how the session is managed from page to page in the application. How long is the session active by default? What conditions will end the session? · Identify the form validation rules that need to be put in place for the login form and the registration form. What format should the data have? What is the maximum length of each item? Identify the necessary functions in JavaScript and PHP to create these validation rules and list them in your report. Note: You will write the functions for the form validation in W3 Assignment 2, so the more you prepare now the simpler that
  • 6. exercise will be. Support your responses with examples. Cite any sources in APA format.