49
Cryptography on the Grid A. Suciu, R. Potolea Technical University of Cluj-Napoca

Technical University of Cluj-Napoca

  • Upload
    others

  • View
    0

  • Download
    0

Embed Size (px)

Citation preview

Cryptography on the Grid

A. Suciu, R. PotoleaTechnical University of Cluj-Napoca

17.04.2008 EGEE Workshop - UTCN 2

Contents

ContextPreliminary WorkGoalsTaxonomy for the GridCryptographic AlgorithmsExperimental ResultsWeb InterfaceConclusion

17.04.2008 EGEE Workshop - UTCN 3

Context

The GridMOSI Project (2005-2008)Virtual Organization using Grid Technology for High Performance Modeling, Simulation and OptimizationFive Institutions (ICI, UPB, INCAS, UTCN, UVT)Lead by: Dr. Ing. Gabriel NeaguUTCN participation - Modeling and Optimization for Cryptology

17.04.2008 EGEE Workshop - UTCN 4

Context (2)

The UTCN grid node (simplified view)

17.04.2008 EGEE Workshop - UTCN 5

Context (3)

The UTCN grid node:22 processors – P4 class, 3GHz1GB RAM / processor160 GB HDD / processorOS – Scientific Linux 3.0.8Middleware - g-lite 3.0.2 Experiments were performed on other nodes of the grid as well

17.04.2008 EGEE Workshop - UTCN 6

Preliminary Work

Finding the Optimal Read Buffer Size for Grid Applications

Local Read

1

10

100

1000

10000

1 10 100 1000 10000 100000 1000000

Buffer Size (bytes)

log(

Read

Tim

e (m

s))

FileSize = 8 MBFileSize = 10MBFileSize = 5 MB

17.04.2008 EGEE Workshop - UTCN 7

Preliminary Work (2)

Finding the Optimal Read Buffer Size for Grid Applications - [130,000; 290,000]

Local Read - Refined

00.050.1

0.150.2

0.250.3

0.35

1000

050

000

9000

013

0000

1700

0021

0000

2500

0029

0000

3300

0037

0000

4100

0045

0000

4900

00

Read Buffer (bytes)

Rea

d tim

e (s

)

File Size = 450 MBFile Size = 600 MB

17.04.2008 EGEE Workshop - UTCN 8

Preliminary Work (3)

Finding the Optimal Read Buffer Size for Grid Applications - [150,000; 300,000]

17.04.2008 EGEE Workshop - UTCN 9

Preliminary Work (4)

Finding the optimal number of worknodes for a given size of a problem:

Matrix MultiplicationGauss EliminationMinimum Spanning TreeShortest PathTransitive ClosureGraph IsomorphismSorting Algorithms

17.04.2008 EGEE Workshop - UTCN 10

Preliminary Work (5)

Matrix Multiplication 2D

0

10

20

30

40

50

60

70

80

90

100

0 5 10 15 20 25 30 35 40

Processors

Tim

e %

1000

700

300

100

17.04.2008 EGEE Workshop - UTCN 11

Preliminary Work (6)Gauss Elimination

1

10

100

1000

10000

100000

1 2 4 8 16 20 25

Processors

Tim

e (m

s) 2000800400200

17.04.2008 EGEE Workshop - UTCN 12

Preliminary Work (7)

QuickSort

0

10

20

30

40

50

60

70

80

90

100

1 2 4 8 16 36

Processors

Tim

e %

100 000500 0001 000 0003 000 000

17.04.2008 EGEE Workshop - UTCN 13

Preliminary Work (8)

Minumum Spanning Tree

0

10

20

30

40

50

60

70

80

90

100

1 2 4 8 10 20 25

Processors

Tim

e %

500100020005000

17.04.2008 EGEE Workshop - UTCN 14

Preliminary Work (9)

Graph Isomorphism

1

10

100

1000

10000

100000

1000000

0 2 4 6 8 10 12 14

Processors

Tim

e - l

ogar

ithm

ic s

cale

9 vertices10 vertices11 vertices12 vertices

17.04.2008 EGEE Workshop - UTCN 15

Preliminary Work (10)

FFT

1

10

100

1000

10000

100000

1 2 4 8 16 32

Processors

Tim

e

819240961024512

17.04.2008 EGEE Workshop - UTCN 16

Papers (2006)I. Gligan, R. Potolea and A. Suciu. Grid Computing: A New Approach to Solving Large Scale Problems. ACAM, ISSN 1221–437X, Vol. 15 (2006) no. 1, pp. 159–170.A. Mascasan, R. Potolea and A. Suciu. Optimal Buffer Size for Grid Applications. ACAM, ISSN 1221–437X, Vol. 15 (2006) no. 1, pp. 203–210.I. Leonte, A. Suciu and E. Cebuc. OptimizingCryptographic Algorithms by Parallel Grid-based Execution. ACAM, ISSN 1221–437X, Vol. 15 (2006) no. 1, pp. 185–192.

17.04.2008 EGEE Workshop - UTCN 17

Goals

determine the degree of suitability of cryptographic algorithms for grid executionfinding ways of parallelization of the algorithms on a grid architecture finding suitable execution (working) modes for the grid infrastructureimprove performanceprovide a “library” of algorithms for grid applications

17.04.2008 EGEE Workshop - UTCN 18

Taxonomy (0)

Practical observation on what happens on the grid:Programs consume files and produce other filesIt would be nice to be able to:

Apply same program on several filesApply several programs on the same fileApply several programs on several files

17.04.2008 EGEE Workshop - UTCN 19

Taxonomy

Flynn’s taxonomy :SISDSIMDMISDMIMD

Our taxonomy :SPSDSPMDMPSDMPMD

17.04.2008 EGEE Workshop - UTCN 20

Taxonomy (2)

Adapting our taxonomy for the GridProgram = ExecutableData = File / FilesProblems:

Programs have additional parametersFind a unitary approach for all 4 categories – batch scripts, easy to useExploit parallelism where available

17.04.2008 EGEE Workshop - UTCN 21

Taxonomy (3)

SPSD/L [Local execution]SPSD/G [Grid execution]SPMD/G [Grid]SPMD/G/DP [Grid, data parallel]MPSD/G [Grid]MPSD/G/DP [Grid, data parallel]MPMD/G [Grid]MPMD/G/DP [Grid, data parallel]

17.04.2008 EGEE Workshop - UTCN 22

Taxonomy (4)SPSD-L (Single Program Single Data - Local)

17.04.2008 EGEE Workshop - UTCN 23

Taxonomy (5)SPSD-G (Single Program Single Data - Grid)

17.04.2008 EGEE Workshop - UTCN 24

Taxonomy (6)SPMD-G (Single Program Multiple Data - Grid)

17.04.2008 EGEE Workshop - UTCN 25

Taxonomy (7)SPMD-G-DP (Single Program Multiple Data -Grid - Data Parallel)

17.04.2008 EGEE Workshop - UTCN 26

Taxonomy (8)MPSD-G (Multiple Program Single Data - Grid)

17.04.2008 EGEE Workshop - UTCN 27

Taxonomy (9)MPSD-G-DP (Multiple Program Single Data -Grid - Data Parallel)

17.04.2008 EGEE Workshop - UTCN 28

Taxonomy (10)MPMD-G (Multiple Program Multiple Data -Grid)

17.04.2008 EGEE Workshop - UTCN 29

Taxonomy (11)MPMD-G-DP (Multiple Program Multiple Data-Grid-Data Parallel)

17.04.2008 EGEE Workshop - UTCN 30

Cryptographic & Cryptanalitic Algorithms

Block ciphers (all AES finalists)Stream ciphers (RC4)Public key ciphers (RSA)Hash functions (SHA-1, SHA-2)Random number generators (NIST, Diehard)Random number tests (NIST, Diehard)

17.04.2008 EGEE Workshop - UTCN 31

Experimental Results

Block ciphers:MarsRC6RijndaelSerpentTwofish

0

2

4

6

8

10

12

Time (s)

Mars RC6 Rijndael Serpent Twofish

Algorithm

17.04.2008 EGEE Workshop - UTCN 32

Experimental Results (2)

Block ciphers:Rijndael -in data parallel, grid based execution mode

0

0.05

0.1

0.15

0.2

0.25

0.3

0.35

0.4

0.45

Time (s)

1 2 4 8 16 32 64 128

Node Count

17.04.2008 EGEE Workshop - UTCN 33

Experimental Results (3)

Stream ciphers:RC4

Not suitable for data parallel, grid based executionInherently sequential Each byte depends on all previous bytesCan be used, but not in data parallel modes

17.04.2008 EGEE Workshop - UTCN 34

Experimental Results (4)

Public key ciphers:

RSA

Most time consuming operation is key-pair generation 0

0.2

0.4

0.6

0.8

1

1.2

512 1024 1536 2048

time

17.04.2008 EGEE Workshop - UTCN 35

Experimental Results (5)

Public key ciphers:

RSA

Fortunately key-pair generation can be parallelized

0

1

2

3

4

5

time (s)

1024 1536 2048

prime size

SPSDSPMD

17.04.2008 EGEE Workshop - UTCN 36

Experimental Results (6)

Hash functions:SHA-1SHA-2

Not suitable for data parallel, grid based executionInherently sequential Can be used, but not in data parallel modes

17.04.2008 EGEE Workshop - UTCN 37

Experimental Results (7)Random number generators:

Linear-CongruentialBlum-Blum-ShubMicali-SchnorrModular-ExponentiationQuadratic-Congruential-1,2Cubic-CongruentialXORMersenne Twister

Extremely suitable for data parallel, grid based execution

17.04.2008 EGEE Workshop - UTCN 38

Experimental Results (9)

Random number testing:NIST tests (16)Diehard tests (15)

Some tests are very time consuming (ex: Fourier spectral test)Extremely suitable for data parallel, grid based execution

17.04.2008 EGEE Workshop - UTCN 39

Web interface

Authentication

17.04.2008 EGEE Workshop - UTCN 40

Web interface

Validation

17.04.2008 EGEE Workshop - UTCN 41

Web interface

File transfer

17.04.2008 EGEE Workshop - UTCN 42

Web interface

Encrypting MPMD-G-DP

17.04.2008 EGEE Workshop - UTCN 43

Web interface

List of submitted jobs

17.04.2008 EGEE Workshop - UTCN 44

Web interface

Get status

17.04.2008 EGEE Workshop - UTCN 45

Web interface

Get output

17.04.2008 EGEE Workshop - UTCN 46

Papers (2007)A. Suciu, R Potolea, “Towards a GridMOSILibrary”, 6th RoEduNet International Conference, 23-24 Nov. 2007, Craiova, Romania, ISBN 987-973-746-581-8, pp. 74-79.R. Potolea, A. Suciu, A. Măşcăşan, "Benchmarking the Gridmosi Library", eChallenges 2007, 24-27 Oct. 2007, The Hague, Netherlands, ISBN 978-1-58603-801-4, pp. 138-145.

17.04.2008 EGEE Workshop - UTCN 47

Papers (2007)R. Potolea, A. Suciu, “Finding the Optimal Read Buffer Size for Grid Applications”, 9th International Symposium on Symbolic and Numeric Algorithms for Scientific Computing Timisoara, Romania September 26-29, 2007, Workshop on Grid Computing Applications Development, pp. 51-54.A. Suciu, R. Potolea, “Cryptographic and Cryptanalytic Algorithms for Grid Applications”, 2007 IEEE International Conference on Intelligent Computer Communication and processing, 6-7 September 2007, Cluj-Napoca, Romania, Workshop on Grid Computing (WGC).

17.04.2008 EGEE Workshop - UTCN 48

ConclusionSeveral categories of cryptographic algorithms were analyzed, implemented and tested for grid-based executionA taxonomy for grid-based execution was developed – 8 execution modesExperimental results show substantial performance improvements (especially in data parallel modes)A “library” of algorithms was developed and is available for grid applications

17.04.2008 EGEE Workshop - UTCN 49

Questions

Thank you for your attention

Questions, please?