Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

gpspad

macrumors 6502a
Original poster
Feb 4, 2014
696
47
I am trying to setup to run a program on my mac. It requires a configuration file and the username in hexadecimal format. Is there a way in terminal to get this?

I have tried just converting the username from plain text to hexadecimal, but that is still hanging it up. I am doing something wrong, but cant seem to find my username as a mac address.
 
I am trying to setup to run a program on my mac. It requires a configuration file and the username in hexadecimal format. Is there a way in terminal to get this?

I have tried just converting the username from plain text to hexadecimal, but that is still hanging it up. I am doing something wrong, but cant seem to find my username as a mac address.

It sounds a lot like you're not exactly clear on what you actually want to achieve.
Based on what you write, I'd say the program expects your username to be hashed in some way, rather than just encoded in a different format. Could that be a correct assumption?
The problem is this: you can use a number of algorithms to generate hashes of text, and unless it says which kind of hash the program expects you to use we can only guess. I'm guessing either sha256 or sha1, in which case the command to generate a hash looks like this, for the respective standards:
echo -n "username" | openssl sha1
echo -n "username" | openssl sha256
 
Thanks for the reply, solved the problem. Turns out it was a dummy value the programmer put into the config file. You have to have something in the field, but it doesn't do anything. I got it working so far.
 
  • Like
Reactions: Mikael H
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.