Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Comment on

( #3333=superdoc: print w/ replies, xml ) Need Help??

sanbiswa,

Since I was brought back into this and since for the moment I'll assume that management wouldn't help you, because they think it's cute to corrupt an Oracle database. Here's a non fool proof idea.

First, you have to nullify all existing copies of your code, good and bad, and then the good code must be read-only to all users (including you). If you need to update the script, then you have to delete it, and then copy a new version, and then make it read-only. You also have to change the way you call Oracle so that your old scripts don't work any more. (hint: change password, change Table name, etc.)

Now write your 'C' program to verify the exact Perl script by not allowing it to be a symbolic link and that MD5 or SHA1 is correct. What I suggest is to read the Perl script into memory and add 50+ characters of non-printable data to it and then verify the MD5/SHA1 of that. If it fails then abort. Obviously the 'C' program must know the valid MD5/SHA1 value, but you can split the MD5/SHA1 into parts and resemble in memory, plus make the 'C' executable at least 100K in size. Now have the C executable write the script to an unique location with a unique name and then have the C program execute your script from there.

It will help, but if someone is determined...

If the 'C' program works, then you can update you Perl scripts and distribute them to happy users. We can hope!

This may help you if your problem user(s) doesn't want to spend a few days figuring out what you have done, but if s/he's good and persistent...

Plan B..Z is find a better job with better management :-)

Good Luck!

"Well done is better than well said." - Benjamin Franklin


In reply to Re: How to ensure that a supported version of my script is being executed? by flexvault
in thread How to ensure that a supported version of my script is being executed? by sanbiswa

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • Outside of code tags, you may need to use entities for some characters:
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.
  • Log In?
    Username:
    Password:

    What's my password?
    Create A New User
    Chatterbox?
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others having an uproarious good time at the Monastery: (6)
    As of 2014-12-20 10:43 GMT
    Sections?
    Information?
    Find Nodes?
    Leftovers?
      Voting Booth?

      Is guessing a good strategy for surviving in the IT business?





      Results (95 votes), past polls