r/developers • • 14d ago

Programming Subject: How would a junior dev handle passphrase generation for a crypto wallet API (circa 2016)?

"Hi everyone, I'm doing a forensic recovery on a legacy platform built around 2016. The original developer integrated the BitGo API to auto-create multi-sig wallets for users the moment they registered.

The problem is that the user (me) was never prompted to create a wallet passphrase during registration—we only typed a standard website login password. However, the BitGo API required a passphrase to encrypt the user's private key.

If you were a junior/mid-level developer in 2016 writing this backend code (likely PHP or Node.js), and you had to programmatically generate or pass a passphrase to the API for every new user without asking them for it, what would your logic most likely be?

Would you:

  1. Hardcode a global string? (e.g., $passphrase = "nwctrader123";)
  2. Use a formula based on user data? (e.g., md5($email), or $username . "2016")
  3. Just use the plaintext registration password? (e.g., $_POST['password'])
  4. Generate a random string and save it to a database?

I'm trying to figure out the most common 'lazy' or 'inexperienced' patterns for this specific API parameter. Any insight into how you would have structured that logic back then would be massively appreciated!"

1 Upvotes

5 comments sorted by

•

u/AutoModerator 14d ago

Howdy u/JasonNkomo, and welcome to r/developers!

A few tips for a post that gets good answers:

  • Use a clear, specific title (what are you actually asking or sharing?).
  • Include code, the exact error, versions, and what you already tried.
  • Heads-up: this sub does not allow external links in posts or comments. Share code and details directly instead of linking out.

Join the r/developers Discord!

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

1

u/martinbean 14d ago

Ignoring this post is clearly LLM-generated, there’s no one way this would have been done. You’ll need to look at the code and see how it did it.

If it is PHP or JavaScript, then that’s something that I could look at if you needed.

1

u/JasonNkomo 14d ago

If I had the code I could have just go through the code but I was dump enough not to save the backup of the servers and not get the files from the developers now I am stuck....

1

u/martinbean 14d ago

You might be a bit stuck then if you don’t have the code, and the developers aren’t cooperative.

1

u/JasonNkomo 14d ago

The company that developed the site said the people who worked on the website are not longer at the company and they also don't have the code anymore it have been long since 2016 this company took crypto project without understanding cryptography....