You are on page 1of 9

INTERNATIONAL JOURNAL OF COMPUTER ENGINEERING International Journal of Computer Engineering and Technology (IJCET), ISSN 0976 6367(Print), ISSN

N 0976 6375(Online) Volume 3, Issue 3, (IJCET) & TECHNOLOGY October-December (2012), IAEME
ISSN 0976 6367(Print) ISSN 0976 6375(Online) Volume 3, Issue 3, October - December (2012), pp. 291-299 IAEME: www.iaeme.com/ijcet.asp Journal Impact Factor (2012): 3.9580 (Calculated by GISI) www.jifactor.com

IJCET
IAEME

WRAPPED RSA CRYPTOGRAPHY CHECK ON WINDOW EXECUTABLE USING RECONFIGURABLE HARDWARE


Rahul Jassal1 1 (Department of Computer Science & Applications, P.U.S.S.G.R.C/ Panjab University, Hoshiarpur, India, rahulatssgpurchsp@gmail.com) ABSTRACT The paper presents secure system RSA cryptography model using FPGA based hardware dongle to prevent from extracting secret information about the software. Half side of the simulation is executing on hardware side and a further result is decrypted software side. RSA calculation architecture is proposed for FPGA that addresses the issues of scalability, flexible performance of public key crypto systems. Keywords: - Finite field architecture, Moxa_usbcable, RSA algorithm, Virtex FPGA, Encryption Simulation I. INTRODUCTION Data transmit over wireless network is in the air and not curbed to any wire. Due to this it is effortless for a hacker to nose around into the information that is being transferred over the wireless network. To prevent this there is a necessitate to encrypt the data in a way that it can only be deciphered by someone who has the decryption key. While most of this so called. Malicious code exploits holes in the operating system, we as humans are party to blame. All antivirus and security suites do is offer that additional layer of prevention. If we were clever enough to avoid all the evident threats by not clicking on that very oddly named.exe file or executing that mail attachment, we wouldnt need a security suite, would we? It is widely known that security issues play a crucial role in the majority of computer and communication systems [1]. An innermost tool for achieving software protection is Cryptography. Cryptography algorithms are most proficiently implemented in routine hardware than in software running on general purpose processors. Hardware implementations are of tremendous value in case of high performance, security and active systems. Traditional ASIC solutions have the well known drawback of reduced flexibility compared to software solutions. 1.1 LEGITIMATE VS. PIRATED MARKET Globally, businesses and consumers will spend more than $300 billion on PC software over the next four years, according to IDC estimates
291

International Journal of Computer Engineering and Technology (IJCET), ISSN 0976 6367(Print), ISSN 0976 6375(Online) Volume 3, Issue 3, October-December (2012), IAEME October December

1. Given the current piracy rates, IDC predicts that, during the same four-year period, the four almost $200 billion worth of software will be pirated.

Since up-to-the-minute security protocols are ever more becoming algorithm autonomous, a minute high degree of elasticity with respect to the cryptography algorithms is desirable. The cryptography protection degrees of all the techniques are based on hardness of arithmetic problems. A capable solution which combines high flexibility with the speed and physical security of traditional hardware is the implementation of cryptographic algorithms on reconfigurable devices such as FPGAs [2]. FPGAs are hardware devices whose purpose is not fixed and which can be programmed in-system. An FPGA accomplishment can be merely upgraded to system. add in any set of rules changes without the need for pricey and time consuming physical design, fabrication and testing required in case of ASICs 2.0 FPGA PROGRAMMING Both the layers for hardware and software is not compromised to make the system rigid from extracting secret information, more ever for ideal software it is extremely hard to detect that an attack is underway. Here in the diagram the flowchart is shown for hardware side FPGA accepts input message with encrypt keys which is synchronized with clock and further handover to module for speed up execution and this in continuation is repeated for getting d equivalent cipher text and the closing figure depicts pin used for this dongle. The Figure 3 shown here is a Xilinx operated Spartan3 kit where the bit file is tuned [6].

292

International Journal of Computer Engineering and Technology (IJCET), ISSN 0976 6367(Print), ISSN 0976 6375(Online) Volume 3, Issue 3, October-December (2012), IAEME October December

The 8 bit on display is tuned for cipher text. The following properties for this FPGA is as isplay follows Product Category: - ALL, Family: - Spartan3, Device: - XC3S200, Package: - FT256 Speed: - 4, Top level Source Type: - HDL, Synthesis Tool: - XST (VHDL/Verilog) Whenever there is question of securing or authenticating secret data on a public here communication network this public key cryptography is extensively used. When deployed with sufficiently long keys, these algorithms are believed to be unbreakable. For secure communications among high performance computers that required elevated confidentiality ions guarantees the strong cryptographic algorithms were first introduced. Now, advances in semiconductor technology and hardware design have made it promising to execute these algorithms in sound time even on user systems, thus enabling the mass market use of wellhms mass-market well built encryption to ensure privacy and authenticity of individuals personal communications. Consequently, this transition has enabled the proliferation of a variety of secure services, secur such as online banking and shopping. Examples of consumer electronics devices that routinely rely on high-performance public key cryptography are Blu-ray players, smart performance Blu ray phones, and ultra-portable devices. portable

293

International Journal of Computer Engineering and Technology (IJCET), ISSN 0976 6367(Print), ISSN 0976 6375(Online) Volume 3, Issue 3, October-December (2012), IAEME

In addition, low cost cryptographic engines are mainstream components in laptops, servers and personal computers. A key requirement for all these hardware devices is that they must be affordable. As a result, they commonly implement a straightforward design architecture that entails a small silicon footprint and low-power profile. 3.0 METHODS OF PROTECTING SOFTWARE Usage of specially coated key diskettes and CDs, passwords and registration numbers Dependence on the Unique Computer Features Software-and-Hardware Protection Based on Dongles Cryptography with dongle protection 3.1 DONGLE/HARDWARE KEY Modern dongles include built-in strong encryption and use fabrication techniques designed to thwart reverse engineering Typical dongles also now contain non volatile memory key parts of the software may actually be stored on the dongle However, security researchers warn that dongles still do not solve the trusted client problem 3.2 Design Methodology The general design cycle for this work consisted of the following steps: Implementation of RSA encryption algorithm on Java and VB.NET. Implementation of AES encryption algorithm on Java platform. Implementation of RSA Decryption algorithm in VHDL for FPGA (dongle) programming. Implementation of AES Decryption algorithm in VHDL for FPGA (dongle) programming. Serial and USB interface between computer and FPGA (dongle) using UART and USB Protocol in VHDL, VB.NET and Java. Software testing using GUI interface in Java and VB.NET. On line (WEB based) software testing in VB.NET. 3.2.1 Hardware and Software Tools used Software Tools: Xilinx ISE and MODELSIM software for FPGA Programming JCreator and jdk1.6 for java platform VB.NET and SQL server MOXA USB cable drivers Hardware Tools: VIRTEX 4 (XC4VFX12) FPGA kit SPARTAN 3 (XC3S200) FPGA kit MOXA USB cable for USB interface RS232 serial cable for serial interface JTAG downloading cable 3.2.2 Serial and USB interface between PC and FPGA (dongle): UART Protocol: Universal Asynchronous Receiver Transmitter RS 232 connector : For Serial interfacing MOXA USB 2.0 cable : for USB interfacing Rivest, Shamir and Adleman (1977): use modular arithmetic Setting up by user A[5]: Find two large primes, pA and qA
294

International Journal of Computer Engineering and Technology (IJCET), ISSN 0976 6367(Print), ISSN 0976 6375(Online) Volume 3, Issue 3, October-December (2012), IAEME October December

Compute nA = pAqA pA Compute (nA)= (p (nA)= (p-1)A x (q-1)A Find an exponent eA such that (eA, (nA)) = 1 Find dA such that dA dAeA 1 (mod (nA)) Publish nA and eA Encryption: EA(M) = MeA C (mod nA) Decryption: DA(C) = CdA M (mod nA) 4.0 DESIGN INTERFACE

This is the very first screen designed for testing the interface the interfacing port might be any unused port or user can go for new port for the communication, the initiate hardware button uploads the bit file into the spartan3 kit with the specified parameters required for communication. For testing purpose user declared a Random number class in .NET for any value between a certain limit and first and second value reserved for any 2 keys values for this RSA implementation, As soon as focus changes to encrypted text box the encrypt and decrypted data is shown in respective boxes. The small three text boxes is of three different three colors each time the user switches to next level the color of the boxes changes to red green yellow. So for public key authentication the module sends a unique message m to a server that is this time our machine which signs it with some private key say k and upon receiving signs the digital signatures s, the user can authenticate the identity of server using (n, e) for verification that s will produce the original message. 4.1 RSA Introduced Since RSA, was introduced in 1977, and has been widely used for establishing safe and and sound communication channels and for authenticating the identity of service providers over insecure communication mediums. In the authentication scheme, the server implements public key authentication with clients by signing a unique message from the client with its clients private key, thus creating what is called a digital signature [4]. The signature is then returned . to the client, which verifies it using the servers known public key The procedure for implementing public key authentication requires the construction of a suitable pair of public g key (n, e) and private key (n, d). Here n is the product of two distinct big prime numbers, and e and d are computed such that, for any given message m, the following identity holds true: m identity _ (md)e mod n _(me)d mod n. To authenticate a message m, the server attaches a signature s
295

International Journal of Computer Engineering and Technology (IJCET), ISSN 0976 6367(Print), ISSN 0976 6375(Online) Volume 3, Issue 3, October-December (2012), IAEME October December

to the original message and transmits the pair. The server generates s from m using its private key with the following computation: s _ md mod n. Anyone who knows the public key Anyone associated with the server can then verify that the message m and its signature s were authentic by checking that: m _ se mod n.

4.2 Flowchart

4.3 Working and Architecture The RSA class inside .NET module is wrapped with FPGA programming. Spartan3 kit get FPGA initialized with the required parameters as specified in bit file and data get uploaded, next is to maintain a dongle check if dongle is already connected then user checks for any process is running on the shell side and if some process is running we kill the process and this all done under the umbrella of XML. And, suppose that if dongle is not connected again it goes for RSA layer and through classes of Serial Port, a check is maintained through RTS and CTS for presence of the dongle, next while the process status in Task Manager is checked if any of the process that user wants to shoot is there or its entry is already there in database the .NET module kill the process otherwise the entry with new name is saved into the database. User data can make a list of some processes that he/she want to kept into the database and make them restrict on dongle bases 4.4 RSA BASED THRESHOLD CRYPTOGRAPHY (RSA (RSA-TC) RSA is a highly secure, public key encryption algorithm which uses a public key and private key to encrypt and decrypt a message. In public crypto systems there are two different keys: a public key that is released publicly so anyone can find it, and a private key is the one that is kept secret. The public key is used to encrypt the message, and private key is used to decrypt message, it. It is very difficult to find out what private key is used for a public key.

296

International Journal of Computer Engineering and Technology (IJCET), ISSN 0976 6367(Print), ISSN 0976 6375(Online) Volume 3, Issue 3, October-December (2012), IAEME

4.5 RSA ENCRYPTION RESULT

In this paper an RSA calculation architecture is proposed for FPGAs that addresses the issues of scalability, flexible performance, and silicon efficiency for the hardware acceleration of Public Key crypto systems. Using techniques based around Montgomery math for exponentiation, the proposed RSA calculation architecture is compared to existing FPGAbased solutions for speed, FPGA utilisation, and scalability[3]. 4.6 PARITY AND IMPLEMENTATION CHECK SerialPort1.PortName = "COM3" SerialPort1.BaudRate = 9600 SerialPort1.Parity = Ports.Parity.None SerialPort1.DataBits = 8 Dim Flag As Boolean Dim Reg As Integer = 1 SerialPort1.RtsEnable = True Try SerialPort1.Open() Flag = SerialPort1.CtsHolding If Flag = False Then SerialPort1.Close() Response.Redirect("Default.aspx") End If Catch ex As Exception SerialPort1.Close()
297

International Journal of Computer Engineering and Technology (IJCET), ISSN 0976 6367(Print), ISSN 0976 6375(Online) Volume 3, Issue 3, October-December (2012), IAEME

End Try If (phi Mod cnt <> 0) Then flag = 0 carry = lcm(cnt, phi) gcd1 = cnt * phi / carry d = Dcomponent(cnt, phi) encript = System.Math.Pow(Double.Parse(carry1), 7) Mod n Dim signfEncpt = encript Dim dcompnt As Double While ((7 * dcompnt) Mod phi <> 1) dcompnt = dcompnt + 1 End While Txt_FChk2 = dcompnt Dim arr(1) As Byte arr(0) = Byte.Parse(encript) SerialPort1.Write(arr, 0, arr.Length) Dim decript_byte As Byte decript_byte = SerialPort1.ReadByte 'SerialPort1.Close() Dim rand_no As Double = Double.Parse(carry1) Txt_FChk2 = decript_byte Dim signop As Integer = Double.Parse(carry1) signum = parity_chk(decript_byte, signop) parity = shared_chk(decript_byte, signum) 'SerialPort1.Close() Return parity Boredum(parity) 5.0 CONCLUSION This is one way out for wrapping RSA layer using .NET using hardware Spartan3 kit on a window based application. One can make restrict some applications with their Process Ids entry into the database with the help of dongle. One can embed such initiators with any web based applications or games for let them stop for execution until and unless user withdraws dongle check. REFERENCES [1] William Stallings ,Cryptography and Network Security, Principles and practices Edition 3d, Pearson Education [2] M.K. Hani, H.Y.Wen, A.Paniandi, Design and implementation of Private and Public key Crypto processor for next generation IT Security applications, Malaysian journal of computer Science, vol.19 (1), 2006 [3] P. Montgomery, Modular multiplication without trial division, Mathematics of Computation, No.44, pp.519-521,1985.

298

International Journal of Computer Engineering and Technology (IJCET), ISSN 0976 6367(Print), ISSN 0976 6375(Online) Volume 3, Issue 3, October-December (2012), IAEME

[4]A. Menezes, P.Van Oorschot, and S.Vanstone, Handbook of applied Cryptography, CRC Press, 1996 [5] R. J. Hwang, F.F.Su, Y.S.Yeh, C.Y. Chen, An Efficient Decryption Method for RSA Cryptosystem, Proceedings of 19th international conference on Advanced Information networking and Applications, 2005 [6] M. McLoone and J. V. McCanny, Rijndael FPGA implementation utilizing look-up tables, in IEEEWorkshop on Signal Processing Systems, Sept. 2001, pp. 349360. [7] Daniel Cazzulino, Web Programming using VB.NET [8] Ganelon, Visual Basic . Net Black Book [9] www.codeworks.it/net/VBNetRs232.htm [10] msdn2.microsoft.com/en-us/library/a9910312.aspx [11] www.learnasp.com/freebook/learn/cs_dbtable.aspx [12] AES page available via http://www.nist.gov/CryptoToolkit. [13] Computer Security Objects Register (CSOR): http://csrc.nist.gov/csor/.[19] For javax.comm package: http://www.stanford.edu/~bsuter/javax.comm-v2 win32.zip[20] R. Rivest, A. Shamir, L. Adleman. A Method for Obtaining Digital Signatures andPublic-Key Cryptosystems. Communications of the ACM, Vol. 21 (2), pp.120126.1978. Previously released as an MIT "Technical Memo" in April 1977. Initial Publication of the RSA scheme AUTHORS PROFILE Rahul Jassal is working as Assistant Professor in Department of Computer Science & Application, Panjab University Regional Centre, Hoshiarpur, India. He received Master of Computer Application in year 2007 and clear the UGC-NET examination for subject Computer Science & Application in the same year. He is with the post from last 5 years.

299

You might also like