Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 12

DFD Diagram and other Documentation

Login system data flow

1. Form takes user name and password from the user and sends for authentication page. 2. The authentication page takes the data and verify the data coming with the values present in the database 3. The password present in the data-base is present in encrypted form using MD5 hashing algorithm. 4. The password from the users end is hashed and then matched with the password stored in the database, and if they match the user level is retrieved from the database, else the user is redirected to login page with an error message. 5. After retrieval of the user level the user is identified as a client user or as an Admin user. 6. Once the level of user is finalized, a corresponding page is displayed viz, for client (his credentials and other stored data), and for admin a control panel is displayed.

DFD Diagram

Modules wise description

Snap shots for the app developed so far: Login:

After login as administrator :

Registration page:

User management page:

Forgot password:

The Advantages of PHP


PHP is one of the most popular server side scripting languages running today. It is used for creating dynamic webpages that interact with the user offering customized information. PHP offers many advantages; it is fast, stable, secure, easy to use and open source (free). Rasmus Lerdorf wrote the first PHP (first called Personal Home Page) scripts as a series of Perl scripts that he used to track visitors to his webpage and to see who was viewing his resume. He eventually rewrote PHP as a scripting engine and added support for forms. PHP has been evolving since 1994 as an open source code. A community of followers and developers formed and began using and further developing PHP. Over the years the Personal Home Page acronym was dropped and it evolved into the PHP Hypertext Preprocessor.

About the Hashing algorithm used in login system

The MD5 Message-Digest Algorithm is a widely used cryptographic hash function that produces a 128-bit (16byte) hash value. Specified in RFC 1321, MD5 has been employed in a wide variety of security applications, and is also commonly used to check data integrity. However, it has been shown that MD5 is not collision resistant;[3] as such, MD5 is not suitable for applications like SSL certificates or digital signatures that rely on this property. An MD5 hash is typically expressed as a 32-digit hexadecimal number.

Algorithm

Figure 1. One MD5 operation. MD5 consists of 64 of these operations, grouped in four rounds of 16 operations. F is a nonlinear function; one function is used in each round. Midenotes a 32-bit block of the message input, and Ki denotes a

32-bit constant, different for each operation. denotes addition modulo 2 .


32

denotes a left bit rotation by s places; s varies for each operation.

MD5 processes a variable-length message into a fixed-length output of 128 bits. The input message is broken up into chunks of 512-bit blocks (sixteen 32-bit little endian integers); the message is padded so that its length is divisible by 512. The padding works as follows: first a single bit, 1, is appended to the end of the message. This is followed by as many zeros as are required to bring the length of the message up to 64 bits fewer than a multiple of 512. The remaining bits are filled up with a 64-bit little endian integer representing the length of the original message, in bits. The main MD5 algorithm operates on a 128-bit state, divided into four 32-bit words, denoted A, B, C and D. These are initialized to certain fixed constants. The main algorithm then operates on each 512bit message block in turn, each block modifying the state. The processing of a message block consists of four similar stages, termed rounds; each round is composed of 16 similar operations based on a non-linear functionF, modular addition, and left rotation. Figure 1 illustrates one operation within a round. There are four possible functions F; a different one is used in each round:

denote the XOR, AND, OR and NOT operations respectively.

The MD5 hash is calculated according to this algorithm:

Pseudo code
//Note: All variables are unsigned 32 bits and wrap modulo 2^32 when calculating var int[64] r, k //r specifies the per-round shift amounts r[ 0..15] := {7, 12, 17, 22, 7, 12, 17, 22, 7, 12, 17, 22, 7, 12, 17, 22} r[16..31] := {5, 9, 14, 20, 5, 9, 14, 20, 5, 9, 14, 20, 5, 9, 14, 20} r[32..47] := {4, 11, 16, 23, 4, 11, 16, 23, 4, 11, 16, 23, 4, 11, 16, 23} r[48..63] := {6, 10, 15, 21, 6, 10, 15, 21, 6, 10, 15, 21, 6, 10, 15, 21} //Use binary integer part of the sines of integers (Radians) as constants: for i from 0 to 63 k[i] := floor(abs(sin(i + 1)) (2 pow 32)) end for //(Or just use the following table):

k[ 0.. 3] := { 0xd76aa478, 0xe8c7b756, 0x242070db, 0xc1bdceee } k[ 4.. 7] := { 0xf57c0faf, 0x4787c62a, 0xa8304613, 0xfd469501 } k[ 8..11] := { 0x698098d8, 0x8b44f7af, 0xffff5bb1, 0x895cd7be } k[12..15] := { 0x6b901122, 0xfd987193, 0xa679438e, 0x49b40821 } k[16..19] := { 0xf61e2562, 0xc040b340, 0x265e5a51, 0xe9b6c7aa } k[20..23] := { 0xd62f105d, 0x02441453, 0xd8a1e681, 0xe7d3fbc8 } k[24..27] := { 0x21e1cde6, 0xc33707d6, 0xf4d50d87, 0x455a14ed } k[28..31] := { 0xa9e3e905, 0xfcefa3f8, 0x676f02d9, 0x8d2a4c8a } k[32..35] := { 0xfffa3942, 0x8771f681, 0x6d9d6122, 0xfde5380c } k[36..39] := { 0xa4beea44, 0x4bdecfa9, 0xf6bb4b60, 0xbebfbc70 } k[40..43] := { 0x289b7ec6, 0xeaa127fa, 0xd4ef3085, 0x04881d05 } k[44..47] := { 0xd9d4d039, 0xe6db99e5, 0x1fa27cf8, 0xc4ac5665 } k[48..51] := { 0xf4292244, 0x432aff97, 0xab9423a7, 0xfc93a039 } k[52..55] := { 0x655b59c3, 0x8f0ccc92, 0xffeff47d, 0x85845dd1 } k[56..59] := { 0x6fa87e4f, 0xfe2ce6e0, 0xa3014314, 0x4e0811a1 } k[60..63] := { 0xf7537e82, 0xbd3af235, 0x2ad7d2bb, 0xeb86d391 } //Initialize variables: var int h0 := 0x67452301 var int h1 := 0xEFCDAB89 var int h2 := 0x98BADCFE var int h3 := 0x10325476 //Pre-processing: append "1" bit to message append "0" bits until message length in bits 448 (mod 512) append length to message /* bit (not byte) length of unpadded message as 64-bit little-endian integer */ //Process the message in successive 512-bit chunks: for each 512-bit chunk of message break chunk into sixteen 32-bit little-endian words w[j], 0 j 15 //Initialize hash value for this chunk: var int a := h0 var int b := h1 var int c := h2 var int d := h3 //Main loop: for i from 0 to 63 if 0 i 15 then f := (b and c) or ((not b) and d) g := i else if 16 i 31 f := (d and b) or ((not d) and c) g := (5i + 1) mod 16

else if 32 i 47 f := b xor c xor d g := (3i + 5) mod 16 else if 48 i 63 f := c xor (b or (not d)) g := (7i) mod 16 temp := d d := c c := b b := b + leftrotate((a + f + k[i] + w[g]) , r[i]) a := temp end for //Add this chunk's hash to result so far: h0 := h0 + a h1 := h1 + b h2 := h2 + c h3 := h3 + d end for var char digest[16] := h0 append h1 append h2 append h3 //(expressed as little-endian) //leftrotate function definition leftrotate (x, c) return (x << c) or (x >> (32-c));

S.R.S Requirements Analysis and Specification


Software/Hardware Requirements
Hardware Requirements
Minimum Hardware and Software requirements are not always the optimal Choice for ease of use, performance, and overall product enjoyment. It is recommended that the following system profile implementation. Personal computer Pen drive CPU(central processing unit) Speaker Mouse

Random Access Memory:32MB RAM(64 MB recommended) Display: 16 bit colour Hard disk space:10 MB free space on the hard disk 2. Software Requirements Following are the few software specifications that are used in the project. MySQL PHP

We have used PHPand MySQL which consists of comprehensive set of application building and user product. MySQL Database The MySQL database has become the worlds most popular open source database because of its consistent fast performance, high reliability and ease of use. Its used on every continentyes, even Antarctica!by individual Web developers as well as many of the worlds largest and fastest-growing organisations to save time and money powering their high-volume Websites, business-critical systems and packaged softwareincluding industry leaders such as Yahoo!,Alcatel-Lucent,Google,Nokia,You Tube, and Zappos.com. Not only is MySQL the worlds most popular open source database, its also become the database of choice for a new generation of applications built on the LAMP stack (Linux,Apache,MySQL,PHP,Peral,python).MySQL runs on more than 20 platforms including Linux,Windows,OS/X,HPUX,AIX,Netware,giving you the kind of flexibility that puts you in control. As on April 2009, MySQL offers MySQL 5.1 in two different variants: the MySQL Community Server and Enterprise Server. They have a common code base and include the following features: A broad subset of ANSI SQL 99,as well as extensions Cross-platform supports Stored procedures Triggers Cursors Updatable Views True Varchar supports Information schema and many more. PHP :

Speed -- not only the speed of execution, which is important, but also that it not slow down the rest of the machine. So it should not demand a lot of system resources. PHP integrates well with other software, especially under UNIX's, has a small footprint and when run as an Apache module is already loaded for use. Plus, PHP is a thin wrapper around many operating system calls, so can be very fast. Stability -- its no good being fast if the system crashes every few thousand pages. No application is bug free, but having a community of PHP developers and users makes it much harder for bugs to survive for long. Under the hood, PHP uses its own resource management system, and has a sophisticated method for handling variables, making it intrinsically a robust system. Security -- the system should be protected from malicious attacks from users, both as programmers and as surfers. PHP provides many levels of security which can be set in the .ini file to the desired level. Simplicity -- programmers should be able to start being productive as soon as possible. With PHP, even HTML coders can start integrating PHP into their pages straight away. Programmers with previous experience of C, or even with Javascript can get up to speed very quickly. Connect ability Because of PHP's modular system of extensions it will interface with many diverse libraries, and adding further extensions is very simple. This allows PHP to make use of specialised working libraries from many different areas, such as encryption, graphics, XML and so on.

Further advantages of PHP.

PHP will run on (almost) any platform. Using the same code base, PHP can be compiled and built on about 25 platforms, including most UNIXs, Windows(95/98/NT/2000) and Macs. As this uses the same code base, all scripts will run identically, whatever the platform. PHP is similar to C. So anyone who has experience with a C-style language will soon understand PHP. In C-style languages we can also include Javascript and Java. In fact, much of PHP's functionality is provided by wrappers around the underlying system calls (such as fread() and strlen()) so C programmers will immediately feel at home. PHP is extendible. PHP consists of the core parsing engine (written by Zend), a set of core code modules and then a set of code extensions. This allows programmers two ways of extending PHP to do some special processing, either by writing an extension module and compiling it into the executable, or by creating an executable that can be loaded using PHP's dynamic loading mechanism. Lots of HTTP server interfaces. PHP currently will load into Apache, IIS, AOLServer, Roxen and THTTPD. Alternatively, it can be run as a CGI module. Lots of database interfaces. PHP currently will work with MySQL, MS SQL, Oracle, Informix, PostgreSQL and many others. These are binary level interfaces, and ODBC is also provided for those situations where the database is not supported. And lots of other modules... when a PHP user wants to interface to particular library, then it is easy to write an interface for it, and many have done so,

and contributed to the main PHP source repository. So you can find modules for graphics routines, PDF files, Flash movies, Cybercash, calendars, XML, IMAP, POP and a host of others. If the library you need is not supported, you can either write one yourself, or employ your favourite programmer to do it. PEAR. The PHP Extension and Add-on Repository. Similar to the CPAN network for Perl, although still in its infancy, the idea of PEAR is to provide a set of PHP scripts that would be installed by default with the PHP installation Fast. PHP is normally used an Apache module and this makes it very fast. It is entirely written in C and is quite small, so loads and executes quickly with small memory footprint. PHP is Open Source. Almost a religious matter to some people! In purely practical terms, it means that you are not dependent on a manufacturer to fix things that don't work, nor are you forced to pay for upgrades every year to get a working version.

Front End of the Project PHP PHP is a general-purpose server-side scripting language originally designed for web development to produce dynamic web pages. For this purpose, PHP code is embedded into the HTML source document and interpreted by a web server with a PHP processor module, which generates the web page document. It also has evolved to include a command-line interface capability and can be used in standalone graphical applications. PHP can be deployed on most web servers and as a standalone interpreter, on almost every operating system and platform free of charge.There is also commercial software such as RadPHP, a rapid application development framework for the PHP language. A competitor to Microsoft's Active Server Pages (ASP) server-side script engine and similar languages, PHP is installed on more than 20 million websites and 1 million web servers. HTML Stands for Hyper Text Markup Language, is predominant markup language, is predominant markup language for web pages. It allows images & objects to be embedded and canbe used to create interactive forms. It provides a mean to create structured documents by denoting structural semantics for text such as heading, paragraphs, links, lists, quotes and other items. It can be embed scripts in languages such as Java script which affects behaviour of HTML web pages. Back End of the Project MYSQL

is a relational database management system (RDBMS)[2] that runs as a server providing multi-user access to a number of databases. It is named after developer Michael Widenius' daughter, My.[3] The SQL phrase stands for Structured Query Language.[4] The MySQL development project has made its source code available under the terms of the GNU General Public License, as well as under a variety of proprietary agreements. MySQL was owned and sponsored by a single forprofit firm, the Swedish company MySQL AB, now owned by Oracle Corporation.[5] Free-software-open source projects that require a full-featured database management system often use MySQL. For commercial use, several paid editions are available, and offer additional functionality. Applications which use MySQL databases include: TYPO3, Joomla, WordPress, phpBB, Drupal and other software built on the LAMP software stack. MySQL is also used in many high-profile, large-scale World Wide Web products, including Wikipedia, Google (though not for searches), Facebook,and Twitter. OPERATING SYSTEM USED The Operating System used in our Project is Windows (vista/xp/7). We are using this Operating System as: It has majority of users. Its user-friendly. It supports the hardware.

You might also like