Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

This is going to be long, so i apologize in advance for anyone who's bored by this. If you just want the question, skip to the end.


I work at a company that does 80% of it's coding in perl. I feel blessed because i know a lot of people who would kill for a programming job not involving VB or java. So the point of this is the fact that we're encouraged to do everything in perl if it's feasable. We are also encouraged to use CPAN whenever possible, since time is money, and with the way the economy is right now, no startup can afford to pay people to reinvent the wheel. My copmany makes transparent / explicit proxying software. The technology is super cool. When we do transparent proxying , we usually use a layer 4 switch to route all traffic destined to port 80 to our proxy, which handles everything from there. Our proxy usually listens on a different port than 80 though, so somehow the traffic must be forwared from one port to another. Originally (before I got there), this was done with squid. But squid is slow and big and ugly. So i proposed the use of ipchains instead (all of our machines run linux). I set up a proof of concept box to show that ipchains could handle 10x more connections than squid while using 1/10th of the system resources that squid would have. This is a good thing. Then it fell upon me to automate this process. Originally i wrote a module to grab configuration info from a config file, and construct the appropriate command line stuff for ipchains. Most importantly, I had this rule:
/sbin/ipchains -A input -s -d 80:80 -p6 -j REDIREC +T 3000
which redirects all traffic destined to port 80 to port 3000 instead. This made transparent proxying work. Unfortunately , the code to do this was pretty dirty. I searched CPAN and found, which gave OO methods to accomplish the same thing, and used SWIG to directly make the C calls, rather than running a shell. This was definitely cooler, so I started rewriting my module to use this interface instead.


Then i found a problem. The module didn't allow you to specify a port to redirect to if 'REDIRECT' was your action. This made redirection pointless, and prevented me from accomplishing what the above ipchains command did. So (like any good hacker), I went through the code, wrote an option in for what I wanted, and made it work (which could have never happened if i didn't have access to source code). Which brings me to my question.


I generated a patch for the module, and sent it off to the author. It's been a week, and I haven't heard anything back. The last time this code was updated was September 1999, which makes me think the author has no intentions of releasing a new version anytime soon. The code is GPL'd, so I could just release my own version with the patch, but somehow I feel like i'm going behind the author's back by doing so. So I guess what I'm asking is what do you do when you have bug fixes for code that's not being maintained anymore?


Disclaimer: This post may contain inaccurate information, be habit forming, cause atomic warfare between peaceful countries, speed up male pattern baldness, interfere with your cable reception, exile you from certain third world countries, ruin your marriage, and generally spoil your day. No batteries included, no strings attached, your mileage may vary.

In reply to What to do when a module is no longer being maintained by BlueLines

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

  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?

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

How do I use this?Last hourOther CB clients
Other Users?
Others examining the Monastery: (1)
As of 2024-04-15 21:54 GMT
Find Nodes?
    Voting Booth?

    No recent polls found