It is my understanding that the GPL and Artistic licences apply to
copying and distributing the "program". I am free to modify perl
(or any other module or such licenced software) and 'use' it as I
wish (whether I'm an individual or a company). If that means I create
a web application based on those modified programs and run it on my
server (perhaps charging a fee for usage), I am not required to
release source --- because I am not "distributing" the product,
merely providing a service (or, as chromatic says: I would only be
providing output from a GPL'd program). Once I decide to sell, or
give away, or otherwise *distribute* the application itself, then I am
bound by the terms of the GPL or Artistic licence (which are
different in what they actually allow me to do).
If you coded programs for "the company", the company (probably) owns
those programs. They do not own any of the original open source code
that your products were based on (or that your products used) and
they cannot restrict your future use of such code (probably stating
the obvious here). But, they do own your new code, and any
modifications you made to the original code while in their employment.
(Note: this interpretation is based on assuming relatively standard
employment agreements you likely signed when you were hired). So,
yes, they can restrict you from using code you wrote for them (which
isn't really yours) to make new products.
Should you decide to "independently" recreate their modified software
you may still have legal problems --- convincing a court that you
recreated it independently of your work for the company may prove
difficult at best (hard to claim 'clean room' status since you were
intimately involved with their project).