[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 206
  • Last Modified:

get harddisk serial or other characteristic info for copyprotection

hi !
i want to copyprotect my compiled perl program. is there a way to get the harddisk serial number or the mac address of the local machine ?

kind regards
ItsMe
0
ItsMe
Asked:
ItsMe
  • 5
  • 4
1 Solution
 
christopher sagayamCommented:
? ?
0
 
ahoffmannCommented:
foreach (`/sbin/ifconfig -a`) {m/^eth0\s+/ && do { @x=split(/\s+/,$_);$mac=$x[$#x]; };}
0
 
ItsMeAuthor Commented:
hi ahoffmann,
the code above didn't work. the script returns nothing and seems to hang.

kind regards
ItsMe
0
Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

 
ahoffmannCommented:
which OS?
0
 
ItsMeAuthor Commented:
2000
0
 
ahoffmannCommented:
2000, what's that? At least more than a year old, probably too ancient ... ;-)

foreach (`ipconfig -all`) {m/\s+Physical address\s+/ && do { @x=split(/\s+/,$_);$mac=$x[$#x]; };}
#
# PLease check spelling in the m// statement
# keep in mind that you may have more than one interface, then you need to skip the pseudo MACs
0
 
ItsMeAuthor Commented:
hi ahoffman,
do you think there is another way to copyprotect compiled perl scripts, which will work on all systems ? I'm thinkin on perl specific functions so that I don't need windows software (sure is sure :-)...

kind regards
ItsMe
0
 
ahoffmannCommented:
what do you want to achieve, just inhibit that people change the script, or that people view the script?

> i want to copyprotect my compiled perl program.
ok, how did you compile it?
Compilation is usualy done by perl.exe at startup.

Copyprotect? That's difficult with scripts, 'cause everyone who understands the code is able to modify it in that way that it matches his requirements and not yours, bypassing the copy-check.

Why do you realy insist on having the functinality implemented in perl (instead of c or c++ or any other compiled language)?
0
 
ItsMeAuthor Commented:
hi ahoffmann,
i'm compiling the script with perl2exe, i think that perl just interprets the script :-) once the script is an exe file you can no longer modify it. i'm working on a server solution and don't want anybody to use my files without permission.

kind regards
ItsMe
0
 
ahoffmannCommented:
so using ipconfig might be ok for newbies.
You also may use some values of the registry (AFAIK perl has a NT-Registry module).
0

Featured Post

Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

  • 5
  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now