[8062] in Perl-Users-Digest
resending truncated digests issues 1680-1683
daemon@ATHENA.MIT.EDU (Perl-Users-Request@ruby.OCE.ORST.E)
Tue Jan 20 17:07:08 1998
Date: Tue, 20 Jan 98 13:34:50 -0800
From: Perl-Users-Request@ruby.OCE.ORST.EDU
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Tue, 20 Jan 1998 Volume: 8 Number: 1681
Today's topics:
cgi form <mr.t@umich.edu>
Re: cgi form (brian d foy)
CGI-BIN script - parameter encryption <mikeh@summitfs.demon.co.uk>
Re: CGI-BIN script - parameter encryption <mr.t@umich.edu>
DBD-oracle <scarpa@mall.it>
Re: DBD-oracle (brian d foy)
Re: Download Usenet group (Greg Bacon)
embedding perl in C++ (Giuseppe Vacanti)
Re: File name from descriptor (Andrew M. Langmead)
Re: GetOpts::Std and 'Use of Uninitialized variable' er <mhazen@franklin.uga.edu>
Re: How to read A:\ from web site (peter caffin)
Re: How to write fixed format data? (brian d foy)
Re: I need a man to lick me in to a frenzy!!! (Mike Stok)
Re: I need some help pleeze (M.J.T. Guy)
Installing and compiling modules (SGI, IRIX 6.2) <lance@junto.net>
Re: IsDate and IsNumeric available? <xxTony.Curtis@vcpc.univie.ac.at>
Re: IsDate and IsNumeric available? (brian d foy)
Re: JavaScript & Perl <denis.lamotteE@interact.lu>
Re: living and free software (was: Re: source into bina (Greg Bacon)
Re: localtime: <barnett@houston.Geco-Prakla.slb.com>
Re: Odd syntax problem (Andrew M. Langmead)
Oraperl and long type <monica@enol.tid.es>
Re: perl (Win95) and DOS commands??? <"martin papproth"@nmp.nokia.com>
Re: Puzzling behavior of c.l.p.* readers (Greg Bacon)
Digest Administrivia (Last modified: 8 Mar 97) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Tue, 20 Jan 1998 11:30:37 -0500
From: "SPLiNTeR" <mr.t@umich.edu>
Subject: cgi form
Message-Id: <6a2jg1$hsv$1@charm.magnus.acs.ohio-state.edu>
I am making a webpage in which an admin will enter a NIC hardware address
into a database. NIC hardware addresses consist of five groups of two
hexidecimal numbers.
I want to have 5 input boxes that each contain 2 digits.
Is there a way to automatically go to the next box when the first one is
filled in?
also, how do I check the data to make sure that the number entered was
indeed hexidecimal?
Any help, comments or links to successfull usage of this is appreciated.
please reply to me via email.
thanks,
SPLiNTeR
mr.t@umich.edu
------------------------------
Date: Tue, 20 Jan 1998 12:00:19 -0500
From: comdog@computerdog.com (brian d foy)
Subject: Re: cgi form
Message-Id: <comdog-ya02408000R2001981200190001@news.panix.com>
Keywords: from just another new york perl hacker
In article <6a2jg1$hsv$1@charm.magnus.acs.ohio-state.edu>, "SPLiNTeR" <mr.t@umich.edu> posted:
>I am making a webpage in which an admin will enter a NIC hardware address
>into a database. NIC hardware addresses consist of five groups of two
>hexidecimal numbers.
>Is there a way to automatically go to the next box when the first one is
>filled in?
depends on the client. this is not a perl thing.
>also, how do I check the data to make sure that the number entered was
>indeed hexidecimal?
um, ensure that it only has two digits and that each digit is
an acceptable hexadecimal number?
--
brian d foy <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>
------------------------------
Date: Tue, 20 Jan 1998 15:17:49 +0000
From: Mike Haberfield <mikeh@summitfs.demon.co.uk>
Subject: CGI-BIN script - parameter encryption
Message-Id: <34C4C01D.6B4E@summitfs.demon.co.uk>
Folks,
Sorry if this is the wrong newsgroup but I couldn't find an HTML /
CGI-BIN script group....
I have a very simple HTML Form with two input fields - User Name and
Password, where the Password field is defined as TYPE Password so that
it doesn't get echoed to the screen (you just get asterisks instead).
However, when I click on the SUBMIT button the parameters are passed
through to my cgi-bin Perl script *unencrypted*, and worse still when I
generate my HTML response page from within the Perl script the resulting
Location reference within the browser shows the URL with the source
parameters appended and visible "?Name=mike;Password=ohdearme". This is
not good.
Is there any way to either encrypt the parameters before they're sent to
my cgi-bin script, or prevent the parameters from being displayed as
part of the URL in the Location field when the result screen is
displayed.
Any help greatly appreciated.
Cheers,
Mike
--
Mike Haberfield, Tel: 0171 236 2850
Summit Financial Systems Ltd, Fax: 0171 236 2677
22 Cousin Lane, e-mail mikeh@summitfs.demon.co.uk
London EC4R 3TE
------------------------------
Date: Tue, 20 Jan 1998 11:25:00 -0500
From: "SPLiNTeR" <mr.t@umich.edu>
Subject: Re: CGI-BIN script - parameter encryption
Message-Id: <6a2j5e$hr3$1@charm.magnus.acs.ohio-state.edu>
you could use frames to kide the url of the displayed page... a user could
still see the url if the were to view the source though...
-SPLiNTeR
>Is there any way to either encrypt the parameters before they're sent to
>my cgi-bin script, or prevent the parameters from being displayed as
>part of the URL in the Location field when the result screen is
>displayed.
------------------------------
Date: Tue, 20 Jan 1998 17:28:22 +0100
From: Daniele Scarpa <scarpa@mall.it>
Subject: DBD-oracle
Message-Id: <34C4D0A5.A4ECA87A@mall.it>
I'm installing perl-dbi-0.91.tar.gz and perl-dbd-oracle-0.47.tar.gz.
DBI is Ok, on the contrary after to have unzipped the driver
perl-dbd-oracle-0.47.tar.gz , it don't create Makefile. This file is
requested from command "make".
(I have read the "readme" file).
What do I do?
Thank you!
Bye
daniele
------------------------------
Date: Tue, 20 Jan 1998 11:55:16 -0500
From: comdog@computerdog.com (brian d foy)
Subject: Re: DBD-oracle
Message-Id: <comdog-ya02408000R2001981155160001@news.panix.com>
Keywords: from just another new york perl hacker
In article <34C4D0A5.A4ECA87A@mall.it>, Daniele Scarpa <scarpa@mall.it> posted:
>I'm installing perl-dbi-0.91.tar.gz and perl-dbd-oracle-0.47.tar.gz.
>DBI is Ok, on the contrary after to have unzipped the driver
>perl-dbd-oracle-0.47.tar.gz , it don't create Makefile. This file is
>requested from command "make".
>(I have read the "readme" file).
did you see the section "BUILDING" and do as it said:
perl Makefile.PL
and if you had trouble with that did you see the section
"IF YOU HAVE PROBLEMS"?
--
brian d foy <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>
------------------------------
Date: 20 Jan 1998 15:59:16 GMT
From: gbacon@adtran.com (Greg Bacon)
To: "Lars Kr. Lundin" <lkl@runge.uni-c.dk>
Subject: Re: Download Usenet group
Message-Id: <6a2hkk$m06$1@info.uah.edu>
[Posted and mailed]
In article <34C2A93A.FF6@runge.uni-c.dk>,
"Lars Kr. Lundin" <lkl@runge.uni-c.dk> writes:
: Can anybody tell me how I can use perl to download the postings
: in a Usenet group?
#! /usr/bin/perl -w
use News::Scan;
my $scan = new News::Scan Group => 'comp.lang.perl.misc',
Spool => '/tmp/clpm',
From => 'nntp',
NNTPServer => 'news.dom.ain:119';
if (not defined $scan) {
die "Failed to create News::Group object\n";
}
elsif ($scan->error) {
die "Error: " . $scan->error . "\n";
}
$scan->collect;
if ($scan->error) {
die "Error: " . $scan->error . "\n";
}
The above program is included as `nntpget' in the eg/ directory of my
News-Scan distribution. Go to
http://www.perl.com/CPAN/authors/id/GBACON/
Hope this helps,
Greg
--
open G,"|gzip -dc";$_=<<EOF;s/([0-9a-f]+)/print G pack"h*",$1/eg
f1b88000b620f22320303fa2d2e21584ccbcf29c84d2258084
d2ac158c84c4ece4d22d1000118a8d5491000000
EOF
------------------------------
Date: 20 Jan 1998 16:57:06 +0100
From: gvacanti@astro.estec.esa.nl (Giuseppe Vacanti)
Subject: embedding perl in C++
Message-Id: <lhsoqj6svh.fsf@sapc47.estec.esa.nl>
--Multipart_Tue_Jan_20_16:57:06_1998-1
Content-Type: text/plain; charset=US-ASCII
I'm trying to run a perl interpreter from within a C++ program. Could
anybody point me to an example of how to do this? I tried to follow
the instructions in perlembed(1), and the Camel and the Leopard books,
but although they mention C++ they only seems to give examples for C.
Perhaps they're trying to tell me something ? :-)
Thanks,
--Multipart_Tue_Jan_20_16:57:06_1998-1
Content-Type: text/plain; charset=US-ASCII
Giuseppe Vacanti gvacanti@astro.estec.esa.nl
Astrophysics Division vox: +31-71-5654175
Space Science Department of ESA/ESTEC fax: +31-71-5654690
Postbus 299, 2200 AG Noordwijk, The Netherlands
--Multipart_Tue_Jan_20_16:57:06_1998-1--
------------------------------
Date: Tue, 20 Jan 1998 15:11:12 GMT
From: aml@world.std.com (Andrew M. Langmead)
Subject: Re: File name from descriptor
Message-Id: <En38uo.Dx6@world.std.com>
rc0230@email.mot.com (David Stashower) writes:
>Is there a way to retrieve the file name (relative, full pathname,
>whatever) from an "open" file-descriptor ? I.e. such that a routine can
>be passed a descriptor for an open file, but be able to "find out" and
>handle the actual file involved.
This is from the comp.unix FAQ. <URL:http://www.landfield.com/faqs/
unix-faq/faq/part4/>
4.3) How do I find the name of an open file?
In general, this is too difficult. The file descriptor may
be attached to a pipe or pty, in which case it has no name.
It may be attached to a file that has been removed. It may
have multiple names, due to either hard or symbolic links.
If you really need to do this, and be sure you think long
and hard about it and have decided that you have no choice,
you can use find with the -inum and possibly -xdev option,
or you can use ncheck, or you can recreate the functionality
of one of these within your program. Just realize that
searching a 600 megabyte filesystem for a file that may not
even exist is going to take some time.
--
Andrew Langmead
------------------------------
Date: Tue, 20 Jan 1998 11:21:19 -0500
From: Mark Hazen <mhazen@franklin.uga.edu>
To: Tom Phoenix <rootbeer@teleport.com>
Subject: Re: GetOpts::Std and 'Use of Uninitialized variable' errors?
Message-Id: <Pine.WNT.3.95.980120104353.-146225I-100000@fcsg1.franklin.uga.edu>
> > I can't use the '-T' flag (as far as I know) because of two things: one
> > of the command line options allows the user to point anywhere they wish
> That needn't preclude taint checking. You should verify that the filename
> given is valid and meets any other criteria you need (stat and the
> filetest operators should be all right; you may or may not care about
> checking the directories and possible symlinks along the path to the
> file). Then you may use the methods in the perlsec manpage to make an
> untainted copy of the filename, which you may then use however you need.
Many thanks. I'll do a parse for naughty characters and then a filetest.
> You may wish to require the config file to be located in one of a short
> list of safe places, such as the user's own home directory or a known-good
> system directory.
This came to mind as well; I was wanting to leave the options open to the
user though (as I'm going to be giving this to a handful of other people
to run on their systems, too).
> As you should be; that's almost certainly the wrong approach. Did you
> realize that you needn't put a program's containing directory into the
Ah, but I get errors if I try to do a File::Find in a directory that isn't
in ENV{'PATH'} if I've got taint checks on.... :(
For example, the following will generate an insecure path error:
#!/usr/bin/perl -Tw
use File::Find;
&find('./');
exit;
sub wanted {
(($dev,$ino,$mode,$nlink,$uid,$gid) = lstat($_)) &&
(int(-M _) == 2) && -f _;}
> Maybe you don't need taint checking, then. But what's the config file all
> about? And why should you need a PATH at all?
The long and the short of it: I'm writing a program which, depending on
the information it gets from a config file, scans directories of web pages
and reports on modified files. The config file is to allow others to
customise the program to their own site more easily, and to allow
*multiplt* configurations (i.e. the program can report back in text, a
snippet of HTML, or a full web page. I can set up different config files
for differently-formatted reports, and make them cron jobs.
I'd be glad to mail the program if you're interested and have that much
free time (grin), but it's rather lengthy (approx. 400 lines) and I'm
reaaly not trying to foist my code onto someone else's shoulders. :)
> BEGIN { die "Can't run $0 if not root" if $< or $> }
Yep, already got this.... (see, I do read other people's source code!
::grin::)
> Of course, if root is running it, who cares where the config file is? And
> taint checking is probably a waste of time, right? (Why would root have to
> feed bogus data to the script? Root can edit the script!)
Agreed. I'm just trying to be *overly* paranoid. :)
> Yes; my() variables aren't accessible by name outside their scope. The
Gotcha. I'm using 'use vars qw(....)' now instead of 'my', thanks to
another reply to this message.
> > ($opt_d = 1)"
>
> That's not right. == perhaps?
Oops. Yep, typo in the posting. I think I understand more now where my
error lay... again, thanks!
-mh.
----
. _+m"m+_"+_ Mark Hazen Network Administrator, Dean's Office
d' Jp qh qh The Franklin College of Arts & Sciences
Jp O O O The University of Georgia (706)542-1546
Yb Yb dY dY
O "Y5m2Y" " even the mightiest wave starts out as a ripple.
"Y_ why make waves when it's easier to nurture ripples?
------------------------------
Date: Tue, 20 Jan 1998 15:46:37 GMT
From: nospam_synic@omen.net.au (peter caffin)
Subject: Re: How to read A:\ from web site
Message-Id: <34cbc54e.8522989@news.omen.net.au>
Eric Bohlman <ebohlman@netcom.com> did cunningly address to
comp.lang.perl.misc..
:Spur Electron Ltd <dmitchell@spurelec.demon.co.uk> wrote:
:: I'm using the following code to check for a file on the A:\ drive
[...]
:You can't. Period. At least not via a CGI script running on an HTTP
:server.
Make sure that your sysadmin has mounted the A: drive and that you have made a
link to that drive (/dev/fdd0 or whatever) from your public_html directory.
Your sysadmin will have to manually mount those floppies every disk change.
The above is for a UNIX/Linux server. I have no idea about how you'd do it for
DOS/Win3.1/Win95/WinNT.
:Your -e test is looking for a file on the *server's* A: drive,
:if it even has one (not likely if it's a Unix server!). I suggest you
:get a good tutorial on CGI and HTTP, as you seem to have some serious
:misconceptions about how they work.
It can be done, but, I doubt any sysadmin would help you do it (and you'd most
likely need one to) unless it was _absolutely_massively_urgent_ because it's
generally an utter pain in the butt.
--: _ ___ _ _ _
_oo__ |_|_ |__ _ | | _ |_|_' _ mailto:synic@omen.net.au
//`'\_ | (/_|(/_| .|. |_(_|| | || | http://www.omen.net.au/~synic
/
------------------------------
Date: Tue, 20 Jan 1998 11:14:25 -0500
From: comdog@computerdog.com (brian d foy)
Subject: Re: How to write fixed format data?
Message-Id: <comdog-ya02408000R2001981114250001@news.panix.com>
Keywords: from just another new york perl hacker
In article <34C391DF.D2DA7562@fox.cisti.nrc.ca>, Pascal Houde <houde@fox.cisti.nrc.ca> posted:
>I'm currently using the format function to set a fixed record.
>The problem is that my fixed record is over 1000 chars long!
>Some fields are 200 long. So you imagine the number of <<< I have!
>Is there any other way to set a fixed record in a simpler way?
you might try sprintf or pack, or wrap your interface into a
module so your scripts don't have to worry about the details.
good luck :)
--
brian d foy <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>
------------------------------
Date: 20 Jan 1998 11:15:18 -0500
From: mike@stok.co.uk (Mike Stok)
Subject: Re: I need a man to lick me in to a frenzy!!!
Message-Id: <6a2iim$174$1@stok.co.uk>
In article <6a2a08$1s1$1@gaia.ns.utk.edu>,
Jay Flaherty <fty_no_spam@utk.edu> wrote:
>while(!($frenzy)) {
> lick_me();
>}
Might that be clearer as
&lick_me until $frenzy;
Hope this helps,
Mike
--
mike@stok.co.uk | The "`Stok' disclaimers" apply.
http://www.stok.co.uk/~mike/ | PGP fingerprint FE 56 4D 7D 42 1A 4A 9C
http://www.tiac.net/users/stok/ | 65 F3 3F 1D 27 22 B7 41
stok@colltech.com | Collective Technologies (work)
------------------------------
Date: 20 Jan 1998 15:55:43 GMT
From: mjtg@cus.cam.ac.uk (M.J.T. Guy)
Subject: Re: I need some help pleeze
Message-Id: <6a2hdv$oe9$1@lyra.csx.cam.ac.uk>
David Waring <dwaring@nwsr.com> wrote:
>Just wondering, what is the == doing when comparing two strings? In other
>words, why is ($sex == "M") true when $sex = "F"?
If you are using -w, what == will do is say "Argument isn't numeric ... ".
Without -w, you won't get the benefit of this wisdom, but Perl will do
its best by converting any initial number in the string. In this case
there's no initial number, so Perl will convert the empty string,
giving 0. So the test boils down to 0 == 0, which is well known to
be true.
Mike Guy
------------------------------
Date: Tue, 20 Jan 1998 13:16:02 -0500
From: Lance Turner <lance@junto.net>
Subject: Installing and compiling modules (SGI, IRIX 6.2)
Message-Id: <34C4E9E2.794B@junto.net>
My attempts at installing Perl Modules due to what appears to be the
necessity of the SGI (cc) C Compiler.
I have gcc 2.7.x installed. Can this be used to compile Perl Modules in
place of cc? (The module I'm trying to install at present is
MIME-Base64-2.0.3.)
I guess I also need a more basic question answered: is compilation
necessary for the installation of all perl modules?
And while I'm at it: up to now I've been using pre-compiled copies of
Perl. Can gcc be used to compile Perl? And what are the advantages of
compiling Perl instead of using a copy that was pre-compiled for my
system?
--
Lance Turner
lance@junto.net
------------------------------
Date: 20 Jan 1998 15:54:18 +0100
From: Remove xx to reply <xxTony.Curtis@vcpc.univie.ac.at>
To: A.Chui@orbis.co.uk
Subject: Re: IsDate and IsNumeric available?
Message-Id: <7xu3azmc11.fsf@haze.vcpc.univie.ac.at>
Re: IsDate and IsNumeric available?, Atta
<A.Chui@orbis.co.uk> said:
Atta> Hi there, I'm trying to parse some text files. One
Atta> problem is to find out whether or not a sub-string is
Atta> a valid date. Similarly whether or not a sub-string is
Atta> a valid real number.
Have a look at the Date modules on CPAN. There are methods
for mungeing around dates and checking them (specifically
Date::DateCalc).
hth,
tony
------------------------------
Date: Tue, 20 Jan 1998 11:30:45 -0500
From: comdog@computerdog.com (brian d foy)
Subject: Re: IsDate and IsNumeric available?
Message-Id: <comdog-ya02408000R2001981130450001@news.panix.com>
Keywords: from just another new york perl hacker
In article <01bd25a9$cb60c760$e37599c3@peugeot>, "Atta Chui" <A.Chui@orbis.co.uk> posted:
>IsNumeric:
> /[+-]?[1-9]\d*(.\d*)?([Ee][+-]?\d*)?/
>but still I don't know if the number would not be out of range.
then test the range as well to ensure that it's magnitude is
acceptable. perhaps you want a really complex regex that you
could spend lots of time testing, or you could use a couple
of simple if() statements.
you might check your regex and think about how it matches:
"0.5" (this one is curious...)
"there is a number here --> 5"
"1.e"
"9e-"
>IsDate:
[snip]
>If you have a better way to do it, or there are source codes available,
>please let me know.
there are lots of Date modules on CPAN. they'll do this sort of
thing for you.
--
brian d foy <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>
------------------------------
Date: Tue, 20 Jan 1998 15:29:34 +0200
From: denis LAMOTTE <denis.lamotteE@interact.lu>
Subject: Re: JavaScript & Perl
Message-Id: <34C4A6AE.E66@interact.lu>
Jerry Davis wrote:
>
> Anyone know if it is possible to pass a value from java script into a perl
> program. I know it is wishful thinking but. . .
>
> For example the javascript command document.referrer will return the
> referring page. I am wondering if there is a way to pass that into a script
> via the get method.
>
> Jerry (the wishful thinker)
yes
if you declare
jscript var temp = "ok"
you can use it in perl $temp
i think it work in the other sense too but try it
------------------------------
Date: 20 Jan 1998 15:36:12 GMT
From: gbacon@adtran.com (Greg Bacon)
Subject: Re: living and free software (was: Re: source into binary code)
Message-Id: <6a2g9c$koh$1@info.uah.edu>
In article <6a19ht$cii$1@news.orst.edu>,
stanley@skyking.OCE.ORST.EDU (John Stanley) writes:
: In article <6a0o44$20k$9@info.uah.edu>, Greg Bacon <gbacon@adtran.com> wrote:
: >I don't have much use for useless software. :-)
:
: Neither do I. But I don't consider commercial software to be useless
: just because I had to pay for it.
Why do you refuse to argue sensibly? I was referring to this statement
you made:
``With perl, if you give the source away, you give the ability to
use it away.''
What need does software I can't use meet?
: >No one is claiming to make a living by giving away software. Why do you
: >insist on returning to a settled point?
:
: Because it hasn't been settled. You think you settled it by proving the
: claim wasn't made, but you quoted the claim in the same article where
: you tried proving it didn't happen.
Any sensible person should be able to see two points in this thread:
1) it's not possible to put food on the table if your only activity is
giving things away, and 2) no one is claiming the opposite--giving
away software is a nice side effect.
: >MAKING A LIVING AND GIVING AWAY SOFTWARE ARE INDEPENDENT EVENTS--
:
: Not when they are connected in the same sentence with the word "by".
: That's a causal relationship. The events "make meatloaf" and "running
: over cats" are usually independent, until you say "I make meatloaf by
: running over cats and cooking them." Yes, the word "by" is important.
That is a very rigid and dogmatic reading. You also missed that other
important word ``while'' in Phoenix's post.
: >It is natural and normal to harbor contempt for those who cause trouble
: >and are generally harmful to society.
:
: Please support that statement with proof or retract it. It is a long
: way from "I won't give you my code for free" to causing trouble for
: society.
Have you read ``Why Software Should Be Free''? Richard Stallman makes
a great case. Check it out at
http://www.cs.uah.edu/cs/students/gbacon/wssbf.txt
: >You're referring to selling an obfuscated version of your work. This is
: >still hoarding.
:
: The work is available to anyone who wants to use it. You cannot see how
: it was done, just as I cannot walk into HP and expect to see how they
: fab the chips for the calculator I just bought, nor can I learn how by
: grinding the top off the chips in the one I bought. Nor can I take the
: automotive diagnostic computer apart at the local garage just because I
: had a tuneup done there, to see how it is done.
There's a difference between copying software and copying something
concrete like a calculator.
: >No one can benefit from what you've learned.
:
: Don't be silly. Anyone can benefit from what I've learned, they just
: have to pay for it. The benefit is the operation of the program,
: not the ability to see the code itself. Did you notice that there is a
: thing called "tuition" at most schools? Do you resent all those
: professors who expect to be paid to teach you the things they have
: learned?
You're really reaching now, Stanley. First, using your intentionally
obfuscated end product, they can only benefit from what you've learned
in that they're bound by the bugs present and the features that aren't
present; they can't fix or improve upon your work. Second, I'm not
proposing a Star Trek-esque economic model. The ideal of free software
is attainable and fits in our current economic model.
: Did you also notice that most of the world would not benefit one tiny
: bit by seeing the code, but many may benefit from its use? E.g., the
: code that runs the MRI systems sold by GE. I would get no benefit from
: seeing the code used by these "greedy code hoarders", but damn wouldn't
: the results of the code be helpful if I needed an MRI? Here is just one
: example of why "greedy code hoarding" can be good. Would you want your
: doctor programming the MRI machine? Would you even expect him to know
: about quadrature phases and pulse programming so he could detect any
: errors in the program? Would you like to be IN the MRI when his program
: runs the first time? (No, no, doctor, the paramter to that call is in
: units of seconds, not microseconds. 3000 is MUCH too long a time to have
: the full power of the RF unit applied.)
Your straw man is burning, Stanley.
: >You're not contributing to human knowledge.
:
: What a wonderfully subjective measure of the value of existance. By this
: measure, a good 90% of the population of the Earth should be taken out
: and shot. No, let's be lenient. 50%.
I've never suggested shooting Bill Gates because of his proprietary
software. I count two burning strawmen.
: >Greed is motivating you to the
: >point of eliminating any feelings of altruism you might have. I
:
: And now we are at the extreme end of the pendulum swing, where the
: desire to feed one's family by doing something one is good at is
: equated to "greed" and anyone who wants to do this lacks any feelings
: of altruism. Yes, all must learn to play the piano. A Utopia in the
: making.
Has anyone suggested intentionally starving oneself or one's family?
That would be preposterous! Many can and do earn good money by selling
the service of writing or modifying software. They also happen to make
that software freely available. For whatever reason, they choose not
to act on greed and laziness in attempts to "maximize their profits".
Real programmers don't have to stop at one program. :-)
: >The Internet wasn't pioneered by greedy source hoarders,
:
: No, it was pioneered by people who were being paid to develop code. It
: cost them nothing to give the code to others who were doing the same
: thing because they weren't being paid by how much they wrote or based
: on how many copies they sold. In fact, they were being paid by the
: government (ARPA, remember?).
Bingo! Did I see a light bulb above your head? It seems you're finally
getting the point after three rounds. That's the same model we've been
describing all along.
: >No Utopia can last when there's greed.
:
: No Utopia exists when people are hungry. Somehow, equating the Internet
: to Utopia lessens the value of Utopia, or inappropriately agrandizes
: the Internet.
This remark leads me to believe that either you haven't been using the
Internet for very long or that you haven't realized the full potential,
perhaps both.
: >I'm just painting a picture of how nice
: >things would be for everyone if they joined the free software movement.
:
: It would be nicer for those who want the software for free, no doubt
: about that. It wouldn't be as nice a place for people who currently make
: their livings writing code and selling it, but they are scum anyway so
: who cares, right?
Go read ``Why Software Should Be Free''.
: Had an MRI recently? Used a modem? Those greedy software hoarders at
: Hayes...
There's a difference between copying software and making a copy of a
modem.
Greg
--
open G,"|gzip -dc";$_=<<EOF;s/([0-9a-f]+)/print G pack"h*",$1/eg
f1b88000b620f22320303fa2d2e21584ccbcf29c84d2258084
d2ac158c84c4ece4d22d1000118a8d5491000000
EOF
------------------------------
Date: Tue, 20 Jan 1998 09:04:08 -0600
From: Dave Barnett <barnett@houston.Geco-Prakla.slb.com>
Subject: Re: localtime:
Message-Id: <34C4BCE8.2948951B@houston.Geco-Prakla.slb.com>
Jahnel Klaus wrote:
>
> BUt i don t have a file i have entries in a file to delete.
> klaus
>
> Richard Remington wrote:
>
> > Jahnel Klaus wrote:
> > >
> > > i get the time with localtime:
> > > i ve now a problem:
> > > how can i handle it to delete files which are older than 2 days of
^^^^^^^^^^^^^^^^^^^
Then why did you ask 'how can i handle it to delete files?' when you
really wanted to know 'how can I use localtime to delete entries in
files'???
> > > actual date?
> > > Klaus
Now, that gets a bit more tricky. What is the format of your data in
the file? I'm assuming each entry has a date.... Are dates in
mm/dd/yy, dd/mm/yy, mm/dd/yyyy, dd/mm/yyyy, or some other format? Or
are the dates of the entries number of seconds since the Epoch?
A bit more information might allow us to help a bit more.
Dave
--
"Security through obscurity is no security at all."
-comp.lang.perl.misc newsgroup posting
------------------------------------------------------------------------
* Dave Barnett U.S.: barnett@houston.Geco-Prakla.slb.com *
* DAPD Software Support Eng U.K.: barnett@gatwick.Geco-Prakla.slb.com *
------------------------------------------------------------------------
------------------------------
Date: Tue, 20 Jan 1998 15:24:11 GMT
From: aml@world.std.com (Andrew M. Langmead)
Subject: Re: Odd syntax problem
Message-Id: <En39GB.v5@world.std.com>
root@atrium.cardima.com (System Administrator) writes:
>However, in practice, (a) works, and (b) generates a syntax error right
>before the split() call:
>$ perl -c tasks
>syntax error in file tasks at line 120, next 2 tokens "(split"
>Can anyone shed any light on this?
I assume you have an older version of perl. Mine says the following:
~>perl -e '$_ = join("/", splice(split(/\//, $_), -1, 1)) if (/=/);'
Type of arg 1 to splice must be array (not split) at -e line 1, near "1)"
Execution of -e aborted due to compilation errors.
~>perl -v
This is perl, version 5.004_01
Copyright 1987-1997, Larry Wall
Perl may be copied only under the terms of either the Artistic License or the
GNU General Public License, which may be found in the Perl 5.0 source kit.
The splice function must have an array (not just any kind of list) as
its first argument.
--
Andrew Langmead
------------------------------
Date: Tue, 20 Jan 1998 17:29:46 +0100
From: Monica Fernandez Barreiro <monica@enol.tid.es>
Subject: Oraperl and long type
Message-Id: <34C4D0FA.2696@enol.tid.es>
Hello:
I have a problem when I try to insert a variable long type
in the data base. In a exactly way I'm going to write the
code and the place where it doesn't work:
$txt = "insert into cuerpo_certificados
(email_mayusculas, codigo) values
('$email_upper', :1)";
$csr = &ora_open ($lda, $txt) || return (1, $ora_errstr);
&ora_bind($csr, $certificado);
do ora_close($csr) || return (1, $ora_errstr);
When the system tries to run the ora_bind it becames stoped and
useless to do anything.
That's all.
------------------------------
Date: Tue, 20 Jan 1998 16:36:51 +0100
From: martin papproth <"martin papproth"@nmp.nokia.com>
Subject: Re: perl (Win95) and DOS commands???
Message-Id: <34C4C493.531D@nmp.nokia.com>
i had the same problem; actually my Dr.Solomon Virusguard was
responsible for the stdin/out being handled somewhat different.
after disabling it, it works now perfectly.
maybe this helps you....
BR
Martin
Live long & prosper !
Junnu wrote:
>
> Please help me... this is very urgent problem...
>
> Couple of weeks ago this works:
>
> --- my perl script ---
> $cwd = `CD`;
> chop($cwd);
> print "my current directry: $cwd\n";
>
> --- and output should be ---
> my current directory: c:\tmp
>
> --- but it is ---
> c:\tmp
> my current directory:
>
> It works some days ago, but not any more... now it prints the CD
> information
> directly out, and $cwd variable does not get it anymore? What's changed?
>
> My w32 perl version is:
>
> --- begin of version ---
> This is perl, version 5.003_07
>
> Copyright 1987-1996, Larry Wall
>
> + suidperl security patch
> Win32 port Copyright (c) 1995-1996 Microsoft Corporation.
> All rights reserved.
> Developed by ActiveWare Internet Corp.,
> http://www.ActiveWare.com
>
> Perl for Win32 Build 303 - Built 14:27:31 Jan 29 1997
>
> Perl may be copied only under the terms of either the Artistic License
> or the
> GNU General Public License, which may be found in the Perl 5.0 source
> kit.
> --- end of version ---
>
> Could someone say, what is wrong? All the other things works, but
> DOS-command
> outputs are not going to STDOUT anymore?
>
> Please mail me, if you know any kind of information.
> --
> Vaasa Electronics Ltd
> juhani.puska@velco.fi
------------------------------
Date: 20 Jan 1998 16:13:24 GMT
From: gbacon@adtran.com (Greg Bacon)
Subject: Re: Puzzling behavior of c.l.p.* readers
Message-Id: <6a2if4$m06$2@info.uah.edu>
In article <6a1o5e$bvc@buffalo.hl.siemens.de>,
Marek.Rouchal@-nospam-hl.siemens.de (Marek Rouchal) writes:
: In article <6a0ifh$20k$3@info.uah.edu>, gbacon@adtran.com (Greg Bacon) writes:
: I believe one has to distinguish between posting to usenet and mailing
: single persons.
I (and others) like to provide a courtesy Cc: if the poster asks for
help or seems really confused. It overcomes Usenet propogation delay
and the possibility that someone might miss the followup in a high
volume group like clpm.
: Of course a human will be able to unmunge every modified
: address, but what I (and the previous posters) are aiming at is to outsmart
: those automatic address collectors.
What happens when someone Cc:-s you? If they unmunge your address, it's
``there for the pickins''.
: Believe me, I am dead sick of those $$$ making
: schemes (that alltogether are chain letter BTW) and porn ads. You'll
: say that I get that b...sh.. 'cause I asked for it. I didn't, period.
: I just posted to c.l.p.m, comp.lang.postscript and comp.os.linux.*.
Huh? I am 100% opposed to spam. I wish it were a capital offense.
I've resorted to filtering, and it is almost a complete solution to the
problem.
: > The effect is to inconvenience others who have a legitimate reason to
: > contact you and to break what has always worked. Address munging is a
: > poor solution to an already disgusting problem.
:
: I agree, but you should accept that others maybe had bigger problems than
: you had (just guessing...) with spamming. After fighting some of the worst
: spammers with the help of their providers, my inbox is almost free of spam
: mail at last. I'd like to keep it that way.
I've been in the same position; that's why I resorted to filtering.
Anyone interested in seeing what I've done (which is based heavily on
a filter by Tom Christiansen) only has to ask.
: PS. I know my munged address would be easy to "crack" even for some piece of
: software. But so far it seems suffiecient.
As long as no one unmunges your address to Cc: you.
Greg
--
open G,"|gzip -dc";$_=<<EOF;s/([0-9a-f]+)/print G pack"h*",$1/eg
f1b88000b620f22320303fa2d2e21584ccbcf29c84d2258084
d2ac158c84c4ece4d22d1000118a8d5491000000
EOF
------------------------------
Date: 8 Mar 97 21:33:47 GMT (Last modified)
From: Perl-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 8 Mar 97)
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.
To submit articles to comp.lang.perl.misc (and this Digest), send your
article to perl-users@ruby.oce.orst.edu.
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.
The Meta-FAQ, an article containing information about the FAQ, is
available by requesting "send perl-users meta-faq". The real FAQ, as it
appeared last in the newsgroup, can be retrieved with the request "send
perl-users FAQ". Due to their sizes, neither the Meta-FAQ nor the FAQ
are included in the digest.
The "mini-FAQ", which is an updated version of the Meta-FAQ, is
available by requesting "send perl-users mini-faq". It appears twice
weekly in the group, but is not distributed in the digest.
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 V8 Issue 1681
**************************************