Virtual Position Forum
Please register to watch content in detail
Thanks
Admin virtual position


Join the forum, it's quick and easy

Virtual Position Forum
Please register to watch content in detail
Thanks
Admin virtual position
Virtual Position Forum
Would you like to react to this message? Create an account in a few clicks or log in to continue.

IT430 - Cryptography :VB6 APPLICATION:

View previous topic View next topic Go down

GMT + 3 Hours IT430 - Cryptography :VB6 APPLICATION:

Post by saleha Tue Oct 30, 2012 9:26 pm

By Lock2Cube you can lock your applications easily !
[You must be registered and logged in to see this image.]
I have implemented IT430 Topic "Cryptography"
Code:
Public Function Encrypt(Name As String, Key As Long) As String
On Error GoTo en
Dim v As Long, c1 As String, z As String
For v = 1 To Len(Name)
c1 = Asc(Mid(Name, v, 1))
c1 = Chr(c1 + Key)
z = z & c1
Next v
Encrypt = z
Exit Function
en:
Text4.Text = Text4.Text & vbCrLf & "------Encryption Error..!"
Resume Next
End Function


Public Function Decrypt(Name As String, Key As Long) As String
On Error GoTo dec
Dim v As Long, c1 As String, z As String
For v = 1 To Len(Name)
c1 = Asc(Mid(Name, v, 1))
c1 = Chr(c1 - Key)
z = z & c1
Next v
Decrypt = z
Exit Function
dec:
Text4.Text = Text4.Text & vbCrLf & "------Decryption Error..!"
Resume Next
End Function
saleha
saleha
Monstars
Monstars

Pisces Dragon
Posts : 469
Join date : 2012-01-28
Age : 36
Location : ...
Blah

Back to top Go down

GMT + 3 Hours Re: IT430 - Cryptography :VB6 APPLICATION:

Post by saleha Tue Oct 30, 2012 9:27 pm

I am just sharing a bit code so VU students can understand the topic that how it works.

This code brings a strong password combination, which is not easy to break even a brute force attack.
saleha
saleha
Monstars
Monstars

Pisces Dragon
Posts : 469
Join date : 2012-01-28
Age : 36
Location : ...
Blah

Back to top Go down

GMT + 3 Hours Re: IT430 - Cryptography :VB6 APPLICATION:

Post by saleha Tue Oct 30, 2012 9:27 pm

Asc() & Chr() two functions


ASCII CODE TABLE IS BELOW :
Codes 0-127

Code Char Code Char Code Char Code Char
0 32 64 @ 96 `
1 33 ! 65 A 97 a
2 34 " 66 B 98 b
3 35 # 67 C 99 c
4 36 $ 68 D 100 d
5 37 % 69 E 101 e
6 38 & 70 F 102 f
7 39 ' 71 G 103 g
8 40 ( 72 H 104 h
9 41 ) 73 I 105 i
10 42 * 74 J 106 j
11 43 + 75 K 107 k
12 44 , 76 L 108 l
13 45 - 77 M 109 m
14 46 . 78 N 110 n
15 47 / 79 O 111 o
16 48 0 80 P 112 p
17 49 1 81 Q 113 q
18 50 2 82 R 114 r
19 51 3 83 S 115 s
20 52 4 84 T 116 t
21 53 5 85 U 117 u
22 54 6 86 V 118 v
23 55 7 87 W 119 w
24 56 8 88 X 120 x
25 57 9 89 Y 121 y
26 <> 58 : 90 Z 122 z
27 59 ; 91 [ 123 {
28 60 < 92 \ 124 |
29 61 = 93 ] 125 }
30 62 > 94 ^ 126 ~
31 63 ? 95 _ 127


[You must be registered and logged in to see this image.]
saleha
saleha
Monstars
Monstars

Pisces Dragon
Posts : 469
Join date : 2012-01-28
Age : 36
Location : ...
Blah

Back to top Go down

GMT + 3 Hours Re: IT430 - Cryptography :VB6 APPLICATION:

Post by Sponsored content


Sponsored content


Back to top Go down

View previous topic View next topic Back to top


Permissions in this forum:
You cannot reply to topics in this forum