Matrix Encryption Algorithm By

Matrix Encryption Algorithm
by

Sandeep M Chandrashekaregowda

Bachelor of Engineering VTU, India
2011

A Project

In Partial Fulfillment of the Requirements

For the Degree of Master of Science

Department of Computer Science

Spring 2014

This project for the Master of Science degree by

Sandeep M Chandrashekaregowda

Has been approved for the
Department of Computer Science
By

______

______

Dr. Rory Lewis

______

Dr. Jia Rao

Contents

1. INTRODUCTION

1.1 Aim and Objective of the project:

1.2 Need of Secure communication

1.3 Introduction to Multimedia

Multimedia Building Blocks

1.3.1 Audio:

1.3.2 Video

1.3.3 Images

1.4. Introduction to Secure Communication

1.4.1 Need of secure communication

1.4.2 Secure communication

1.4.3. How security is provided?

1.5. Structure of MP4

1.5 .1 Terms and definitions [17]

1.5.2Object-structured File Organization

1.6 Introduction to Multimedia

1.6.1 Audio:

1.6.2 Video

1.6.3 Images

1.7. Introduction to Secure Communication

1.7.1 Need of secure communication

1.7.2 Secure communication

1.7.3. How security is provided?

1.7.4. Structure of MP4

1 .8 Terms and definitions [17]

1.8.2Object-structured File Organization

2. Background and Prior Work

2.1. SECMPEG by Meyer and Gadegast, 1995

2.2 Video Encryption Algorithm by Qiao and Nahrstedt, 1997

2.3. Video Encryption Methods by Alattar, Al-Regib and Al-Semari, 1999

2.4 Partial Encryption Algorithms for Videos by Cheng and Li, 2000

3. Matrix Encryption Algorithm

3.1 Matrix Encryption Algorithm

32 Schema:

3.3 Encryption:

6.4 Decryption

4. Security Analysis

The above are generic or the repeat of the analysis of other algorithms, not the security analysis of your specific matrix encryption algorithm. One way to present the security analysis is to explore the complexity of brute force attacks of your algorithm. You can then discuss the potential intelligent way to decrypt if any.

5. Implementation

6. Challenges Encountered

7. Testing and performance

8. Conclusion

9. Future work

10. References

1. INTRODUCTION

With the advancement of the ages, man has greatly found the need to communicate through distances. Initially this being accomplished through snail-mail was not real enough. He wanted to communicate vital moments of his file, his thoughts through the usage of more realistic means by the usage of multimedia, which is nothing but audio and video, which helped to share interesting thoughts, interesting audio/video files among people. Sharing of such files often requires communicating through networks of computers, which is not always secure enough. It is often a requirement that the file being shared is only visible or usable by the intended recipient, sometimes it is also may be essential to disguise the intruder of the file being different than what it really is. And in some commercial purposes it also may be required that only parts of the communicated audio/video files are playable. This arouses the need to device a methodology to securely communicate these multimedia files and hence protect the intellectual property of multimedia from attacks arising out of a hostile network environment.

1.1 Aim and Objective of the project:

Aim:
To develop a methodology by which the video and audio files are secured in time and space efficient manner.
Objective:

To develop an encryption methodology that utilizes various available encryption techniques and helps secure multimedia data files in such a manner that securing only information in the frame data provides an effect of securing the file as a whole. This securing process is to be carried out in a manner so as to reduce the amount of time used in securing the file.

1.2 Need of Secure communication

With the advent and consequent vast growth of the technology, intellectual property has become vulnerable to a number of threats that range from information retrieval to destruction of the intellectual property. Hence one has found the extensive need to secure such intellectual property. Intellectual property in the form of multimedia data files has been under constant threat over the years.Given the fact that often files (including multimedia) would need to be communicated through possibly insecure channels where an imposter or an intruder may cause extensive damage to such intellectual property. It has become the need of the hour that methods are developed to ensure secure communication of such file.

1.3Introduction to Multimedia

Multimedia is media and content that uses a combination of different content forms. The term can be used as a noun (a medium with multiple content forms) or as an adjective describing a medium as having multiple content forms. The term is used in contrast to media which only use traditional forms of printed or hand-produced material. Multimedia includes a combination of text, audio, still images, animation, video, and interactivity content forms. Multimedia has become an inevitable part of any presentation. It has found a variety of applications right from entertainment to education. The evolution of internet has also increased the demand for multimedia content. Multimedia is the media that uses multiple forms of information content and information processing (e.g. text, audio, graphics, animation, video, interactivity) to inform or entertain the user. Multimedia also refers to the use of electronic media to store and experience multimedia content. Multimedia is similar to traditional mixed media in fine art, but with a broader scope. The term "rich media" is synonymous for interactive multimedia.

Multimedia may be broadly divided into linear and non-linear categories. Linear active content progresses without any navigation control for the viewer such as a cinema presentation. Non-linear content offers user interactivity to control progress as used with a computer game or used in self-paced computer based training. Non-linear content is also known as hypermedia content. Multimedia presentations may be viewed in person on stage, projected, transmitted, orplayed locally with a media player. A broadcast may be a live or recorded multimedia presentation. Broadcasts and recordings can be either analog or digital electronic media technology. Digital online multimedia may be downloaded or streamed. Streaming multimedia may be live or on-demand. Multimedia games and simulations may be used in a physical environment with special effects, with multiple users in an online network, or locally with an offline computer, game system, or simulator.

Multimedia Building Blocks

Any multimedia application consists any or all of the following components:

1. Text: Text and symbols are very important for communication in any medium. With the recent explosion of the Internet and World Wide Web, text has become more the important than ever. Web is HTML (Hypertext Markup language) originally designed to display simple text documents on computer screens, with occasional graphic images.
2. Audio: Sound is perhaps the most element of multimedia. It can provide the listening pleasure of music, the startling accent of special effects or the ambience of a mood-setting background.
3. Images: Images whether represented analog or digital plays a vital role in a multimedia. It is expressed in the form of still picture, painting or a photograph taken through a digital camera.
4. Video: Digital video has supplanted analog video as the method of choice for making video for multimedia use. Video in multimedia are used to portray real time moving pictures in a multimedia project.

1.3.1 Audio:

Sound is perhaps the most important element of multimedia. It is meaningful "speech" in any language, from a whisper to a scream. It can provide the listening pleasure of music, the startling accent of special effects or the ambience of a mood setting background. Sound is the terminology used in the analog form, and the digitized form of sound is called as audio.

An audio file format is a file format for storing audio data on a computer system. It can be a raw bit stream, but it is usually a container format or an audio data format with defined storage layer. The general approach towards storing digital audio is to sample the audio voltage which, on playback, would correspond to a certain level of signal in an individual channel with a certain resolution—the number of bits per sample—in regular intervals (forming the sample rate). This data can then be stored uncompressed, or compressed to reduce the file size. [15]

It is important to distinguish between a file format and a codec. A codec performs the encoding and decoding of the raw audio data while the data itself is stored in a file with a specific audio file format. Most of the publicly documented audio file formats can be created with one of two or more encoders or codecs. Although most audio file formats support only one type of audio data (created with an audio coder), a multimedia container format (as MKV or AVI) may support multiple types of audio and video data.

1.3.2 Video

Video can be basically understood as a process of displaying still images at a rapid rate giving a notion of a moving image, which is coupled with perfectly synchronized audio stream. Each such still image is referred to as a frame.

Modern video file formats interleave audio and video to allow for playing even partially loaded video stream on the network. And they also employ video compression methodologies to conserve space. This compression is made possible by using relative references that is to say if two consecutive frames have almost the same content except for partial changes, it is preferable to record only the changes and use the reference frame to generate the current frame.

Thus we normally find the frames distinguished as,

I-frame (intra-coded frame) is an infra-coded pictures in effect a fully specified picture, like a conventional static image file. I-frames are pictures coded without reference to any pictures except themselves. They may be generated by an encoder to create a random access point (to allow a decoder to start decoding properly from scratch at that picture location). They may also be generated when differentiating image details prohibit generation of effective P or B frames. I-frames typically require more bits to encode than other picture types. Often, I-frames are used for random access and are used as references for the decoding of other pictures. Intra refresh periods of a half-second are common on such applications as digital television broadcast and DVD storage. Longer refresh periods may be used in some environments. [18]

P-frame (Predicted frames) holds the changes in the image from the previous frame (Ex: Moving a car across a stationary background, only car’s movement needs to be recorded).

P-frames require the prior decoding of some other picture(s) in order to be decoded. They may contain both image data and motion vector displacements and combinations of the two. They can reference previous pictures in decoding order.

In the older standard designs (such as MPEG-2), use only one previously-decoded picture as a reference during decoding, and require that picture to also precede the P picture in display order. In H.264, it can use multiple previously-decoded pictures as references during decoding, and can have any arbitrary display-order relationship relative to the picture(s) used for its prediction. Typically, P-frames require fewer bits for encoding than I-frames do. [17]

B-frame (bi-directional predicted frame) helps specify the content by using differences between the current and both preceding and following frames. [17]

B-frames require the prior decoding of some other picture(s) in order to be decoded. It may contain both image data and motion vector displacements and combinations of the two. They include some prediction modes that form a prediction of a motion region by averaging the predictions obtained using two different previously-decoded reference regions.

In older standard designs (such as MPEG-2), B pictures are never used as references for the prediction of other pictures. As a result, a lower quality encoding (resulting in the use of fewer bits than would otherwise be the case) can be used for such B pictures because the loss of detail will not harm the prediction quality for subsequent pictures. In H.264, they may or may not be used as references for the decoding of other pictures.

In older standard designs (such as MPEG-2), use exactly two previously-decoded ^pictures as references during decoding, and require one of those pictures to precede the B j picture in display order and the other one to follow it. In H.264, can use one, two, or more than two previously-decoded pictures as references during decoding, and can have any arbitrary display-order relationship relative to the picture(s) used for its prediction. Typically, B-frames require fewer bits for encoding than either I or P frames do. The following figure shows the relationship among the various frame types mentioned above. [17]

Fig: 1 Group of frames [17]

1.3.3 Images

An image (from Latin imago) is an artifact, for example a two-dimensional picture that has a similar appearance to some subject, usually a physical object or a person. Image file formats are standardized means of organizing and storing digital images. Image files are composed of either pixel or vector (geometric) data that are rasterized to pixels when displayed (with few exceptions) in a vector graphic display. The pixels that constitute an image are ordered as a grid (columns and rows); each pixel consists of numbers representing magnitudes of brightness and color.

1.4. Introduction to Secure Communication

1.4.1 Need of secure communication

The requirements of information security within an organization have undergone two major changes in the last several decades. Before the wide spread use of data processing equipment, the security of information felt of be valuable to an organization was provided primarily by physical and administrative means.

With the advent of the computer, the need for automated tools for protecting files and other information stored on the computer became evident. This is especially the case for a shared system.

1.4.2 Secure communication

When two entities are communicating with each other, and they do not want a third party to listen to their communication, then they want to pass on their message in such a way that nobody else can understand their message. This is known as communicating in a secure manner or secure communication. Secure communication includes means by which people can share information with varying degrees of certainty that third parties cannot know what was said. Other than communication spoken face to face out of possibility of listening, it is probably safe to say that no communication is guaranteed secure in this sense, although practical limitations such as legislation, resources, technical issues (interception and encryption), and the sheer volume of communication are limiting factors to surveillance.

1.4.3. How security is provided?

There are two major encryption methodologies used to provide secure communication:

Method I: Symmetric Encryption

Encryption methodologies that require the same secret key to encipher and decipher the message are using what is called private key encryption or symmetric key encryption. Symmetric encryption methods use mathematical operations that can be programmed into extremely fast computing algorithms so that the encryption and decryption processes are executed quickly by even small computers. The challenges that this type of encryption methodology faces is that if either copy of the key falls into the wrong hands, massages can be decrypted by others and the sender and intended receiver may not know the message was intercepted. The primary challenge of symmetric key encryption is getting the key to the receiver, a process that must be conducted out of band to avoid interception.

There are number of popular symmetric encryption cryptosystems. One of the most widely known is the Data Encryption Standard (DBS). DBS uses a 64-bit block size and 56-bit key. But over the years DBS has been proven to be easily compromised using a dedicated attack supported by proper hardware. [22]

Method II: Asymmetric Encryption

Another category of encryption technique is asymmetric encryption. Whereas the symmetric encryption system use a single key both encrypted and decrypted a message, asymmetric encryption uses two different but related keys, and either key can be used to encrypt or decrypt the message. If, however, key A is used to encrypt the message, only key B can decrypt it, and if key B is used to encrypt the message, only key A can decrypt it. Asymmetric encryption can be used to provide elegant solution to problem of security and verification. This technique has its highest value when one key used as a private key, which means that it is kept secret (much like the key of the symmetric encryption), known only to the owner of the key pair, and other key serves as a public key, which means that it is stored in a public location where anyone can use it. This is why the more common name for asymmetric encryption is public-key encryption.

One of the most popular asymmetric encryption techniques is the RSA algorithm. There are many such algorithms that are widely in use in the present day. [22]

1.5.Structure of MP4

MP4 follows the ISO base format. The ISO Base Media File Format is designed to contain timed media information for a presentation in a flexible, extensible format that facilitates interchange, management, editing, and presentation of the media. This presentation may be 'local' to the system containing the presentation, or may be via a network or other stream delivery mechanism. The file structure is object-oriented; a file can be decomposed into constituent objects very simply, and the structure of the objects inferred directly from their type. The file format is independent of any particular network protocol while enabling efficient support for them in general. The ISO Base Media File Format is a base format for media file formats. One such being MPEG-4 is technically described by the ISO/IEC 14496-12, in accordance with its compliance to the base format. [6]

The responsibility of maintaining the ISO Base Media File Format rests on WG1 and WG11.

1.5 .1 Terms and definitions [17]

The following terms and definitions are useful in understanding the file format

Box: Object-oriented building block defined by a unique type identifier and length. It is also popularly known as 'atom' in some specifications, including the first definition of MP4.