Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask C/C++ Expert


Home >> C/C++

In 1976 Diffie and Hellman have suggested their famous protocol for key exchange based on number theory. More recently (around 2002) I. Kanter, W. Kinzel and E. Kanter [1] proposed to use neural networks synchronization by mutual learning as the mechanism to achieve secure key exchange. Unlike in Diffie-Hellman protocol the common secret key is generated here by multiple message  exchange rounds at which every participant gets an approximation of the key.

It had turned out, however, that the Kanter-Kinzel-Kanter (KKK) protocol is not secure, and three different attacks on this protocol had been demonstrated in [2]. Later, it has been shown in [3, 4] that resistance of the protocol against different attacks can be improved by tuning the neural networks parameters. The neural cryptography is still very active area [5] further development of which may produce fast cryptographic protocols using simple arithmetic operations, parallelizable and implementable in hardware.

2 The KKK protocol and geometric attack

2.1 KKK protocol

In this section we briefly describe a variant of KKK scheme which uses an anti-Hebbian learning rule and for which a genetic attack has been first considered in [2].

Each of two parties A and B in KKK protocol uses a two layer neural network (parity machine in terms of [1]), see fugure 1.

The first layer consists of K perceptrons and the second layer computes the parity of the hiddent outputs of these K perceptrons. Each pereceptron has n inputs and therefore the whole network accepts N = Kn input values, which are assumed to be either 1 or

-1. The output node of kth perceptron (1 ≤ k ≤ K) has a connection with its ith input with the weight wk,i. All weights are integers from the set {-L, . . . , L} for some L.

When given n inputs xk,1, . . . xk,n the kth perceptron generates at its output the sign (+1 or -1) of the weighted sum of its inputs: ok = Σn i=1wk,ixk,i. The output O of the whole network is then generated as the parity of the outputs of K perceptrons: O = ΠK k=1ok.

In the KKK protocol with the fixed K, N, and L the both parties A and B start with the neural networks of the s ame publicly known structure, but with random uncorrelated weights, which assumed to be secret (i.e known only to A and B, respectively). At each round a new set of N random input values is chosen publicly and each party announces publicly the result of evaluation of its own network on that set of input values. If announced results are different (OA 6= OB) then both parties do not change their networks and proceed to the next round. If the results coincide OA = OB = O then both parties update the weights in those their perceptons which produced the same results (ok = O) at their (hidden) inputs. The anti-Hebbian learning rule is used to update the weights: wk,i := wk,i - okxk,i. If after update the weight gets the value outside of {-L, . . . L} this value is adjusted to the nearest bound (L or -L).

The remarkable property of the described protocol is that starting with random weights both parties eventually (with probability 1) will arrive to the same weights in their neural networks (networks are synchronized), which can be used then as the common secret key.

The detection of synchronization can be implemented by the testing that both networks have produced the same outputs for S consecutive rounds, with S some fixed in advance value.

The secrecy of the key relies on the (assumed) difficulty for an attacker to find out that secret key even assuming that the attacker does know all random inputs and outputs generated by both parties during the execution of the protocol. Notice that attacker is in a different position as compared with parties of the protocol and can not simply follow the protocol mimicking the moves. If the attacker E starts with the network of the same structure as those of A and B and with uncorrelated random weights then there is no problem for E to perfom steps of the protocol when OA = OB = OE. But in all other cases E is forced to deviate from the protocol.

In the paper [2] the authors have shown that the KKK key exchange scheme is unsecure and demonstrated three different types of attacks: genetic, geometric and probabilistic.

2.2 Geometric Attack

Here we describe briefly the geometric attack. The attacker constructs a neural network C with the same structure as these of A and B and randomly initializes its weights. At each step she trains C with the same input as the two parties, and updates its weights with the following rules:

  • If A and B have different outputs OA 6= OB, then the attacker doesn't update C
  • If all A, B and C have the same outputs OA = OB = OC then the attacker update

C by the usual learning rule.

  • If A and B have the same outputs OA = OB and QC 6= QA then the attacker finds

i0 ∈ {1, . . . K} that minimizes | Σ N j=0w C i,j · xi,j |. The attacker negates o C i0 and updates C assuming the new hidden bits and output QA.

3It is reported in [2] that such an attack can be successful for differen variants of the KKK protocol and different parameters.

Furthermore there is an opportunity for parallelization:

different attackers starting from randomly chosing states behave independently and thus multiple attackers have a higher probability to be successful.

How to make attacks less successfull?

In [3] it has been argued that increasing the range of weights in the neural networks, that is a parameter L, would provide a defense against geometric attacks and in [4] the argument has been extended to other types of attacks including genetic one. The efficiency of such a defense is based on the fact that synchronization time grows proportionally to L 2, while success rate of the attacks drops exponentially.

Such a defense may be cosidered theoretically sufficient, however quadratically increasing synchronization time may make the whole protocol not very impractical.

3 Empirical investigation of the geometric attack

This exercise asks you to write a program implementing geometric attack on KKK protocol using MPI and investigate how the success rate of the attack depends on

  • values of N,L,K;
  • execution on single host, or a cluster (with reasonable resources requested);
  • online or offline attack.

You need to write a C program(s) which

  • implements a KKK protocol;
  • implements two variants of parallel geometric attack on the protocol: online, where an attacker executes in parallel with the protocol, and offline when an attacker is given a record of public trace of the protocol.

C/C++, Programming

  • Category:- C/C++
  • Reference No.:- M91609564

Have any Question?


Related Questions in C/C++

Question 1find the minimum and maximum of a list of numbers

Question: 1. Find the Minimum and Maximum of a List of Numbers: 10 points File: find_min_max.cpp Write a program that reads some number of integers from the user and finds the minimum and maximum numbers in this list. Th ...

What are the legal requirements with which websites must

What are the legal requirements with which websites must comply in order to meet the needs of persons with disabilities? Why is maximizing accessibility important to everyone?

1 implement the binary search tree bst in c using the node

1. Implement the Binary Search Tree (BST) in C++, using the Node class template provided below. Please read the provided helper methods in class BST, especially for deleteValue(), make sure you get a fully understanding ...

Software development fundamentals assignment 1 -details amp

Software Development Fundamentals Assignment 1 - Details & Problems - In this assignment, you are required to answer the short questions, identify error in the code, give output of the code and develop three C# Console P ...

Project - space race part a console Project - Space Race Part A: Console Implementation

Project - Space Race Part A: Console Implementation INTRODUCTION This assignment aims to give you a real problem-solving experience, similar to what you might encounter in the workplace. You have been hired to complete a ...

There are several ways to calculate the pulse width of a

There are several ways to calculate the pulse width of a digital input signal. One method is to directly read the input pin and another method (more efficient) is to use a timer and pin change interrupt. Function startTi ...

Why do researcher drop the ewaste and where does it end

Why do researcher drop the ewaste and where does it end up?

Assign ment - genetic algorithmin this assignment you will

ASSIGN MENT - GENETIC ALGORITHM In this assignment, you will use your C programming skills to build a simple Genetic Algorithm. DESCRIPTION OF THE PROGRAM - CORE REQUIREMENTS - REQ1: Command-line arguments The user of yo ...

Assignment word matchingwhats a six-letter word that has an

Assignment: Word Matching What's a six-letter word that has an e as its first, third, and fifth letter? Can you find an anagram of pine grave. Or how about a word that starts and ends with ant (other than ant itself, of ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As