[16376] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 3788 Volume: 9

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Mon Jul 24 18:10:40 2000

Date: Mon, 24 Jul 2000 15:10:24 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <964476624-v9-i3788@ruby.oce.orst.edu>
Content-Type: text

Perl-Users Digest           Mon, 24 Jul 2000     Volume: 9 Number: 3788

Today's topics:
        NetBIOS/nbname ??? <Terrill@Bennett.org>
    Re: NetBIOS/nbname ??? <coy@coystoys.com>
    Re: NetBIOS/nbname ??? <godzilla@stomp.stomp.tokyo>
    Re: NetBIOS/nbname ??? <mcnuttj@nin.iats.missouri.edu>
    Re: Newbie "Learning Perl"  help <animalx1@home.com>
    Re: Pattern Matching HTML <robertNOroSPAM@kronos.custard.org.invalid>
    Re: Pattern Matching HTML (Abigail)
        PERL -w BUG!? (was: HELP: longSyntax ok, but: rHsh->{my (David Combs)
    Re: PERL -w BUG!? (was: HELP: longSyntax ok, but: rHsh- <uri@sysarch.com>
        perl as part of unix distribution dgallardo@my-deja.com
    Re: perl as part of unix distribution schnurmann@my-deja.com
    Re: perl as part of unix distribution (NP)
    Re: perl as part of unix distribution <russ_jones@rac.ray.com>
    Re: perl as part of unix distribution (Lupe Christoph)
    Re: perl as part of unix distribution dgallardo@my-deja.com
    Re: perly.y (Mark-Jason Dominus)
        Post Form AND redirect zagar@my-deja.com
    Re: Post Form AND redirect <noemail@noemail.com>
        problem with Perl Section <gabriel.ibanez@corp.terra.cl>
        Question about redirecting output in perl on NT sbhide@my-deja.com
    Re: READING hashes eats memory!? <mjcarman@home.com>
        regexp help (George Cyriac {EME SEAP})
    Re: regexp help (Mads Orbesen Troest)
    Re: searching multiple sites - <dan@tuatha.sidhe.org>
    Re: Simple Reg Expression Question <Chris.Durbin@motorola.com>
        Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: Mon, 24 Jul 2000 16:26:25 -0400
From: "Terrill_b" <Terrill@Bennett.org>
Subject: NetBIOS/nbname ???
Message-Id: <e52Zw1a9$GA.435@cpmsnbbsa08>

Inquiring minds want to know...

At places like:

   http://grc.com

Steve Gibson gets your name from your computer. I suspect he's using
something like nbname in NetBIOS.

Been trying now for several months (not non-stop, of course <g>) to figure
this out.

UNCLE!

Someone know how it's done in Perl???

tb





------------------------------

Date: Mon, 24 Jul 2000 21:21:42 GMT
From: "Coy" <coy@coystoys.com>
Subject: Re: NetBIOS/nbname ???
Message-Id: <Gr2f5.9258$Mt.102222@nnrp1.ptd.net>

well, if he's on a windows machine,

$REMOTE_ADDR = $ENV('REMOTE_ADDR');

print system('nbtstat -A $REMOTE_ADDR');


something like that.

but in a unix environment, or raw socket operation,
I have no idea how to unpack the binary that MS
produces at port 139 though. sorry :(

But, its a good thing to know, and it looks like I have yet
another project to add to my list of things to find out.

Good luck

 - Coy

"Terrill_b" <Terrill@Bennett.org> wrote in message news:e52Zw1a9$GA.435@cpmsnbbsa08...
: Inquiring minds want to know...
:
: At places like:
:
:    http://grc.com
:
: Steve Gibson gets your name from your computer. I suspect he's using
: something like nbname in NetBIOS.
:
: Been trying now for several months (not non-stop, of course <g>) to figure
: this out.
:
: UNCLE!
:
: Someone know how it's done in Perl???
:
: tb
:
:
:




------------------------------

Date: Mon, 24 Jul 2000 14:42:47 -0700
From: "Godzilla!" <godzilla@stomp.stomp.tokyo>
Subject: Re: NetBIOS/nbname ???
Message-Id: <397CB857.4E884DC1@stomp.stomp.tokyo>

Terrill_b wrote:

> At places like:
 
>    http://grc.com
 
> Steve Gibson gets your name from your computer. I suspect he's using
> something like nbname in NetBIOS.
 
> Been trying now for several months (not non-stop, of course <g>)
> to figure this out.

> Someone know how it's done in Perl???


Simple port scanner and a few tricks to communicate with
Windows web server and Windows telnet application.

Why bother writing this in Perl? Programs like this are
available by the dozens, some free, some shareware and
some commercial programs.

Why bother at all? A person with a bit of imagination
can deal with security quite effectively. I am running
no special software, no Guard Dog, no Black Ice, nada.
Famous GRC cannot touch a system like mine:


Port Service   Status    Security Implications

21     FTP    Stealth!   There is NO EVIDENCE WHATSOEVER that
                         a port (or even any computer) exists
                         at this IP address!

23   Telnet   Stealth!   There is NO EVIDENCE WHATSOEVER that
                         a port (or even any computer) exists
                         at this IP address!

25    SMTP    Stealth!   There is NO EVIDENCE WHATSOEVER that
                         a port (or even any computer) exists
                         at this IP address!

79   Finger   Stealth!   There is NO EVIDENCE WHATSOEVER that
                         a port (or even any computer) exists
                         at this IP address!

80    HTTP    Stealth!   There is NO EVIDENCE WHATSOEVER that
                         a port (or even any computer) exists
                         at this IP address!

110   POP3    Stealth!   There is NO EVIDENCE WHATSOEVER that
                         a port (or even any computer) exists
                         at this IP address!

113  IDENT    Closed     Your computer has responded that this 
                         port exists but is currently closed to 
                         connections.

139  NetBIOS  Stealth!   There is NO EVIDENCE WHATSOEVER that
                         a port (or even any computer) exists
                         at this IP address!

143  IMAP     Stealth!   There is NO EVIDENCE WHATSOEVER that
                         a port (or even any computer) exists
                         at this IP address!

443  HTTPS    Stealth!   There is NO EVIDENCE WHATSOEVER that
                         a port (or even any computer) exists
                         at this IP address!


However, I can get into your computer,
at whim and will and, do many things
which would shock you. Just a matter
of know how. This is very safe, very
gentle and there is no way to prevent
this from happening:

print "file:///%43|%2f";

Doesn't work for MAC / Apple and some
Linux systems. Those are not computers
but rather fancy Etch-A-Sketch toys.


Godzilla!

--
I will rock you.
http://la.znet.com/~callgirl3/bornwild.mid


------------------------------

Date: 24 Jul 2000 21:33:34 GMT
From: Justin McNutt <mcnuttj@nin.iats.missouri.edu>
Subject: Re: NetBIOS/nbname ???
Message-Id: <8licne$8h9$1@dipsy.missouri.edu>

Coy <coy@coystoys.com> wrote:
> well, if he's on a windows machine,

> $REMOTE_ADDR = $ENV('REMOTE_ADDR');

> print system('nbtstat -A $REMOTE_ADDR');

If you're on a unix machine with samba installed,

print system('nmblookup -A $REMOTE_ADDR');

nmblookup performs similar functions to nbtstat.

--J


------------------------------

Date: Mon, 24 Jul 2000 20:18:02 GMT
From: "Elbert Rush" <animalx1@home.com>
Subject: Re: Newbie "Learning Perl"  help
Message-Id: <_v1f5.49261$fR2.450607@news1.rdc1.mi.home.com>

Thanks a million.  I knew I was trying everything but just couldn't seem to
make this work.  It was starting to make me a little irritable.  Maybe I can
get past chpt. 3 now!!
"Eric Bohlman" <ebohlman@netcom.com> wrote in message
news:8lh78c$agm$9@slb3.atl.mindspring.net...
> The Unknown (unknown-one@home.com) wrote:
> : Am using ActivePerl 5.22 and Windows 98 SE.
> :
> : I must be missing something because I don't understand why this:
> :
> : print "Type strings here:\n";
> : @a = <STDIN>;     # here I just typed "one two three"
> : print @a;                 # I also remembered to use
> :                                # CTRL-Z to indicate the eof
> :
> : gives this:
> :
> : two
> : three
> :
> : instead of this:
> :
> : one
> : two
> : three
>
> There's a bug in the Win95 and Win98 console output routines (part of the
> OS, not part of perl) that causes the first line output after you enter a
> Ctrl+Z to disappear under some circumstances.  It looks like you're being
> bitten by it.  Simply printing a blank line after doing anything that
> reads STDIN to the end will usually fix it.
>




------------------------------

Date: Mon, 24 Jul 2000 11:17:04 -0700
From: Robert <robertNOroSPAM@kronos.custard.org.invalid>
Subject: Re: Pattern Matching HTML
Message-Id: <000a3290.4bab30da@usw-ex0101-008.remarq.com>

> Well, your $html contains regex metacharacter, so it's
> unlikely to work.

I'm not entirely sure what you mean here. Are you referring to
the quotes and question marks? If so, would it simply be a matter
of adding a "\" in front of these to cancel their significance?

> Furthermore, <NEWS> suggests you are line by line.
> $html contains several newlines. Unlikely to ever match.

Yes of course! I hadn't considered that. Is there a way of
looking through the HTML file as one big lump, rather than line
by line?

Thanks for your help,

Rob.


-----------------------------------------------------------

Got questions?  Get answers over the phone at Keen.com.
Up to 100 minutes free!
http://www.keen.com



------------------------------

Date: 24 Jul 2000 14:36:53 EDT
From: abigail@foad.org (Abigail)
Subject: Re: Pattern Matching HTML
Message-Id: <slrn8np360.vcg.abigail@alexandra.foad.org>

Robert (robertNOroSPAM@kronos.custard.org.invalid) wrote on MMDXIX
September MCMXCIII in <URL:news:000a3290.4bab30da@usw-ex0101-008.remarq.com>:
{} > Well, your $html contains regex metacharacter, so it's
{} > unlikely to work.
{} 
{} I'm not entirely sure what you mean here. Are you referring to
{} the quotes and question marks? If so, would it simply be a matter

Quotes are not special in regexes. The man page can tell you which
characters are special.

{} of adding a "\" in front of these to cancel their significance?

Yes. Or use quotemeta.

{} > Furthermore, <NEWS> suggests you are line by line.
{} > $html contains several newlines. Unlikely to ever match.
{} 
{} Yes of course! I hadn't considered that. Is there a way of
{} looking through the HTML file as one big lump, rather than line
{} by line?

Yes. Just read in the file.


Abigail
-- 
 :;$:=~s:
-:;another Perl Hacker
 :;chop
$:;$:=~y
 :;::d;print+Just.
$:;


------------------------------

Date: 24 Jul 2000 18:24:04 GMT
From: dkcombs@netcom.com (David Combs)
Subject: PERL -w BUG!? (was: HELP: longSyntax ok, but: rHsh->{myKey} UNDEFINED??):
Message-Id: <8li1k4$hmo$1@slb1.atl.mindspring.net>

In article <qBVe5.14$DT4.1328911@nnrp2.clara.net>,
Colin Keith <ckeith@clara.net> wrote:
>In article <8lg72l$p3h$1@slb0.atl.mindspring.net>, dkcombs@netcom.com (David Combs) wrote:
>[working]
>>         dQuoteIt(%{$recordHashRef}->{"curLine"}),   "\n");
>[notworking]
>> dQuoteIt($recordHashRef->{curline}), "\n");
>
>Well I guess it could be a copying error, but this uses curline (lowercase 

No, NOT a copying-error.  Is the EXACT code.

The SERIOUS BUG (?) is that I use -w, and perl DIDN'T
   COMPLAIN about the undefined misspelled-curline (lower-case "l").


My *Occur* buffer (I have matching via no-case):
13 lines matching "curline" in buffer test4-19jul00.pl.
  195:##    curLine =>  $curLine;
  255:   if (! defined($recordHashRef->{curLine})) {
  256:     print(STDERR "OOPS!!: ERROR!!: ! defined(\$recordHashRef->{curLine});  thus I do a NEXT!\n");
  262:   print(STDERR $indentStr, "[$i]: WORKS OK!!!: NOW, TRY FOR x=>{curLine}: ", 
  263:	 dQuoteIt(%{$recordHashRef}->{"curLine"}),   "\n");
  266:   print(STDERR $indentStr, "[$i]: FAILS!!!: ", dQuoteIt($recordHashRef->{curline}), "\n");
                                                                                ^^^^^^^
  297:		       curLine =>  "the curLine1",
  311:		       curLine =>  "the curLine2",
  360:my $curLine = "";
  433:  my $sTemp = $curLine = $linesAry5[$i];
  445:    "   \$linesAry5[$i]: $curLine\n");
  523:      printStringAry("   METHOD-3: via SPLIT of \$curLine=$curLine\" INTO @tempAry",   \@tempAry, "tempAry", 0, 3);
  544:		       curLine =>  $curLine,


Again, here is that quoteIt sub:


sub dQuoteIt($) {
  my $arg1 = shift;
  print(STDERR "ERROR!!: in dQuoteit(), \$arg1=shift IS UNDEFINED!!!\n") 
    if ! defined($arg1);
  "\"$arg1\"";       #ie, return("\"$arg1\"");
}


------- Again, this next I just (now) "lifted" straight out of emacs:



---------------------------------------------------- the run:

858 ====> !!
perl -w test4-19jul00.pl


-------------------- ENTER testPrintWRAINrecordsAry():

<SNIP>

[0]: at G5
[0]: at H
[0]: WORKS OK!!!: NOW, TRY FOR x=>{curLine}: "the curLine1"
ERROR!!: in dQuoteit(), $arg1=shift IS UNDEFINED!!!
Use of uninitialized value in concatenation (.) at test4-19jul00.pl line 73.

[0]: FAILS!!!: ""
[0]: at I

---------------------------------------------------- and that code again:



#!/usr/local/bin/perl  -w  ~dkc/test4-19jul00.pl
use strict;   
#use diagnostics;
$^W = 1;

<SNIP>

   print(STDERR "[$i]: at G5\n");
   if (! defined($recordHashRef->{curLine})) {
     print(STDERR "OOPS!!: ERROR!!: ! defined(\$recordHashRef->{curLine});  thus I do a NEXT!\n");
     next; }

   print(STDERR "[$i]: at H\n");

   # NEXT LINE WORKS OK!!
   print(STDERR $indentStr, "[$i]: WORKS OK!!!: NOW, TRY FOR x=>{curLine}: ", 
	 dQuoteIt(%{$recordHashRef}->{"curLine"}),   "\n");

   # BUT NOT THIS ONE!!!!!: "Use of uninitialized value in print at test4-19jul00.pl line 261.":
------ HERE IS THE "curLine" that I MISSPELLED "curline":
------ HERE IS THE "curLine" that I MISSPELLED "curline":
------ HERE IS THE "curLine" that I MISSPELLED "curline":
   print(STDERR $indentStr, "[$i]: FAILS!!!: ", dQuoteIt($recordHashRef->{curline}), "\n");
   print(STDERR "[$i]: at I\n");


------ QUESTION: why did the -w (and use strict) NOT CATCH this?????



================= Anyway, here's what I did two minutes ago:





So, I backed up the (MY bug + (maybe) PERL -w bug) program:
   879	cp -p test4-19jul00.pl test4-19jul00--misspelled-curline-not-caught-bug.pl

Fixed the MISSPELLING-bug that only a HUMAN (NOT -w!!!) could see:
   print(STDERR $indentStr, "[$i]: FAILS!!!: ", dQuoteIt($recordHashRef->{curLine}), "\n");

000000 And reran:
879 ====> 
879 ====> 
879 ====> cp -p test4-19jul00.pl test4-19jul00--misspelled-curline-not-caught-bug.pl
880 ====> !perl
perl -w test4-19jul00.pl


-------------------- ENTER testPrintWRAINrecordsAry():

<SNIP>

[0]: at H
[0]: WORKS OK!!!: NOW, TRY FOR x=>{curLine}: "the curLine1"
[0]: FAILS!!!: "the curLine1"
[0]: at I


--- so now I have to add an "if" to that FAILS print.  :-)


THANKS SO MUCH FOR FINDING THAT MISSPELLING?

What do I have to do now?  Write a program to check each "my" decl
and look for misspelled (via case) occurrences -- since it looks 
like I can't trust -w!!!!   :-((((((

David


------------------------------

Date: Mon, 24 Jul 2000 18:53:29 GMT
From: Uri Guttman <uri@sysarch.com>
Subject: Re: PERL -w BUG!? (was: HELP: longSyntax ok, but: rHsh->{myKey} UNDEFINED??):
Message-Id: <x7g0oz9x7d.fsf@home.sysarch.com>

>>>>> "DC" == David Combs <dkcombs@netcom.com> writes:

  DC> The SERIOUS BUG (?) is that I use -w, and perl DIDN'T
  DC>    COMPLAIN about the undefined misspelled-curline (lower-case "l").

it is not a perl bug, but yours.

  DC>   255:   if (! defined($recordHashRef->{curLine})) {
  DC>   266:   print(STDERR $indentStr, "[$i]: FAILS!!!: ", dQuoteIt($recordHashRef->{curline}), "\n");

those 2 are hash keys and perl doesn't know or check their spelling. how
could it? and -w doesn't deal with variable declarations, use strict
does. if you had used the value of a hash with a misspelled key, _w
would most likely tell you that. unless you were doing something like ++
which bypasses that warning.

changing from stupid studly caps to underlines and all lower case will
make your life much easier. 

and improving your formatting and code structure will help too. i found
your stuff to be highly unreadable and therefore much harder to debug so
i didn't even try to find the spelling mistake. others had better eyes
and did.

uri

-- 
Uri Guttman  ---------  uri@sysarch.com  ----------  http://www.sysarch.com
SYStems ARCHitecture, Software Engineering, Perl, Internet, UNIX Consulting
The Perl Books Page  -----------  http://www.sysarch.com/cgi-bin/perl_books
The Best Search Engine on the Net  ----------  http://www.northernlight.com


------------------------------

Date: Mon, 24 Jul 2000 18:35:49 GMT
From: dgallardo@my-deja.com
Subject: perl as part of unix distribution
Message-Id: <8li2a5$2tk$1@nnrp1.deja.com>

Sorry if this is off topic or inflammatory.

Is perl part of any standard unix distribution?  Are there any moves in
this direction.

I like to use perl in shell scripts for program installation and
maintenance but my sysadmin will not allow perl on production systems.
I hate to think that I'll have to rewrite the perl bits in sed or awk.

Do other folks have similarly recalcitrant sysadmins?  (I mean with
regards to perl.  I know they're paid to be hardasses.)


Sent via Deja.com http://www.deja.com/
Before you buy.


------------------------------

Date: Mon, 24 Jul 2000 18:44:54 GMT
From: schnurmann@my-deja.com
Subject: Re: perl as part of unix distribution
Message-Id: <8li2r6$3ak$1@nnrp1.deja.com>

Tell your sysadmin they are a bigot.  I used to run Perl scripts via
crontab all the time.

In article <8li2a5$2tk$1@nnrp1.deja.com>,
  dgallardo@my-deja.com wrote:
> Sorry if this is off topic or inflammatory.
>
> Is perl part of any standard unix distribution?  Are there any moves
in
> this direction.
>
> I like to use perl in shell scripts for program installation and
> maintenance but my sysadmin will not allow perl on production systems.
> I hate to think that I'll have to rewrite the perl bits in sed or awk.
>
> Do other folks have similarly recalcitrant sysadmins?  (I mean with
> regards to perl.  I know they're paid to be hardasses.)
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
>


Sent via Deja.com http://www.deja.com/
Before you buy.


------------------------------

Date: Mon, 24 Jul 2000 19:46:34 GMT
From: nvp@spamnothanks.speakeasy.org (NP)
Subject: Re: perl as part of unix distribution
Message-Id: <u21f5.460454$VR.5807509@news5.giganews.com>

24 Jul 2000 18:35:49 GMT, dgallardo@my-deja.com <dgallardo@my-deja.com> wrote:
: 
: Is perl part of any standard unix distribution?  Are there any moves in
: this direction.

There are many Unix-like distributions that ship with some variant of
Perl.  (Net|Free|Open)BSD, Linux, Solaris 8, etc..

: I like to use perl in shell scripts for program installation and
: maintenance but my sysadmin will not allow perl on production systems.

Your sysadmin is nuts.  Unless he has a Really Good Reason not to put
Perl on a production server, then I'd be very interested to hear what
the person has to say.  :-)

: Do other folks have similarly recalcitrant sysadmins?  (I mean with
: regards to perl.  I know they're paid to be hardasses.)

I don't get paid to be a hardass.  They won't even let me near a bikini. :-)

-- 
Nate II



------------------------------

Date: Mon, 24 Jul 2000 15:34:18 -0500
From: Russ Jones <russ_jones@rac.ray.com>
Subject: Re: perl as part of unix distribution
Message-Id: <397CA84A.E8978DD1@rac.ray.com>

dgallardo@my-deja.com wrote:
> 
> Sorry if this is off topic or inflammatory.
> 
> Is perl part of any standard unix distribution?  Are there any moves in
> this direction.
>

Perl is an optional component of HP-UX, and it's required to run a
number of HP products, and a number of third party products that run
on HP.

> I like to use perl in shell scripts for program installation and
> maintenance but my sysadmin will not allow perl on production systems.
> I hate to think that I'll have to rewrite the perl bits in sed or awk.
> 
> Do other folks have similarly recalcitrant sysadmins?  (I mean with
> regards to perl.  I know they're paid to be hardasses.)
> 

An argument can be made for not putting any free or shareware
software, including Perl, on a mission-critical system (I'm just
reporting the argument, I have Perl on lots of production systems and
in lots of production jobs.)

But here it is: If Perl blows up for some reason and brings your
multi-billion dollar business down, or causes an cruise missile you
made to fall out of the sky onto a childrens' hospital, or something
else really bad like that, who do hold responsible? It's something
that your stockholders and auditors and lawyers have a right to ask,
because if you lose a few million bucks, or kill someone with this
software, you're going to have to answer for it to your stockholders,
or the survivors. Who can you sue for loss of business, or to offset
the lawsuits that you're going to get hammered with, or whatever.
Since you didn't pay for the software and don't have any kind of
guarantee of usability, you're stuck.

I think that while most of us aren't auditors or lawyers, we can agree
that Perl is (probably) safe for (most) mission-critical tasks, but
what about the Name On Request Free Computer Language (tm) that some
guy in your shop wants to run? Should your company run that one on
production, too? If he only wants to use it to maintain some other
software, it probably won't hurt you to bad if it dies, but what if he
wants to use it to write a finite element analysis program that's
going to be used to build a bridge?

I've thought about this a lot in the past. I've written software
before that, if it failed, people could die (although not in Perl).
Common sense should be your guide, but common sense isn't nearly as
common as its name would suggest.


-- 
Russ Jones - HP OpenView IT/Operatons support
Raytheon Aircraft Company, Wichita KS
russ_jones@rac.ray.com 316-676-0747

Quae narravi, nullo modo negabo. - Catullus


------------------------------

Date: 24 Jul 2000 22:02:55 +0200
From: lupe@alanya.lupe-christoph.de (Lupe Christoph)
Subject: Re: perl as part of unix distribution
Message-Id: <8li7df$q5t$1@alanya.lupe-christoph.de>

dgallardo@my-deja.com writes:

>Sorry if this is off topic or inflammatory.

>Is perl part of any standard unix distribution?  Are there any moves in
>this direction.

perl 5.005_03 is included with Solaris 8 (first time to have perl
on board). It's not on the freeware CD, but on one of the OS CDs.

>I like to use perl in shell scripts for program installation and
>maintenance but my sysadmin will not allow perl on production systems.
>I hate to think that I'll have to rewrite the perl bits in sed or awk.

I once wrote something in Perl some poor other guy had to rewrite
in ksh.

Perl is a language for sysadmins. So if he is against Perl,
tell him go play with his Visual Basic ;-) or maybe his JCL.

>Do other folks have similarly recalcitrant sysadmins?  (I mean with
>regards to perl.  I know they're paid to be hardasses.)

Only customers were management insisted on suiability. I mean they
wanted somebody they could sue ...
-- 
| lupe@lupe-christoph.de       |        http://free.prohosting.com/~lupe |
| "jryy vg ybbxf yvxr gur l2x oht qvqa'g erne vg'f htyl urnq." "lrc. gur |
| qbbzfnlref unir orra cebira jebat lrg ntnva."  ....  "qvq lbh frr gung |
| gbb?" "ubhfgba. jr unir n ceboyrz."           User Friendly 2000-01-01 |


------------------------------

Date: Mon, 24 Jul 2000 21:30:04 GMT
From: dgallardo@my-deja.com
Subject: Re: perl as part of unix distribution
Message-Id: <8licgm$arm$1@nnrp1.deja.com>

Solaris 8 ships with perl?  We're using Solaris 7, which does not...


In article <u21f5.460454$VR.5807509@news5.giganews.com>,
  nitty28@excite.com wrote:
> 24 Jul 2000 18:35:49 GMT, dgallardo@my-deja.com
<dgallardo@my-deja.com> wrote:
> :
> : Is perl part of any standard unix distribution?  Are there any moves
in
> : this direction.
>
> There are many Unix-like distributions that ship with some variant of
> Perl.  (Net|Free|Open)BSD, Linux, Solaris 8, etc..
>
> : I like to use perl in shell scripts for program installation and
> : maintenance but my sysadmin will not allow perl on production
systems.
>
> Your sysadmin is nuts.  Unless he has a Really Good Reason not to put
> Perl on a production server, then I'd be very interested to hear what
> the person has to say.  :-)
>
> : Do other folks have similarly recalcitrant sysadmins?  (I mean with
> : regards to perl.  I know they're paid to be hardasses.)
>
> I don't get paid to be a hardass.  They won't even let me near a
bikini. :-)
>
> --
> Nate II
>
>


Sent via Deja.com http://www.deja.com/
Before you buy.


------------------------------

Date: Mon, 24 Jul 2000 18:20:37 GMT
From: mjd@plover.com (Mark-Jason Dominus)
Subject: Re: perly.y
Message-Id: <397c88f4.4585$270@news.op.net>

In article <8lhukr$vvc$1@nnrp1.deja.com>,  <jdimov@cis.clarion.edu> wrote:
>So...  How do I get this little beast to actually perform lexical
>analysis on something and spit out parsed code?

I'd suggest

        perl -Dx program.pl

But without knowing what you are trying to accomplish, it's really
hard to understandyour question.



------------------------------

Date: Mon, 24 Jul 2000 20:05:48 GMT
From: zagar@my-deja.com
Subject: Post Form AND redirect
Message-Id: <8li7ip$6us$1@nnrp1.deja.com>

I know how to redirect to another page/CGI... I also know how to
recieve a form and parse through it...

What I'm trying to do is combine the two, to redirect to another page,
and the redirect CONTAINS a form that I have generated completely with
Perl.

Does anyone know how to do this???

Thanks!
Scott


Sent via Deja.com http://www.deja.com/
Before you buy.


------------------------------

Date: Mon, 24 Jul 2000 16:33:52 -0400
From: Young <noemail@noemail.com>
Subject: Re: Post Form AND redirect
Message-Id: <397CA830.4E3B135E@noemail.com>

Can't you just redirect to the Perl script that generates the form? Or am
I misunderstanding what you want to do?

zagar@my-deja.com wrote:

> I know how to redirect to another page/CGI... I also know how to
> recieve a form and parse through it...
>
> What I'm trying to do is combine the two, to redirect to another page,
> and the redirect CONTAINS a form that I have generated completely with
> Perl.
>
> Does anyone know how to do this???
>
> Thanks!
> Scott
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.



------------------------------

Date: Mon, 24 Jul 2000 16:18:28 -0400
From: Gabriel =?iso-8859-1?Q?Ib=E1=F1ez?= <gabriel.ibanez@corp.terra.cl>
Subject: problem with Perl Section
Message-Id: <397CA494.DFAB1D8F@corp.terra.cl>

This is a multi-part message in MIME format.
--------------CF3DC1987CA13F5C17502594
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8bit


Hi there,

I have a problem with an Apache server (1.3.12) and Perl Sections.
Apache doesnt accept any cgi-bin directory built with Perl Section
but it does accept any Virtual Host. I cant guess its a problem about
hash size because it knows everything about any virtual host. My problem
is just with cgi-bin directories.

In order to skip this problem I added this line:

     AddHandler cgi-script .cgi .pl

Obviously, Apache dont believe any ScriptAlias line (with PerlSection)
is a valid path or command.

Do someone have this problem before? Or can someone help me to solve it?
Thanks in advance.
-- 
Regards,Saludos,
--

   Gabriel Ibáñez C.           |   mailto: Gabriel.Ibanez@corp.terra.cl
--------------CF3DC1987CA13F5C17502594
Content-Type: text/x-vcard; charset=us-ascii;
 name="gabriel.ibanez.vcf"
Content-Transfer-Encoding: 7bit
Content-Description: Card for Gabriel Ibáñez
Content-Disposition: attachment;
 filename="gabriel.ibanez.vcf"

begin:vcard 
n:Ibáñez;Gabriel
x-mozilla-html:FALSE
adr:;;;;;;
version:2.1
email;internet:Gabriel.Ibanez@corp.terra.cl
fn:Gabriel Ibáñez
end:vcard

--------------CF3DC1987CA13F5C17502594--



------------------------------

Date: Mon, 24 Jul 2000 21:54:33 GMT
From: sbhide@my-deja.com
Subject: Question about redirecting output in perl on NT
Message-Id: <8lidun$bt3$1@nnrp1.deja.com>

Hi,

	I have this strange problem on NT 4.0.

I have a simple script given below:
----
print "Hello World!\n";
---

when I installed perl on my machine I allowed the installer to
associate .pl scripts with perl program so that i can just
say "test.pl" on a command window and it executes the script. however
this has a side effect and that is when I redirect the output onto a
file, it is created without any contents now.

i.e.

C:\temp> test.pl > t
	->> here t is empty after the command

however, if i run it explicitly as perl -w test.pl > t
	->> the t file has "Hello World!" in it.

what is going on here?


thanks,
suraj


Sent via Deja.com http://www.deja.com/
Before you buy.


------------------------------

Date: Mon, 24 Jul 2000 15:36:32 -0500
From: Michael Carman <mjcarman@home.com>
Subject: Re: READING hashes eats memory!?
Message-Id: <397CA8D0.4C0F9E8C@home.com>

Ken Barr wrote:
> 
> The %cell HoHoH is created before I start to read it as are the %src
> and %dst ones, but I think you are close to the answer...  
> The way the memory usage increases on each iteration makes it seem 
> like the entire hash is getting duplicated somewhere on each read?

Do all the keys match? i.e. are the keys to %src the same as the first
level keys to %cell? Another symptom of autovivification would be lots
of warnings about the use of uninitialized variables. 

You are running your script with -w, aren't you? :)

> Any idea how to prevent that?

Make sure that you have both 'use strict' and -w. If neither of those
point at anything, I'd suggest getting familiar with the debugger.

> The "my" scoping didn't help :(

No, it wouldn't really. It just lexically scopes the scalar vars used
only in the loop, and was included more out of habit than anything else.

-mjc


------------------------------

Date: 24 Jul 2000 19:16:53 GMT
From: cyriac@usna.navy.mil (George Cyriac {EME SEAP})
Subject: regexp help
Message-Id: <8li4n5$jql$8@news.usna.navy.mil>
Keywords: regexp

I am trying to change newline characters from a textarea to HTML breaklines so I can display it on a webpage correctly.  I have tried this but it won't work $from{'description'} =~ /\\n/<br>/;
It normally shows new line characters as spaces when I just print out it plainly to an HTML page.
I know this is really dumb, but please help me: (preferably by email);
TIA






------------------------------

Date: Mon, 24 Jul 2000 20:15:18 GMT
From: mads@troest.NEVERMORE.dk (Mads Orbesen Troest)
Subject: Re: regexp help
Message-Id: <k6fk2tedC4v7-pn2-wp34H8dOTjkz@mads.lokal.net>

On Mon, 24 Jul 2000 19:16:53, cyriac@usna.navy.mil (George Cyriac {EME
SEAP}) wrote:

> $from{'description'} =3D~ /\\n/<br>/;

Try something like:

   $txt =3D "this is\na test!";
   $txt =3D~ s/\n/\<br\>/g;
   print $txt;
   -> this is<br>a test!

      ... /\/\\ads Orbesen Troest <mads@troest.NEVERMORE.dk>

(Please remove NEVERMORE from address when replying via email...)


------------------------------

Date: Mon, 24 Jul 2000 18:34:28 GMT
From: Dan Sugalski <dan@tuatha.sidhe.org>
Subject: Re: searching multiple sites -
Message-Id: <U_%e5.4647$f_5.22943@news1.rdc1.ct.home.com>

Nitin <muhala@my-deja.com> wrote:

> I'm trying to write a script that will allow a user to enter a search
> term and have it searched over multiple web sites. The problem I am
> running into is that some of these sites that I am searching are
> password protected. I have access to the sites and I know how to deal
> with sites that are using the standard web server authentication (where
> the browser pops up the the userid/password challenge box). 

Well, if you've got the permission of the site owner, they ought to be
able to fix you up with the appropriate code and/or specs. If you don't
have that permission, then you should go get it. (Which will likely get
you the info you need to do the searching properly)

				Dan


------------------------------

Date: Mon, 24 Jul 2000 13:19:34 -0500
From: "Chris Durbin" <Chris.Durbin@motorola.com>
Subject: Re: Simple Reg Expression Question
Message-Id: <8li1g2$73s3@nntp.cig.mot.com>


"Kenny Lim" <kennylim@techie.net> wrote in message
news:vXz85.31257$NP5.922995@newsread2.prod.itd.earthlink.net...
> Hi Tony,
>
> My explicit requirement would be able to split
> the words and numbers. (the number to be split has
> to be only the last 2 digits from the right)
>
> ie.
>
> DB2Explorer52
>
> Words  : DB2Explorer <---As you can see, DB2 also comprise numbers which
we
> will avoid splitting.
> Numbers : 52
>
> Split to :
>
> ${1} = Words
> ${2} = numbers
>
>
It is very possible, you  should look up Perl's regex shortcuts.
\d - any single digit
\D - any non-digit character
\w - any word character (A-Za-z0-9_)
\W - any non-word character
\s - any whitespace character (\t,\n, ,\r,\f)
\S - any non- whitespace character

and the modifiers
* - any number of ( zero or more instances )
+ - one or more instances of.

and always try to anchor your regex using ^ and/or $
^ - beginning of the line
$ - end of the line ( as determined by the current eol delimiter, \n)

so to answer you original query, how to match

> ProgID = s 'DatabaseSearch5.DatabaseSearchWindow.1'
> ProgID = s 'Explorer.DatabaseSearchWindow.1'
> ProgID = s 'DB2Explorer5.DatabaseSearchWindow.1'

you can anchor at either front or back or both to be completely anal... $^)

while(<DATA>)
{
    s/^ProgID = s'(\w+)\d[0,2](\..*$)/$1 52 $2/;
 }




------------------------------

Date: 16 Sep 99 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 16 Sep 99)
Message-Id: <null>


Administrivia:

The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc.  For subscription or unsubscription requests, send
the single line:

	subscribe perl-users
or:
	unsubscribe perl-users

to almanac@ruby.oce.orst.edu.  

| NOTE: The mail to news gateway, and thus the ability to submit articles
| through this service to the newsgroup, has been removed. I do not have
| time to individually vet each article to make sure that someone isn't
| abusing the service, and I no longer have any desire to waste my time
| dealing with the campus admins when some fool complains to them about an
| article that has come through the gateway instead of complaining
| to the source.

To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.

To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.

For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.


------------------------------
End of Perl-Users Digest V9 Issue 3788
**************************************


home help back first fref pref prev next nref lref last post