USB KEY PROFILE MANAGER FOR MOZILLA

USB KEY PROFILE MANAGER FOR MOZILLA

A Project Report Presented to

The Faculty of the Department of Computer Science San Jose State University In Partial Fulfillment

of the Requirements for the Degree Master of Science

by Yun Zhou December 2004

1

? 2004 Yun Zhou ALL RIGHTS RESERVED

2

APPROVED FOR THE DEPARTMENT OF COMPUTER SCIENCE ______________________________________________________

Dr. Chris Pollett ______________________________________________________

Dr. Melody Moh ______________________________________________________

Dr. Mark Stamp APPROVED FOR THE UNIVERSITY _____________________________________________________

3

ABSTRACT

USB KEY PROFILE MANAGER FOR MOZILLA By Yun Zhou

Mozilla's profile manager allows users to save their private information such as bookmarks, cache and email drafts and customize their preferences settings. In this project, we build an XPCOM (Cross Platform Component Object Model) component called the USB (Universal Serial Bus) Key Profile Manager as an extension to the existing profile manager so that users can carry their profiles around via removable USB keys and use those profiles on different computers. To achieve this, three major functions were implemented: USB profile loader, user authentication and profile encryption. In this report, we will start with some background information and related work followed by a detailed description of the project design and an encryption performance test. We will summarize the report with a conclusion and a brief discussion of future work.

4

TABLE OF CONTENTS

I. INTRODUCTION............................................................................................................ 1 II. BACKGROUND AND RELATED WORK................................................................... 3

2.1 Mozilla's Profile Manager......................................................................................... 3 2.1.1 Strengths and Weaknesses ................................................................................3 2.1.2 nsProfile.............................................................................................................5 2.1.3 nsProfileAccess................................................................................................. 5

2.2 XPCOM - Cross Platform Component Object Model.............................................. 6 2.2.1 Modularity......................................................................................................... 6 2.2.2 Interface............................................................................................................. 6 2.2.3 XPCOM Glue.................................................................................................... 8 2.2.4 Component Management ...............................................................................9

2.3 Mozilla's Personal Security Manager (PSM) and Network Security Services (NSS) ......................................................................................................................................... 9

2.3.1 Overview........................................................................................................... 9 2.3.2 The Structure of PSM...................................................................................... 10 2.3.3 NSS API.......................................................................................................... 11 2.4 Advanced Encryption Standard (AES)....................................................................11 2.4.1 The Algorithm................................................................................................. 11 2.4.2 Operation Modes............................................................................................. 12 2.5 Hash Algorithms..................................................................................................... 14 2.5.1 MD5 and SHA-1..............................................................................................14 2.5.2 Dictionary Attack and Salted Hash..................................................................15 2.7 Performance Test of a USB Drive...........................................................................16 2.7.1 Advantages and Disadvantages of USB Drives ..............................................16 2.7.2 Several USB Drives, Their Storage Space and Transfer Rates....................... 16 2.7.3 Read and Write Performance Test .................................................................17 III. DESIGN AND IMPLEMENTATION......................................................................... 18 3.1. Event-Driven Design..............................................................................................18 3.2 USB Profile Loader................................................................................................. 22 3.2.1 Detect Mounted USB Drives...........................................................................22 3.2.2 Search for Profiles on Mounted USB drives................................................... 23 3.2.3 Load Profiles to the Registry........................................................................... 24 3.2.4 Cleanup at Shutdown.......................................................................................26 3.3 User Authentication.................................................................................................28 3.3.1 Password Prompt............................................................................................. 29 3.3.2 How the Project Uses nsIWindowWatcher and nsIPromptService ................ 33 3.3.2 Salted Password Digest................................................................................... 35 3.4 AES Encryption and Decryption............................................................................. 38

v

5

................
................

In order to avoid copyright disputes, this page is only a partial summary.

Google Online Preview   Download