Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Crypting passwords

Crypting passwords

Scheduled Pinned Locked Moved C / C++ / MFC
windows-admintutorialquestion
7 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    Rickard Andersson20
    wrote on last edited by
    #1

    Here I am again! Well, now I have to know how to encrypt a string into unknown chars, e.g: d45R#! = sw.5v.n7.sd.4r.h5 // sw = d and 5v = 4 and n7 = 5 etc. I know this is difficult (it should be!?), but how to do it? Is there a code somewhere? It would be more safe to make it by your own but I don't know HOW! ;) When I tried to write a binary to the registry I could get the string anyway! :( ------------------------------ ©0d3 ©®4©k3® - That's me! :) ------------------------------

    B 1 Reply Last reply
    0
    • R Rickard Andersson20

      Here I am again! Well, now I have to know how to encrypt a string into unknown chars, e.g: d45R#! = sw.5v.n7.sd.4r.h5 // sw = d and 5v = 4 and n7 = 5 etc. I know this is difficult (it should be!?), but how to do it? Is there a code somewhere? It would be more safe to make it by your own but I don't know HOW! ;) When I tried to write a binary to the registry I could get the string anyway! :( ------------------------------ ©0d3 ©®4©k3® - That's me! :) ------------------------------

      B Offline
      B Offline
      Brad Bruce
      wrote on last edited by
      #2

      Do you need to do 1 way or reversable encryption?

      R 1 Reply Last reply
      0
      • B Brad Bruce

        Do you need to do 1 way or reversable encryption?

        R Offline
        R Offline
        Rickard Andersson20
        wrote on last edited by
        #3

        I don't under stand... But I want to encrypt and then decrypt... ------------------------------ ©0d3 ©®4©k3® - That's me! :) ------------------------------

        M 1 Reply Last reply
        0
        • R Rickard Andersson20

          I don't under stand... But I want to encrypt and then decrypt... ------------------------------ ©0d3 ©®4©k3® - That's me! :) ------------------------------

          M Offline
          M Offline
          Malcolm McMahon
          wrote on last edited by
          #4

          Generally password encryption is done with a "trapdoor" algorithm, i.e. you can't decrypt. You record the encrypted password then, when someone tries to log in or whatever, the password they enter in encrypted through the same algorithm and the encrypted versions compared. This kind of encrypted version is often called a "digest".

          J 1 Reply Last reply
          0
          • M Malcolm McMahon

            Generally password encryption is done with a "trapdoor" algorithm, i.e. you can't decrypt. You record the encrypted password then, when someone tries to log in or whatever, the password they enter in encrypted through the same algorithm and the encrypted versions compared. This kind of encrypted version is often called a "digest".

            J Offline
            J Offline
            James R Twine
            wrote on last edited by
            #5

            Malcolm McMahon wrote: the password they enter in encrypted through the same algorithm and the encrypted versions compared.    Correct.  That is the same thing that I told you (Rickard/CodeCracker) on your earlier post: you can use a MD5 hash, and compare the hashed values to perform matching.    If you will never need to "show" the password to the user (meaning, they can set an initial password, logon with a password, change their password, but never have it shown to them), then using a Digest is a pretty good solution.    Peace! -=- James.

            R 1 Reply Last reply
            0
            • J James R Twine

              Malcolm McMahon wrote: the password they enter in encrypted through the same algorithm and the encrypted versions compared.    Correct.  That is the same thing that I told you (Rickard/CodeCracker) on your earlier post: you can use a MD5 hash, and compare the hashed values to perform matching.    If you will never need to "show" the password to the user (meaning, they can set an initial password, logon with a password, change their password, but never have it shown to them), then using a Digest is a pretty good solution.    Peace! -=- James.

              R Offline
              R Offline
              Rickard Andersson20
              wrote on last edited by
              #6

              Tell me where to read about it! I've tried MSDN Library but can't find anything about the MD5! :( ------------------------------ ©0d3 ©®4©k3® - That's me! :) ------------------------------

              M 1 Reply Last reply
              0
              • R Rickard Andersson20

                Tell me where to read about it! I've tried MSDN Library but can't find anything about the MD5! :( ------------------------------ ©0d3 ©®4©k3® - That's me! :) ------------------------------

                M Offline
                M Offline
                Malcolm McMahon
                wrote on last edited by
                #7

                A google search turned up: The MD5 Homepage

                1 Reply Last reply
                0
                Reply
                • Reply as topic
                Log in to reply
                • Oldest to Newest
                • Newest to Oldest
                • Most Votes


                • Login

                • Don't have an account? Register

                • Login or register to search.
                • First post
                  Last post
                0
                • Categories
                • Recent
                • Tags
                • Popular
                • World
                • Users
                • Groups