News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests
NB: Posting URL's See here: Posted URL Change

Main Menu

Macro to simply encode string

Started by quocsan, March 18, 2025, 11:45:10 PM

Previous topic - Next topic

zedd151

Quote from: quocsan on March 20, 2025, 01:38:50 AMFree to code, free to cause problem to my PCs/laptops and my head.  :badgrin:
Been there, done that.  :biggrin:
I was also at times, free from the obligation to go to work every now and then. I told them I had some sort of virus.  :tongue:  I am retired now, and have plenty of time.
¯\_(ツ)_/¯   :azn:

'As we don't do "requests", show us your code first.'  -  hutch—

jj2007

include \masm32\MasmBasic\MasmBasic.inc
  Init
  .if Instr_(GetRegVal("HKCU\Volatile Environment","USERPROFILE", "unknown"), "Zedd")
MsgBox 0, "Please put 100$ on my account, IBAN IT991234675106510650651651", "Hi Zedd", MB_OK
  .else
MsgBox 0, "Congrats, MasmBasic is free!!", "Hi", MB_OK
  .endif
EndOfCode
:cool:

LordAdef

Quote from: jj2007 on March 19, 2025, 10:41:07 PM I'm in bug chasing mode now
This is the name of my current life  :skrewy:


Masmbasic is a great project!

jj2007

Quote from: quocsan on March 18, 2025, 11:45:10 PMI'm awaiting to hearing from you.

Check the attachment ;-)

And, just for fun, build it and run it with a debugger...

quocsan

#19
Quote from: jj2007 on March 22, 2025, 03:23:00 AM
Quote from: quocsan on March 18, 2025, 11:45:10 PMI'm awaiting to hearing from you.

Check the attachment ;-)

And, just for fun, build it and run it with a debugger...
Dear jj2007,
I shall check the app when I'm with Windows PC.
Quick look at the source code, I was thinking of a polymorphic virus until I saw MsgBox.  :badgrin:

EDIT: I've just checked your app on MacBook via Parallel Desktop.
So good! The quite long string was completely obscured!
Now I am thinking of making this feature available on other languages such as C/C++/Pascal.

Last time, accidentally I saw a thread by NoCforMe about Finite State Automaton, so I try learning automata, CFG and the like. Perhaps some day I can build for myself an expression parser in form of a DLL written completely in the assembly language. :-)

NoCforMe

Quote from: quocsan on March 23, 2025, 12:54:53 AMPerhaps some day I can build for myself an expression parser in form of a DLL written completely in the assembly language. :-)

Oh, I have no doubt that you can and will do that.
It's completely within the realm of possibility.
Assembly language programming should be fun. That's why I do it.

jj2007

Quote from: quocsan on March 23, 2025, 12:54:53 AMI shall check the app when I'm with Windows PC.
Quick look at the source code, I was thinking of a polymorphic virus until I saw MsgBox.  :badgrin:

I found the bug in RichMasm, the corrected version is online :biggrin:

To use the feature,
- open a source in RichMasm
- select the text you want to obscure (plain text, don't include quotes)
- go to menu Edit & Format and click on Obscure string (near the bottom)
- move the part between --- start and --- end to where it should run.
- mov ecx, esp: use as needed, but don't forget the stack correction after using it

quocsan

Quote from: jj2007 on March 24, 2025, 08:50:54 AM
Quote from: quocsan on March 23, 2025, 12:54:53 AMI shall check the app when I'm with Windows PC.
Quick look at the source code, I was thinking of a polymorphic virus until I saw MsgBox.  :badgrin:

I found the bug in RichMasm, the corrected version is online :biggrin:

To use the feature,
- open a source in RichMasm
- select the text you want to obscure (plain text, don't include quotes)
- go to menu Edit & Format and click on Obscure string (near the bottom)
- move the part between --- start and --- end to where it should run.
- mov ecx, esp: use as needed, but don't forget the stack correction after using it
Thank you for your effort, jj2007.
I shall trying this feature. 😀