The MASM Forum Archive 2004 to 2012

General Forums => The Campus => Topic started by: David on January 15, 2010, 09:43:20 PM

Title: Program Registration Verification & Storing Settings- Need some methods.
Post by: David on January 15, 2010, 09:43:20 PM
1.  Hi guys, so I made a program and I want to add some more protection to it so that I can ban people from it if I catch them spamming the chat program.  However, my computer cannot be on all day, and I am not paying for virtual server hosting.  So I need a method of verification.  Back when I programmed in C++, I would write their computer name on my website.  My C++ program would download the file (URLDownloadToFile) and read it line by line, if it found its name, then it let the person use the program... if it did not find their computer name, the program would close.  I cannot do this method in C++ program, because I want to add a more secure method of protection.  (I am using Yodas Crypter to pack my application). 

So what is a good method to use?  I am not sure how to read a file line by line.

2.  Where do you store your application settings?  In the registry or in an ini file?  I am not sure which method to use.  Writing to the registry requires UAC, and I don't want to add a manifest, for XP users... so how can I prompt my program to request UAC access?  Which method?

Title: Re: Program Registration Verification & Storing Settings- Need some methods.
Post by: jj2007 on January 15, 2010, 10:54:47 PM
Quote from: David on January 15, 2010, 09:43:20 PM
I am not sure how to read a file line by line.

Check MasmBasic's Recall (http://www.masm32.com/board/index.php?topic=12460):

Quote
   Recall "\masm32\include\winextra.inc", MyRec$()
   mov lc, Min(eax, 20)
   Print Str$("%i lines found", lc)
   For_ n=0 To lc-1
      Print Str$("\nRec %i\t", n)
      Print Left$(MyRec$(n), 50)
   Next
Rem[/color]   returns lines in eax (null if an error occurred), and the number of total bytes read in edx
Title: Re: Program Registration Verification & Storing Settings- Need some methods.
Post by: ecube on January 16, 2010, 01:58:29 AM
file streams is a good way to save things, as it's still pretty unknown, especially for the average user, and you need special programs to find em and read em.You can keep your settings encrypted inside the stream too, as far as yoda's crypter.. that things pretty much useless depending on which 1 your using. The ASM one for sure, the C++ 1 is abit better.