Printer Friendly Version Print this thread
Email this thread to a friend eMail this thread to a friend
Featured Web Site Template

Hundreds More at Free Site Templates.com!

Web Site Partners
Sponsored Links
Jet City Software
 
Whos Here ?
There are 0 guests and 1 members in the forums right now.
Reflects user activity within the last 5 minutes
Moderator(s): Prowler, jcokos
Member Message

mbhkewl
Joined: Aug 25, 2004
# Posts: 4

View the profile for mbhkewl Send mbhkewl a private message

Posted: 2004-Aug-25 13:54
Edit Message Delete Message Reply to this message

Hello!

I have a perl script that I wish to protect its source code ... the only "simple" way I could find is by using an encryption script (http://richard.fairthorne.is-a-geek.com/utils_obfuscate.php)

Now, I don't want to encode the whole script, I just put a simple IF statement and it should check what I need I encoded this statement with essential variables such that if the user deleted the encoded test, the script fails.

Unfortunately, perl fails to read that encoded segment :/

Here's the segment I need to encode ::

my($location, $other_headers)= @_ ;
if ($ENV{'HTTP_HOST'} ne "www.site.com"wink {
$location="http://place.org/";
}
print "$HTTP_1_X 302 Moved1512", $NO_CACHE_HEADERS,
"Date: ", &rfc1123_date($now,0), "1512",
$other_headers,
"Location: $location15121512" ;
goto EXIT ;


Any idea on how I should protect this segment?! Why the decode_base64() wouldn't return the function as it should?

Thanks in advance...



g1smd
Staff
Joined: Jul 28, 2002
# Posts: 10439

View the profile for g1smd Send g1smd a private message

Posted: 2004-Aug-28 09:22
Edit Message Delete Message Reply to this message

Why encrypt the source code? People visiting your site see the output of the script, not the script source code itself.





mbhkewl
Joined: Aug 25, 2004
# Posts: 4

View the profile for mbhkewl Send mbhkewl a private message

Posted: 2004-Aug-28 10:31
Edit Message Delete Message Reply to this message

I know ... the goal is protect the source code since I'll be selling the script .. sorry, I forgot to mention that in my first post :/

I want to lock the script to a certain server and disable the copy/paste issues so that people don't handout the script for free!



Prowler
Staff
Joined: Aug 14, 2000
# Posts: 1795

View the profile for Prowler Send Prowler a private message

Posted: 2004-Aug-30 16:07
Edit Message Delete Message Reply to this message

Obfuscation will not keep the determined Perl programmer away for long. It might make it a little convoluted which might stop only the script kiddies.

You could try giving the standard backslash n instead of the 1512 for starters.



mbhkewl
Joined: Aug 25, 2004
# Posts: 4

View the profile for mbhkewl Send mbhkewl a private message

Posted: 2004-Aug-30 23:36
Edit Message Delete Message Reply to this message

Could you be more specific, and if possible define an example since I'm not an expert in Perl (PHP freak)

Thanks for the hint.


You are not permitted to post messages in this forum or topic, because of one or more of the following reasons:
  1. You have not yet logged in, or registered properly as a member
  2. You are a member, but no longer have posting rights.
  3. This is a private forum, for which you do not have permissions.

If you are a recent member, it's possible that you simply have not yet confirmed your account. Please check your email for a message entitled 'JimWorld Forums: Confirm Your Account' and follow the instructions contained within.

If you cannot find this message, click here to Re-Send it.

If you are still experiencing problem, please read the Login Assistance Article for some advice on what may be causing your login not to work properly.

Switch to Advanced Editor and ... Create a New Topic or Reply to this Thread

New posts Forum is locked
© 1995  ·  iWeb, Inc  ·  DBA JimWorld Productions