AMBEDKAR INSTITUTE OF TECHNOLOGY DELHI ---------------------------------------------------------------------------- ------------------------------------------------------------------------- PROJECT REPORT ---------------------------------------------------------------------------- ------------------------------------------------------------------------- MINOR PROJECT: WEBLOGGER Team members: Mayank tanwar Gurudev jayant Ravi raj
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
The satisfaction that accompanies that the successful completion ofany task would be incomplete without the mention of people whoseceaseless cooperation made it possible, whose constant guidanceand encouragement crown all efforts with success. We are grateful to our project guide Mr. Prakash sir for the guidance, inspiration and constructive suggestions that helpful us in the preparationof this project.We also thank our colleagues who have helped in successfulcompletion of the project.
Mayank tanwar
Gurudev jayant
Ravi raj
Content:
1. Objective
2. Architecture
3. Feasibility Study
4. Machine specification
5. Working of Present System
6. Screen shots
7. Diagrams
a) Data Flow Diagram
b) E-R Diagram
c) Sequence Diagram
8. Conclusion
9. Bibliography
Want to know who's been accessing your website? Want to track them by IP address, browser type, even username? Web Logger lets you log information about the people who come to a website, without their knowledge. Unless you tell them, they have no way of knowing that they've been tracked as you log their time of access, where on your site they went, what their username is (if they logged in to your website, as you're going to see how to do), what their IP address is (and if they have cable access, they have a fixed IP address), how long they worked with the web page they accessed, and what type of browser they have.
Want to get a handle on who comes to your site and how long they stay? Then Web Logger’s for you.
Using Web Logger, you can track users as they move around your site. In fact, you can even block access if you want. What does the user see? Where the user is accessing a page called target.jspexcept for the text Web Logger has added to the bottom of the page. Unless that added text informed the user that he was being tracked (and, of course, you can remove that text from Web Logger), he would have no way of knowing it.
OBJECTIVES:
ARCHITECTURE
DIAGRAM: WEBLOGGER
EXPLAINATION:
Here's the information that's logged for each user:
Access time Authentication type
Username
User IP address
URL accessed
Browser
Milliseconds used
Here's what the report will look like. You can have this logged in the web server's logs or in a separate log file of your own creationWebLogger lets you do either:
User access at Mon Mar 07 15:47:53 EST 2006Authentication type: BASICUser name: SteveUser IP: 127.0.0.1Accessing: /logger/target’sHost: 127.0.0.1Browser: Internet ExplorerMilliseconds used: 109
To make what it does possible, Web Logger uses a filter. You can get your hands on the data sent to JSPs and servlets, and on the data they return, using filters. All you have to do is to write your filter, compile it, and install it so that the web server only grants access to the web resource you're filtering through that filter. And that gives you complete control.
FEASIBILITY STUDY :
The weblogger module will display the empty boxes for user name and
password. The user will enter the details and press the submit button. In
case there is any change to be made, cancel button can be pressed so
that the details entered already will be cleared.
Technical Feasibility
The technology suggested for implementing the project is Login system
with web server (Internet Authentication Server) and SMS server.
The data will be collected in XML format through web using java
technology.
The system will be hosted through a Web Server. The hardware requirements
are a robust server and leased line connectivity.
The project proposed will involve procurement of one robust webserver.
The database also can be stored in the same server. Other requirements
are Leased line connectivity for internet, development of Webpage with
java technology for checking and uploading data to database and a
SMS server to receive and reply SMS queries.
Operational Feasibility
Initial development of application needs to be done through external
agency with annual maintenance contract. Further improvements to the
system and maintenance could be done internally.
A few days’ orientation training on the new system will be sufficient to
enhance the operating skills of the users
TOOLS, PLATFORM & LANGUAGE TO BE USED
TOOLS:
FRONT-END : JAVA NET BEANS 7
PLATFORM:
WINDOW NT 4.0 /XP
HARDWARE AND SOFTWARE ENVIRONMENT
MINIMUM HARDWARE RECOMMENDATION :
PROCESSOR : Pentium iv
RAM : 128 MB
STORAGE CAPACITY : 10 GB
CONNECTIVITY : LAN or Internet (minimum speed : 512Kbps)
MACHINE SPECIFICATION:
SOFTWARE RECOMMENDATION :
OPERATING SYSTEM : WINDOW NT 4.0 /9X/ XP/VISTA/7.
Working of present system :
Simple Filter
A lot of filter technology is needed to build Web logger. WebLogger works with both the request object holding the data sent from the browser and the response object sending data back to the browser. So how do you work with, for example, the response object to send data back to the browser? Say that you want to filter access to a JSP page named simple.jsp and that you want a filter to add some text to the output of this JSP sent back to the browser. Here's what that JSP page looks likeas it stands, all this page does is to display the text "Using a filter" in an <H1> HTML header.
Because you have access to the data sent to and from this JSP page in a filter, you can display your own text in the web page . In this figure, a filter attached to simple.jsp wrote the text "The filter wrote this," just as WebLogger added the warning about logging user access . Note that the URL still points to simple.jsp; there's nothing to indicate that the page is being filtered.
Significant Methods of the javax.servlet.http.ServletRequest Class
java.lang.Object getAttribute(java.lang.String name) Returns the value of the named attribute
java.util.Enumeration getAttributeNames() Returns a Java Enumeration holding the names of the attributes in the request
java.lang.String getCharacterEncoding() Returns the character encoding used in the request's body
int getContentLength() Returns the length of the request
body. Returns -1 if the length is not known
java.lang.String getContentType() Returns the MIME type of the body of the request
java.util.Locale getLocale() Returns the locale of the client browser
java.util.Enumeration getLocales() Returns a Java Enumeration of Locale objects giving the preferred locales of the client
int getLocalPort() Returns the IP port number where the request was received
java.lang.String getParameter(java.lang.String name) Returns the value of a request parameter, such as the contents of an HTML control
java.util.Enumeration getParameterNames() Returns a Java Enumeration holding the names of the parameters contained in this request.
Sets the character encoding of the response, such as UTF-8
void setContentLength(int len) Sets the length of the content in the response
void setContentType(java.lang.String type) Sets the content type
void setLocale(java.util.Locale loc) Sets the locale of the response
Restricting Access Based on Time of Day
The list of things you can do with filters is endless. You can convert, for example, the data sent to a servlet from XML to HTML, or even from French to English. You can add a common header or footer to all web pages in your site. You can use a single filter as a gateway to your entire site. You can restrict access to a JSP or servlet in case multithreading issues become a problem (on most web servers, multiple threads from multiple users can execute the same servlet or JSP code at the same time).
You can even restrict access to a resource based on the time of day. Say you have a company full of employees and don't want them to access a game on your site during the day. Here's what the restricted starting page of the game, game.jsp, might look like:
Restricting Access Based on Password
At this point, you've made use of the response object in filters, but filters can also work with the request object, as WebLogger does. Using the request object lets you handle data on its way to the filtered web resource. For instance, one of the most popular uses of filters is to restrict access to web resources based on password .
If the user enters the correct password, he's OK'd by the filter, which passes control on to a JSP named loggedin.jsp.
On the other hand, if the user enters the wrong password, the filter denies access and displays the error page.
interesting thing here is that you're reading data from HTML controlsa password control in this casein the filter. The data in the password control isn't even used in the target JSP. In the first HTML page the user sees, login.html, the password control is simply named password.
Screen shots:
WebLogger at work
Reading a password .
Restricting access based on time of day with a filter
Slapping a filter on game.jsp will make it inaccessible during working hours
Restricting access-based passwords with a filter
If the user enters the correct password, he's OK'd by the filter, which passes control on to a JSP named loggedin.jsp
Denying access for an incorrect password.
If the user enters the wrong password, the filter denies access and displays the error page
Diagrams:
Data Flow Diagram
Sequence Diagram
conclusions:
To log accesses to a web resource, you don't have to change that web resource; you can use a filter in Java-enabled web servers. To create a filter, you have to create a Java class that implements the Filter interface, which includes the init, doFilter, and destroy methods. When the user accesses the resource you're filtering, the doFilter method gets control, gaining access to the request object sent to the resource and the response object the resource sends back to the browser.
WebLogger uses the request object to get its information about the user, reading the URL the user is accessing, the user's IP address, hostname, and browser type. If the user is logged in using HTTP authentication, WebLogger records the type of authentication used and records the username. It also logs the time of the user's access, as well as the time he spent accessing the web resource you're filtering.
You've got options when it comes to where you want the log text sent with WebLogger. If you use Tomcat, that text is stored in stdout.log by default. But as discussed in this chapter, you can specify the log file you want to use. As also covered, you can create your own files, writing to them as you please.
WebLogger is a powerful project that lets you keep track of who's been visiting your site and log that information. Not bad.
bibliography:
1. Java Server programming Ivan Bayross2. The complete reference java
Future ScopeScope of this project is very broad in terms of other manually taking exams.Few of them are:-
1. This can be used for Security in defferent systems as well as in corporate
world.
2. Can be used at servers of a organisations as it is a web based application.