Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask

Re: scramble ad link

by TedPride (Priest)
on Jul 02, 2006 at 08:10 UTC ( #558838=note: print w/replies, xml ) Need Help??

in reply to scramble ad link

This is more an obfuscation problem than anything else. Sure, there are millions of ways to encrypt the link, but anyone with half a brain will still be able to figure out where it is in the code, even with little or no programming experience. What you need to do is add a verification routine entirely separate from the link print (and preferably hidden somewhere they aren't likely to look) that loads the script, computes a hash of its size and/or contents, and checks it against an internal hash to make sure the script hasn't been modified. Then if they remove your link, the script errors out, and most people won't be smart enough to figure out why.

Replies are listed 'Best First'.
Re^2: scramble ad link
by GrandFather (Sage) on Jul 02, 2006 at 09:43 UTC

    Note Re: $. - smarter than you might think which describes using <DATA> to access the source of the script. That's a neat way to get the source actually being executed and if there is any excuse (like configuration parameters for example) to have a __DATA__ section then much of the code pertaining to the tests can vanish from sight as being relevant to checking configuration.

    The code protection could be made rather strong by requiring a key (some of the source) to decode important parts of the code that then get executed using eval.

    DWIM is Perl's answer to Gödel

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://558838]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (6)
As of 2017-07-20 18:05 GMT
Find Nodes?
    Voting Booth?
    I came, I saw, I ...

    Results (311 votes). Check out past polls.