Welcome to www.programmer2programmer.net Its all about security programming source code


 Microsoft Certification
 Final Year Project Idea
 Connection Strings
 Password Recovery
 SQL Injection
 Encryption & Decryption
 LIVE Academic Project
 Project #1 - VB6, Access
  Project #2 - VB.Net, SQL
 Project #3 - ASP, Access
 Project #4 - ASP.NET, C#
 Project #5 - VB6, SQL
 Project #6 - Stegano
 Project #7 - C
 Project #8 - C++
 Project #9 - JAVA, MySQL
 Project #10- PHP, MySQL
 Project #11- JSP, Oracle
 Project #12- C# Face Exp
 Project #13- Mobile Bank
 Download MBA Project
 MBA Project Topic
 Project Viva Question
  2018 New Projects
 Project Synopsis Download
 University Question Paper, Assignment and Projects
 SMU - Question Paper
 SMU - Assignment
 SMU - Synopsis Projects
 SCDL - Assignment
 IGNOU - Synopsis Projects
 Welingkar - Projects
 Project Report Formats
 Interview Question Answer
 General & HR Round
 Visual Basic 6
 VB.Net & C#
 SQL Server
  Oracle and DBA

100% Tested
Ready Academic IT Projects


 Free Visual Basic .Net source code download of Transposition or Geometrical  Pattern Encryption Decryption

Home Personal Member Forum Source Project Tips Contact

Transposition Encryption

Transposition Encryption or Geometrical Pattern Encoding Encryption Decryption technique written in Visual Basic .NET.
Click here to Download the source code.


In transposition and geometrical pattern encoding the text is rearranged with the aid of some type of geometric figure, a typical example being a two - dimensional array or a matrix, First plain text message is written into the figure according to a particular matrix, the cipher text then created by taking the letters off the matrix according to a different path.

1. Encryption / Decryption


2. XOR Encryption

3. Transposition Encryption
4. Symmetric Encryption
5. Asymmetric Encryption
6. Certificate Authority

7. Decryption Logics

8. Sample Coding

Next : PK Encrypter

Screen shot


First we set our matrix, it is a multidirectional array, user can set the array dimension, the pattern of cipher text depends on matrix dimension. After creating the array we put plain text character by character into the array pocket, when the array is filled we moved the text from the array to the temporary string variable, then reset the array and continue until the plain text is completely covered.

            For j = i To LastPos
                '>>> check if need to XOR the character
                If ChkXOR.Checked = True Then
                    Dim TempChar As String
                    TempChar = Mid(StrDataIn, j, 1)
                    DataArray(r, c) = Chr(Asc(TempChar) Xor XORCode)
                    DataArray(r, c) = Mid(StrDataIn, j, 1)
                End If
                c = c + 1
                '>>> reset the array indexer
                If r > IndR - 1 Then
                    r = 0
                    c = 0
                End If
                If c > IndC - 1 Then
                    c = 0
                    r = r + 1
                End If

After that we transpose the array by row and column, here you can improve if you want, you can create another array to order the transposition. After transposition loop the array and concatenate all the array element into and string variable and return it as a cipher text. If you check the XOR option it will XOR the output cipher text. In case of decryption you need to transpose the array in reverse order to get the plain text. Lastly remove the filler character from the final output, we use chr(1).

        Dim StrTemp As String
        StrTemp = ""
        Dim p, p1 As Integer
        p = 1
        p1 = 1
        For r = 0 To IndR - 1
            For c = 0 To IndC - 1
                StrTemp = StrTemp & DataArray(r, c)
        While p <= StrTemp.Length
            '>>> replace array filling character
            '>>> check if it is xor
            If ChkXOR.Checked = True Then
                StrOut = StrOut & Replace(Mid(StrTemp, p1, 1), _
                Chr(Asc(Chr(1)) Xor XORCode), "")
                StrOut = StrOut & Replace(Mid(StrTemp, p1, 1), Chr(1), "")
            End If
            p = p + 1
            '>>> increment position by row
            p1 = p1 + IndR
            If p1 > StrTemp.Length Then
                p1 = p1 - StrTemp.Length + 1
            End If
        End While

If you combine Transposition Encryption with XOR Encryption it will produce near to impossible cipher text. May be for professional hacker, cracker it is not very hard to break, however for normal security need and easy to implement it is quite used today.

Download the source code and project files


It is free to download, source code are well commented, complete visual basic .net source code can be download from the download link. I did not claim any copyright for this Transposition Encryption program and source code. You can freely download this Transposition Encryption program and use all or part of this program as you want. This is tested and live project visual basic source code however, my advice to you that you should take a backup of your original text and data file before use this Transposition Encryption program.

  Language: Visual Basic .NET   Platform: Win 2000, Win XP
  Category: Security Programming   Cost: $0.0
  Copyright: NO   Source Code: YES
  Size: 95 KB   Download: 768 Times
  No of Files: 15


(C) Atanu Maity, 2006-2018