begin process at 2012 02 16 07:24:58
  Trouver un code source :
 
dans
 
Accueil > 

Code

 > 

Sécurité

 > CRYPTER À LA MANIERE DE CESAR

CRYPTER À LA MANIERE DE CESAR


 Information sur la source

Note :
4,4 / 10 - par 5 personnes
4,40 / 10

  • 1

  • 2

  • 3

  • 4

  • 5

  • 6

  • 7

  • 8

  • 9

  • 10
Catégorie :Sécurité Classé sous :crypter, cesar Niveau :Débutant Date de création :08/08/2001 Vu :3 180

Auteur : Majen

Ecrire un message privé
Site perso
Commentaire sur cette source (2)
Ajouter un commentaire et/ou une note

 Description

C'est un simple décalage de lettre

text1 = msg normal
text2 = msg crypté
text3 = clef

Source

  • Dim i As Integer
  • Dim x, xx, xxx
  • Form1.Text2 = ""
  • For i = 1 To Len(Form1.Text1)
  • x = Mid$(Form1.Text1, i, 1)
  • If x = "a" Or x = "A" Then xx = 1 + Text3
  • If x = "b" Or x = "B" Then xx = 2 + Text3
  • If x = "c" Or x = "C" Then xx = 3 + Text3
  • If x = "d" Or x = "D" Then xx = 4 + Text3
  • If x = "e" Or x = "E" Then xx = 5 + Text3
  • If x = "f" Or x = "F" Then xx = 6 + Text3
  • If x = "g" Or x = "G" Then xx = 7 + Text3
  • If x = "h" Or x = "H" Then xx = 8 + Text3
  • If x = "i" Or x = "I" Then xx = 9 + Text3
  • If x = "j" Or x = "J" Then xx = 10 + Text3
  • If x = "k" Or x = "K" Then xx = 11 + Text3
  • If x = "l" Or x = "L" Then xx = 12 + Text3
  • If x = "m" Or x = "M" Then xx = 13 + Text3
  • If x = "n" Or x = "N" Then xx = 14 + Text3
  • If x = "o" Or x = "O" Then xx = 15 + Text3
  • If x = "p" Or x = "P" Then xx = 16 + Text3
  • If x = "q" Or x = "Q" Then xx = 17 + Text3
  • If x = "r" Or x = "R" Then xx = 18 + Text3
  • If x = "s" Or x = "S" Then xx = 19 + Text3
  • If x = "t" Or x = "T" Then xx = 20 + Text3
  • If x = "u" Or x = "U" Then xx = 21 + Text3
  • If x = "v" Or x = "V" Then xx = 22 + Text3
  • If x = "w" Or x = "W" Then xx = 23 + Text3
  • If x = "x" Or x = "X" Then xx = 24 + Text3
  • If x = "y" Or x = "Y" Then xx = 25 + Text3
  • If x = "z" Or x = "Z" Then xx = 26 + Text3
  • Do While xx > 26
  • xx = xx - 26
  • Loop
  • If xx = 1 Then xxx = "a"
  • If xx = 2 Then xxx = "b"
  • If xx = 3 Then xxx = "c"
  • If xx = 4 Then xxx = "d"
  • If xx = 5 Then xxx = "e"
  • If xx = 6 Then xxx = "f"
  • If xx = 7 Then xxx = "g"
  • If xx = 8 Then xxx = "h"
  • If xx = 9 Then xxx = "i"
  • If xx = 10 Then xxx = "j"
  • If xx = 11 Then xxx = "k"
  • If xx = 12 Then xxx = "l"
  • If xx = 13 Then xxx = "m"
  • If xx = 14 Then xxx = "n"
  • If xx = 15 Then xxx = "o"
  • If xx = 16 Then xxx = "p"
  • If xx = 17 Then xxx = "q"
  • If xx = 18 Then xxx = "r"
  • If xx = 19 Then xxx = "s"
  • If xx = 20 Then xxx = "t"
  • If xx = 21 Then xxx = "u"
  • If xx = 22 Then xxx = "v"
  • If xx = 23 Then xxx = "w"
  • If xx = 24 Then xxx = "x"
  • If xx = 25 Then xxx = "y"
  • If xx = 26 Then xxx = "z"
  • Form1.Text2 = Form1.Text2 & xxx
  • Next i
  • ' (c) Majen da l33t c0d4h ! huhu
Dim i As Integer
Dim x, xx, xxx
Form1.Text2 = ""
For i = 1 To Len(Form1.Text1)
 x = Mid$(Form1.Text1, i, 1)
  If x = "a" Or x = "A" Then xx = 1 + Text3
  If x = "b" Or x = "B" Then xx = 2 + Text3
  If x = "c" Or x = "C" Then xx = 3 + Text3
  If x = "d" Or x = "D" Then xx = 4 + Text3
  If x = "e" Or x = "E" Then xx = 5 + Text3
  If x = "f" Or x = "F" Then xx = 6 + Text3
  If x = "g" Or x = "G" Then xx = 7 + Text3
  If x = "h" Or x = "H" Then xx = 8 + Text3
  If x = "i" Or x = "I" Then xx = 9 + Text3
  If x = "j" Or x = "J" Then xx = 10 + Text3
  If x = "k" Or x = "K" Then xx = 11 + Text3
  If x = "l" Or x = "L" Then xx = 12 + Text3
  If x = "m" Or x = "M" Then xx = 13 + Text3
  If x = "n" Or x = "N" Then xx = 14 + Text3
  If x = "o" Or x = "O" Then xx = 15 + Text3
  If x = "p" Or x = "P" Then xx = 16 + Text3
  If x = "q" Or x = "Q" Then xx = 17 + Text3
  If x = "r" Or x = "R" Then xx = 18 + Text3
  If x = "s" Or x = "S" Then xx = 19 + Text3
  If x = "t" Or x = "T" Then xx = 20 + Text3
  If x = "u" Or x = "U" Then xx = 21 + Text3
  If x = "v" Or x = "V" Then xx = 22 + Text3
  If x = "w" Or x = "W" Then xx = 23 + Text3
  If x = "x" Or x = "X" Then xx = 24 + Text3
  If x = "y" Or x = "Y" Then xx = 25 + Text3
  If x = "z" Or x = "Z" Then xx = 26 + Text3
  
  Do While xx > 26
    xx = xx - 26
  Loop
  
  If xx = 1 Then xxx = "a"
  If xx = 2 Then xxx = "b"
  If xx = 3 Then xxx = "c"
  If xx = 4 Then xxx = "d"
  If xx = 5 Then xxx = "e"
  If xx = 6 Then xxx = "f"
  If xx = 7 Then xxx = "g"
  If xx = 8 Then xxx = "h"
  If xx = 9 Then xxx = "i"
  If xx = 10 Then xxx = "j"
  If xx = 11 Then xxx = "k"
  If xx = 12 Then xxx = "l"
  If xx = 13 Then xxx = "m"
  If xx = 14 Then xxx = "n"
  If xx = 15 Then xxx = "o"
  If xx = 16 Then xxx = "p"
  If xx = 17 Then xxx = "q"
  If xx = 18 Then xxx = "r"
  If xx = 19 Then xxx = "s"
  If xx = 20 Then xxx = "t"
  If xx = 21 Then xxx = "u"
  If xx = 22 Then xxx = "v"
  If xx = 23 Then xxx = "w"
  If xx = 24 Then xxx = "x"
  If xx = 25 Then xxx = "y"
  If xx = 26 Then xxx = "z"
 Form1.Text2 = Form1.Text2 & xxx
Next i

' (c) Majen da l33t c0d4h ! huhu 

 Conclusion

PS : ça ne garanti aucune sécurité


 Sources du même auteur

Source avec Zip SERIAL RENAMER
Source avec Zip TEST DE LUCIDIDÉ
Source avec Zip MORSE
Source avec Zip INTRODUCTION AU VISUAL BASIC
SUBSTITUTION POLYALPHABÉTIQUE (VIGENERE)

 Sources de la même categorie

Source avec Zip Source avec une capture Source .NET (Dotnet) CHIFFREMENT XOR PLUS ROBUSTE par dheroux
Source avec Zip CRYPTAGE MARANT par alpha5
Source avec Zip ACCÈS PAR MOT DE PASSE À FEUILLE EXCEL par mimiZanzan
Source avec Zip CRYPTER-DÉCRYPTER UN TEXTE - TEXTE CRYPTÉ UNIQUEMENT EN MAJ... par Saintache
Source avec Zip Source avec une capture FOLDER PROTECTION par hackoo

 Sources en rapport avec celle ci

Source avec Zip Source avec une capture SECURITEMESSAGE,CRYPTER,CRYPTOGRAPHIE par okosa
Source avec Zip Source .NET (Dotnet) CRYPTER ET DÉCRYPTER TOUS TYPES DE FICHIERS "TEXTE ,IMAGES, ... par miccorse
Source avec Zip Source .NET (Dotnet) CRYPTEUR/DECRYPTEUR par zippedfire
Source avec Zip CRYPTER-DÉCRYPTER UN TEXTE - TEXTE CRYPTÉ UNIQUEMENT EN MAJ... par Saintache
Source .NET (Dotnet) DÉCOMPRESSER EN .NET PLUSIEURS FORMATS POPULAIRES D'ARCHIVAG... par NikatorS

Commentaires et avis

Commentaire de mythic_kruger le 16/07/2005 08:32:03

Ben mon vieux un codage Cesar tient en trois lignes de code.
Il faut employer les fonctions asc() et chr() pour travailler sur le code ASCII des caractères. En plus ça permet de gérer TOUS les caractères ASCII.
for n=1 to len(string)
xx=xx & chr((asc(mid(string,n,1))+1) mod 256)
next n
A plus nol33t coda

Commentaire de mythic_kruger le 16/07/2005 08:38:04

De plus si c'est un codage César il n' y a pas de clé (si: chr(1) cad le premier caractère ASCII, puisqu'on ajoute 1). Donc tu parles d'une clé sur Text3 qui se révèle uptopique. Bref c'est très très limite comme code. 4 ans après.

 Ajouter un commentaire


Discussions en rapport avec ce code source dans le forum

Crypter une base de données [ par rachid ] je suis entrain de développer une application (avec VB6) qui utilisera des bases de données Access.Comment faire pour qu'on puisse utiliser ces bases FSO Aide!... Crypter [ par AgentSmith ] Salut à tous,Je vous solicite pour la raison d'un peti programme que je develope.Ce programme sert à crypter tous les codes ASPde toutes les pages d'u Crypter dans la base de registre [ par BURN ] Comment on fait pour crypter de quoi dans la base de régistre ??????????????????????C'est très IMPORTANT !Merci question pour crypter ce que j'enregistre [ par cedstyle70 ] voila bonjour tout le monde je commence dans la programmation et me suis amuser a créer ca avec un copain, c'est un programme qui me sert de "base de aide cryptage [ par rems02 ] je voudrais crypter un dossiermais je ne sais pas comment l'ouvriren binaire pour pouvoir le crypter.merci de votre aiderems obtenir le mdp d'un .exe crypter avec.... [ par cav ] bonjour,voila je voudrai savoir comment retrouver le mot de passe d'un fichier exe crypter avec le logiciel "invibles secrets 4" j'ai fait une boulete comment loader une image crypter [ par geri ] Bonjour,j'ai certaines questions concernant le cryptage et loader des images avec vb.net.je fait une application qui doit faire afficher mes dessins t md5 ??? [ par Nerdz ] Salut,Jai des mots de passe et logins dans une base mysql crypter en md5...et j'aimerais faire la vérification des users..Donc il entre son login et p Très urgent: Cryptage [ par YannGotti ] Je shouaiterais savoir s'il y à une possibilité de crypter un fichier avec une simple cléf stringFichier: |C:\Essais.txt|Code: |*****||Crypter| |Decry Crypter [ par KKVDC ] Quels'un aurrais une source pour Crypter un Fichiers vbs via un prog créé en vb6 ?Merci de me repondre.


Nos sponsors


Sondage...

Comparez les prix

CalendriCode

Février 2012
LMMJVSD
  12345
6789101112
13141516171819
20212223242526
272829    

Consulter la suite du CalendriCode

Photothèque

 
Développement réalisé par Nicolas SOREL (Nix) avec l'aide de : Cyril DURAND et Emmanuel (EBArtSoft), Merci à Vincent pour ses précieux conseils.
CodeS-SourceS.com© Toute reproduction même partielle est interdite sauf accord écrit du Webmaster
CodeS-SourceS.com© est une marque déposée tous droits réservés

Google Coop CodeS-SourceS Google Coop CodeS-SourceS
Temps d'éxécution de la page : 4,243 sec (3)

Nous contacter | Annoncer sur CodeS-SourceS | Mentions légales