Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7247967
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T22:04:34+00:00 2026-05-28T22:04:34+00:00

I am writing an encryption application that requires a 64 bit key. I am

  • 0

I am writing an encryption application that requires a 64 bit key. I am currently using the following code to automatically generate a key.

Function GenerateKey() As String
    ' Create an instance of a symmetric algorithm. The key and the IV are generated automatically.
    Dim desCrypto As DESCryptoServiceProvider = DESCryptoServiceProvider.Create()

    ' Use the automatically generated key for encryption. 
    Return ASCIIEncoding.ASCII.GetString(desCrypto.Key)

End Function

I am wanting the user to create their own key. Can I convert a user defined password (a string) into a 64 bit key that can be used?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T22:04:35+00:00Added an answer on May 28, 2026 at 10:04 pm

    The answer depends on how secure you want it to be, I’m no security expert so I wouldn’t give advice on it.

    I did see this though: http://msdn.microsoft.com/en-us/library/system.security.cryptography.rfc2898derivebytes.aspx It can be used to derives bytes from a string key and salt in the way Jodrell eluded to, and would be far better than rolling yor own.

    The other constructor that might be suited after that stage is detailed here: http://msdn.microsoft.com/en-us/library/51cy2e75.aspx

    I’m sure if you searched for that on the web you could find examples of how to use it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm writing an application for Android that uses symmetric key encryption to protect sensitive
I have an encryption/copy protection question. I'm writing an application for a company that
Writing documentation in html requires some code examples. What to do with characters that
I'm currently writing an application to PGP encrypt files using the Bouncy Castle API
I'm writing a web application that allows anyone to register (using their OpenID). When
I am writing a kid sister encryption function and I need a PRNG that
I'm writing an implementation of the XXTEA encryption algorithm that works on streams, ie,
I'm writing an iPhone application that needs to send small bits of information (two
i am writing an application that will need to store less than about 1mb
I'm writing an application to Encrtpt/Decrypt files and using DESCryptoServiceProvider for this purpose. This

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.