CSC/ECE 517 Spring 2016/Implement private browsing: Difference between revisions
No edit summary |
|||
(5 intermediate revisions by one other user not shown) | |||
Line 49: | Line 49: | ||
We have implemented the function to set this member based on the mozprivatebrowsing attribute. | We have implemented the function to set this member based on the mozprivatebrowsing attribute. | ||
[[File: | [[File: MozprivateBrowsing.png]] | ||
===Step 2=== | ===Step 2=== | ||
Line 55: | Line 55: | ||
We have created an enum 'ConstellationMsg' that holds an isPrivate message containing pipelineId and sender as attributes. | We have created an enum 'ConstellationMsg' that holds an isPrivate message containing pipelineId and sender as attributes. | ||
[[File: | [[File: Enum_Struct.png]] | ||
The below member has been added to the pipeline struct to check if it's private | The below member has been added to the pipeline struct to check if it's private | ||
Line 61: | Line 61: | ||
[[File: Selection_004.png ]] | [[File: Selection_004.png ]] | ||
===Step | ===Step 3=== | ||
The below function | The below function has been implemented to check whether the pipeline is private or not. | ||
[[File: | [[File:Pipeline_Function.png]] | ||
===Design Pattern=== | ===Design Pattern=== | ||
As per the design document, we have added few fields/members, defined an enum and added a method. The requirements did not require any design pattern to be implemented as such and thus, we have not used any design pattern | As per the design document, we have added few fields/members, defined an enum and added a method. The requirements did not require any design pattern to be implemented as such and thus, we have not used any other design pattern apart from the existing servo design strategy. Details about the servo design can be found [https://github.com/servo/servo/wiki/Design here]. | ||
===Testing=== | ===Testing=== |
Latest revision as of 23:03, 3 April 2016
Implement Private Browsing
Servo<ref>https://github.com/servo/servo</ref> is a prototype web browser engine written in the RUST language. Servo currently does not support the mode where the cookies, login, history and downloads are forgotten after the session ends. The goal of this project is to implement incognito/private browsing feature in Servo.
Introduction
Servo is an experimental web browser layout engine being developed by Mozilla Research. Servo is written in the Rust<ref> https://doc.rust-lang.org/ </ref> language, which is also being developed by Mozilla Research. The language is being refined through feedback from Servo development, and writing the Rust compiler itself. Rust is a systems programming language similar to C and C++ in syntax (but semantically very different). The emphasis is on speed, safety, concurrency and control of memory layout.
Motivation
When a user browses the web, Firefox remembers lots of information for the user - like the sites visited. There may be times, however, when the users don't want people with access to their computer to see this information, such as when shopping for a present. Private Browsing allows the users to browse the Internet without saving any information about which sites and pages they have visited. Private Browsing also includes Tracking Protection in Private Browsing, which prevents companies from tracking the browsing history across multiple sites.[1]
Installing Servo
Prerequisites on Debian based linuxes
sudo apt-get install curl freeglut3-dev autoconf \ libfreetype6-dev libgl1-mesa-dri libglib2.0-dev xorg-dev \ gperf g++ build-essential cmake virtualenv python-pip \ libssl-dev libbz2-dev libosmesa6-dev libxmu6 libxmu-dev \ libglu1-mesa-dev libgles2-mesa-dev libegl1-mesa-dev
Building Servo
git clone https://github.com/servo/servo cd servo ./mach build --dev
Running Servo
./mach run [url] --devtools <port number>
Implementation
The below mentioned steps were followed to implement private browsing. The detailed requirements are described in the document available here:[2].
Step 1
As per the requirement, we have added the is_private member to the struct IFrameLoadInfo to check if it's a private iframe or not
We have implemented the function to set this member based on the mozprivatebrowsing attribute.
Step 2
We have created an enum 'ConstellationMsg' that holds an isPrivate message containing pipelineId and sender as attributes.
The below member has been added to the pipeline struct to check if it's private
Step 3
The below function has been implemented to check whether the pipeline is private or not.
Design Pattern
As per the design document, we have added few fields/members, defined an enum and added a method. The requirements did not require any design pattern to be implemented as such and thus, we have not used any other design pattern apart from the existing servo design strategy. Details about the servo design can be found here.
Testing
For this particular project, an automated test is to be created to test the functionality which is part of the subsequent steps and is not included in the initial steps, and hence at this point of time the users/reviewers are not supposed perform any manual testing or testing from GUI. More details about writing the automated test for this project can be found here.
References
<references/>