encryption

Please support our Assembly advertiser: Programming Forums - DaniWeb Sister Site
Reply

Join Date: Dec 2008
Posts: 10
Reputation: raseel is an unknown quantity at this point 
Solved Threads: 0
raseel raseel is offline Offline
Newbie Poster

Re: Let's learn assembly!

 
0
  #1
Dec 8th, 2008
emergent;help i a project in encryption any text of alphapets and numbers into a random characters(from A-Z and 0-9 numbers)
using assembly
if u please
Reply With Quote Quick reply to this message  
Join Date: Nov 2008
Posts: 23
Reputation: low_coder is an unknown quantity at this point 
Solved Threads: 2
low_coder low_coder is offline Offline
Newbie Poster

Re: encryption

 
0
  #2
Dec 9th, 2008
encryption any text of alphapets and numbers into a random characters
; do you want later to decrypt it back or no?
Reply With Quote Quick reply to this message  
Join Date: Dec 2008
Posts: 10
Reputation: raseel is an unknown quantity at this point 
Solved Threads: 0
raseel raseel is offline Offline
Newbie Poster

Re: encryption

 
0
  #3
Dec 9th, 2008
yes encryption and decryption code
and reading the text from a text file
thanks
Last edited by raseel; Dec 9th, 2008 at 9:53 am.
Reply With Quote Quick reply to this message  
Join Date: Dec 2005
Posts: 5,850
Reputation: Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute Salem has a reputation beyond repute 
Solved Threads: 751
Team Colleague
Salem's Avatar
Salem Salem is offline Offline
Void main'ers are DOOMed

Re: encryption

 
0
  #4
Dec 9th, 2008
Start simple - write a program which just copies the file, one character at a time.

Until you can do that reliably, there's no point trying to implement a crypt/decrypt, because you'll have no way to test it.
Reply With Quote Quick reply to this message  
Join Date: Nov 2008
Posts: 23
Reputation: low_coder is an unknown quantity at this point 
Solved Threads: 2
low_coder low_coder is offline Offline
Newbie Poster

Re: encryption

 
0
  #5
Dec 9th, 2008
; here is a simple encrypting/decrypting app.:
; on encryption it will just inc hex values represented byeach char
; on decryption dec
  1. .386
  2. .model flat,stdcall
  3. option casemap:none
  4. include \masm32\include\windows.inc
  5. include \masm32\include\user32.inc
  6. include \masm32\include\kernel32.inc
  7. include \masm32\include\masm32.inc
  8. includelib \masm32\lib\user32.lib
  9. includelib \masm32\lib\kernel32.lib
  10. includelib \masm32\lib\masm32.lib
  11.  
  12. .data?
  13. szBuff db 256 dup(?)
  14. .code
  15. start:
  16. invoke AllocConsole
  17. invoke StdIn, ADDR szBuff, sizeof szBuff
  18.  
  19. lblCrypt:
  20. mov eax, offset szBuff
  21. @@:
  22. cmp byte ptr [eax],0
  23. je lblPrint
  24. inc byte ptr [eax]
  25. inc eax
  26. jmp @B
  27.  
  28. lblPrint:
  29. mov eax, offset szBuff
  30. invoke StdOut, ADDR szBuff
  31.  
  32. lblDecrypt:
  33. mov eax, offset szBuff
  34. @@:
  35. cmp byte ptr [eax],0
  36. je lblExit
  37. dec byte ptr [eax]
  38. inc eax
  39. jmp @B
  40.  
  41. lblExit:
  42. mov eax, offset szBuff
  43. invoke StdOut, ADDR szBuff
  44. invoke ExitProcess, 0
  45. end start
Reply With Quote Quick reply to this message  
Join Date: Dec 2008
Posts: 10
Reputation: raseel is an unknown quantity at this point 
Solved Threads: 0
raseel raseel is offline Offline
Newbie Poster

Re: encryption

 
0
  #6
Dec 10th, 2008
thanks a lot .but it is only allowed for me to use TASM for 8086 ,and u here used MASM ,it is a little bit different could u help me to do this
thanks again
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the Assembly Forum


Views: 750 | Replies: 5
Thread Tools Search this Thread



Tag cloud for Assembly
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC