NYCPHP Meetup

NYPHP.org

[nycphp-talk] enabling gd on Unix

Rafi Sheikh Rafi.Sheikh at Ingenix.com
Wed Mar 24 10:40:07 EST 2004


Hello folks, thank you for your time and answers.  I will drop this thread
since the sys admin is vehemently adamant that he will only install from the
CD that came with the server (IBM), and it is pre-compiled, and does not
have gd enabled, plus PHP is 4.0.6, plus jpgrpah won't work either...b4 I
shoot him I better give up-  Sigh!

Thanks

-----Original Message-----
From: talk-request at lists.nyphp.org [mailto:talk-request at lists.nyphp.org]
Sent: Wednesday, March 24, 2004 9:35 AM
To: talk at lists.nyphp.org
Subject: talk Digest, Vol 10, Issue 46


Send talk mailing list submissions to
	talk at lists.nyphp.org

To subscribe or unsubscribe via the World Wide Web, visit
	http://lists.nyphp.org/mailman/listinfo/talk
or, via email, send a message with subject or body 'help' to
	talk-request at lists.nyphp.org

You can reach the person managing the list at
	talk-owner at lists.nyphp.org

When replying, please edit your Subject line so it is more specific
than "Re: Contents of talk digest..."


Today's Topics:

   1. gd on Unix (Rafi Sheikh)
   2. Re: when MySQL "rollback" doesn't (David Mintz)
   3. Re: gd on Unix (David Mintz)
   4. uploading and permissions (Greg Faber)
   5. Re: gd on Unix (Alan T. Miller)
   6. Re: uploading and permissions (Dan Cech)
   7. Re: gd on Unix (Daniel Convissor)
   8. Secure (XML-RPC) connection (Faber Fedor)
   9. Re: Secure (XML-RPC) connection (Mitch Pirtle)
  10. Re: Secure (XML-RPC) connection (Matthew Terenzio)
  11. Re: Secure (XML-RPC) connection (Mitch Pirtle)
  12. RE: Secure (XML-RPC) connection (Chris Bielanski)


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

Message: 1
Date: Tue, 23 Mar 2004 16:32:30 -0600
From: Rafi Sheikh <Rafi.Sheikh at Ingenix.com>
Subject: [nycphp-talk] gd on Unix
To: "'talk at lists.nyphp.org'" <talk at lists.nyphp.org>
Message-ID:
	<C92A8F8B60F96B42911EFA70AF30A88F060A4579 at msp7-msx1.ingenix.com>
Content-Type: text/plain;	charset="iso-8859-1"

Hi list:
BASICS:
apache 1.3.27, PHP 4.0.6, IBM server


How does one enables gd on Unix?

I do know that on WIN2K-pro one needs to uncomment the extensions for gd in
php.ini...but in Unix I dont see any listings (gd_php.so, etc)...how can I
find it (so I could tell the admin)... any suggestions?  

Here is what I have from the php_info()
Configure Command './configure' '--prefix=/opt/freeware' '--with-apxs'
'--with-mysql' '--with-config-file-path=/etc/opt/freeware/apache'
'--with-ftp' '--with-zlib' '--with-system-regex' '--without-xml'
'--with-ftp' '--with-ssl'

Configuration File (php.ini) Path /etc/opt/freeware/apache/php.ini 

***no gd info***

SERVER_SOFTWARE Apache/1.3.27 (Unix) PHP/4.0.6 




This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity to
which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified that
any dissemination, distribution or copying of this e-mail is prohibited. If
you have received this e-mail in error, please notify the sender by replying
to this message and delete this e-mail immediately.

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

Message: 2
Date: Tue, 23 Mar 2004 17:37:10 -0500 (EST)
From: David Mintz <dmintz at davidmintz.org>
Subject: Re: [nycphp-talk] when MySQL "rollback" doesn't
To: NYPHP Talk <talk at lists.nyphp.org>
Message-ID: <Pine.BSF.4.58.0403231728590.19528 at emra.pair.com>
Content-Type: TEXT/PLAIN; charset=US-ASCII

On Tue, 23 Mar 2004, Daniel Convissor wrote:

> Not to doubt you, but, uh, I guess I will, you're using innodb tables,
> right?  Okay, you are.  So, you've got a bug in your code.  Echo out each
> query before you execute it.  Make sure the scripts/queries are executing
> in the order you expect.  Then, if that doesn't get you no love, go to the
> length of copying/pasting the queries in the same order into a MySQL
> command line shell.
>

Ouch. So that means it *should* work... but I already rewrote this method
to do all its own SQL and tested it pretty thoroughly. It passed, so I
declared victory and committed it to my little repository. Now I gotta
decide whether to roll back (so to speak) to the previous revision and
wage more war... I was pretty much echoing the hell out of everything. And
yes the tables are InnoDB.

I think I'll go get on the subway now so I can get a front row seat at the
meeting. (Said he, changing the subject (-: )

Thanks Dan,


---
David Mintz
http://davidmintz.org/

        "Anybody else got a problem with Webistics?" -- Sopranos 24:17

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

Message: 3
Date: Tue, 23 Mar 2004 17:40:54 -0500 (EST)
From: David Mintz <dmintz at davidmintz.org>
Subject: Re: [nycphp-talk] gd on Unix
To: NYPHP Talk <talk at lists.nyphp.org>
Message-ID: <Pine.BSF.4.58.0403231738560.51623 at emra.pair.com>
Content-Type: TEXT/PLAIN; charset=US-ASCII

On Tue, 23 Mar 2004, Rafi Sheikh wrote:

> Hi list:
> BASICS:
> apache 1.3.27, PHP 4.0.6, IBM server
>
>
> How does one enables gd on Unix?
>
> I do know that on WIN2K-pro one needs to uncomment the extensions for gd
in
> php.ini...but in Unix I dont see any listings (gd_php.so, etc)...how can I
> find it (so I could tell the admin)... any suggestions?
>
> Here is what I have from the php_info()
> Configure Command './configure' '--prefix=/opt/freeware' '--with-apxs'
> '--with-mysql' '--with-config-file-path=/etc/opt/freeware/apache'
> '--with-ftp' '--with-zlib' '--with-system-regex' '--without-xml'
> '--with-ftp' '--with-ssl'


I believe you need '--with-gd' in your configure command.

(And if I'm wrong I know someone will set the record straight.)

HTH,

---
David Mintz
http://davidmintz.org/

        "Anybody else got a problem with Webistics?" -- Sopranos 24:17

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

Message: 4
Date: Tue, 23 Mar 2004 17:59:40 -0500
From: Greg Faber <greg at click3x.com>
Subject: [nycphp-talk] uploading and permissions
To: NYPHP Talk <talk at lists.nyphp.org>
Message-ID: <C3E6C0B9-7D1D-11D8-90DB-000502F1DDFC at click3x.com>
Content-Type: text/plain; charset=US-ASCII; format=flowed

Hi-

sorry to bug y'all with these beginner questions...

I made a little uploading site where I can upload various files, works 
great.
Now I want to archive the folders via the same web ui.
I can't tar anything because the permissions of the uploaded files are:
r-------- (ie: 400)
How can I change the permissions (or set them the way I want) on the 
files as I upload them?

thanks,
greg

ps: have fun in Montreal, it's just LOVELY this time of year ;-)


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

Message: 5
Date: Tue, 23 Mar 2004 17:41:36 -0800
From: "Alan T. Miller" <amiller at criticalmedia.biz>
Subject: Re: [nycphp-talk] gd on Unix
To: "NYPHP Talk" <talk at lists.nyphp.org>
Message-ID: <00e301c41141$25ee7ef0$6e0a0a0a at webdev>
Content-Type: text/plain;	charset="iso-8859-1"

Chances are you will also need to have installed libjpeg and libpng for PHP
to compile with the '--with-gd' option. And of course you will need to have
GD installed on your box as well. I just went through this all last night
and had to add those libraries (of course this was compiling php5 on Fedora
Linux against apache 1.3.9). PHP4 has a built in GD library does it not...
anyone?

Alan


----- Original Message ----- 
From: "David Mintz" <dmintz at davidmintz.org>
To: "NYPHP Talk" <talk at lists.nyphp.org>
Sent: Tuesday, March 23, 2004 2:40 PM
Subject: Re: [nycphp-talk] gd on Unix


> On Tue, 23 Mar 2004, Rafi Sheikh wrote:
>
> > Hi list:
> > BASICS:
> > apache 1.3.27, PHP 4.0.6, IBM server
> >
> >
> > How does one enables gd on Unix?
> >
> > I do know that on WIN2K-pro one needs to uncomment the extensions for gd
in
> > php.ini...but in Unix I dont see any listings (gd_php.so, etc)...how can
I
> > find it (so I could tell the admin)... any suggestions?
> >
> > Here is what I have from the php_info()
> > Configure Command './configure' '--prefix=/opt/freeware' '--with-apxs'
> > '--with-mysql' '--with-config-file-path=/etc/opt/freeware/apache'
> > '--with-ftp' '--with-zlib' '--with-system-regex' '--without-xml'
> > '--with-ftp' '--with-ssl'
>
>
> I believe you need '--with-gd' in your configure command.
>
> (And if I'm wrong I know someone will set the record straight.)
>
> HTH,
>
> ---
> David Mintz
> http://davidmintz.org/
>
>         "Anybody else got a problem with Webistics?" -- Sopranos 24:17
> _______________________________________________
> talk mailing list
> talk at lists.nyphp.org
> http://lists.nyphp.org/mailman/listinfo/talk
>


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

Message: 6
Date: Tue, 23 Mar 2004 20:16:48 -0500
From: Dan Cech <dcech at phpwerx.net>
Subject: Re: [nycphp-talk] uploading and permissions
To: NYPHP Talk <talk at lists.nyphp.org>
Message-ID: <4060E180.8020905 at phpwerx.net>
Content-Type: text/plain; charset=us-ascii; format=flowed

The first thing I'd try would be: http://php.net/chmod

Dan

Greg Faber wrote:
> Hi-
> 
> sorry to bug y'all with these beginner questions...
> 
> I made a little uploading site where I can upload various files, works 
> great.
> Now I want to archive the folders via the same web ui.
> I can't tar anything because the permissions of the uploaded files are:
> r-------- (ie: 400)
> How can I change the permissions (or set them the way I want) on the 
> files as I upload them?
> 
> thanks,
> greg
> 
> ps: have fun in Montreal, it's just LOVELY this time of year ;-)


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

Message: 7
Date: Wed, 24 Mar 2004 00:39:16 -0500
From: Daniel Convissor <danielc at analysisandsolutions.com>
Subject: Re: [nycphp-talk] gd on Unix
To: NYPHP Talk <talk at lists.nyphp.org>
Message-ID: <20040324053915.GA14106 at panix.com>
Content-Type: text/plain; charset=us-ascii

On Tue, Mar 23, 2004 at 05:41:36PM -0800, Alan T. Miller wrote:
> Chances are you will also need to have installed libjpeg and libpng for
PHP
> to compile with the '--with-gd' option.

Yep.  And zlib.

Here's what it took for me to get a _minimal_ PHP 5 build with GD...

./configure --prefix=/path/to/install \
    --with-gd --with-jpeg-dir=/usr/local --with-zlib-dir=/usr/local \
    --without-pear --disable-ipv6 --disable-libxml --disable-ctype \
    --disable-dom --disable-mbregex --disable-posix --disable-session \
    --disable-simplexml --disable-spl --disable-tokenizer --disable-xml \
    --disable-libtool-lock

--Dan

-- 
 T H E   A N A L Y S I S   A N D   S O L U T I O N S   C O M P A N Y
            data intensive web and database programming
                http://www.AnalysisAndSolutions.com/
 4015 7th Ave #4, Brooklyn NY 11232  v: 718-854-0335 f: 718-854-0409

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

Message: 8
Date: Wed, 24 Mar 2004 09:24:48 -0500
From: Faber Fedor <faber at linuxnj.com>
Subject: [nycphp-talk] Secure (XML-RPC) connection
To: NYPHP Talk <talk at lists.nyphp.org>
Message-ID: <20040324142448.GB13593 at uranus.faber.nom>
Content-Type: text/plain; charset=us-ascii

I need some extra brains for a design I'm doing.  Since it's going to
involve XML-RPC and PHP, I figured I'd ask here.

I'm putting together a basic shopping cart.  I can't use existing
solutions because the back end database is called jBASE (a variant of
PICK). jBASE lives on the Production Server behind a LinkSys
firewall/router.  The web site sits on the Web Server and is outside of
the firewall. The plan so far is: user submits a request (places an
order, wants to see Product ID# 1234, etc.) to the Web Server.  The Web
Server does some PHP magic and sends the request to the Production
Server via XML-RPC.  The Production Server does some (PHP?) magic and hands
the request to the database via CGI calls. When the Production Server
responds, the process is reversed.

I don't know how to do the XML-RPC magic above, but tht's part of the
fun of the project.  What I Can't figure out is how to securely transfer
the data between the two servers. I need a secure connection from the
Web Server, through the firewall to the Production Server that can't be
cracked by script kiddies and the like. I tried setting up a VPN tunnel
using FreeS/WAN And Openswan and I can't get them working after a week,
so it's time to try something else.

The client insists that this be done in real-time, so I can't have a
copy of the database on the web server.

Any ideas?

-- 
 
Regards,
 
Faber                     

Linux New Jersey: Open Source Solutions for New Jersey
http://www.linuxnj.com




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

Message: 9
Date: Wed, 24 Mar 2004 10:03:10 -0500
From: Mitch Pirtle <mitchy at spacemonkeylabs.com>
Subject: Re: [nycphp-talk] Secure (XML-RPC) connection
To: NYPHP Talk <talk at lists.nyphp.org>
Message-ID: <4061A32E.6050708 at spacemonkeylabs.com>
Content-Type: text/plain; charset=us-ascii; format=flowed

Faber Fedor wrote:

> The client insists that this be done in real-time, so I can't have a
> copy of the database on the web server.
> 
> Any ideas?

I am a unix guy, so I don't know how to implement this in the Windows 
world - keep that in mind.

One approach I took in the past was to use ssh and port forwarding (e.g. 
forwarding port 9876 on the webserver to 80 on the production machine). 
  Then set tcpwrappers to only allow localhost access to port 9876. 
That way your xml-rpc calls can go to localhost:9876...

You are now talking on a ssh-encrypted tunnel to the production machine.

Does that fit the bill?

-- Mitch

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

Message: 10
Date: Wed, 24 Mar 2004 10:07:43 -0500
From: Matthew Terenzio <webmaster at localnotion.com>
Subject: Re: [nycphp-talk] Secure (XML-RPC) connection
To: NYPHP Talk <talk at lists.nyphp.org>
Message-ID: <0056401B-7DA5-11D8-A2C6-0003938BDF32 at localnotion.com>
Content-Type: text/plain; charset=US-ASCII; format=flowed

I curious to see what others say, because I've never done this, 
exactly.  It sounds like a typical web service, but I'm not sure why it 
is needed to be done this way. With proper precaution, can't the web 
server just interact directly with the database through an SSL?

On Mar 24, 2004, at 9:24 AM, Faber Fedor wrote:

> I need some extra brains for a design I'm doing.  Since it's going to
> involve XML-RPC and PHP, I figured I'd ask here.
>
> I'm putting together a basic shopping cart.  I can't use existing
> solutions because the back end database is called jBASE (a variant of
> PICK). jBASE lives on the Production Server behind a LinkSys
> firewall/router.  The web site sits on the Web Server and is outside of
> the firewall. The plan so far is: user submits a request (places an
> order, wants to see Product ID# 1234, etc.) to the Web Server.  The Web
> Server does some PHP magic and sends the request to the Production
> Server via XML-RPC.  The Production Server does some (PHP?) magic and 
> hands
> the request to the database via CGI calls. When the Production Server
> responds, the process is reversed.
>
> I don't know how to do the XML-RPC magic above, but tht's part of the
> fun of the project.  What I Can't figure out is how to securely 
> transfer
> the data between the two servers. I need a secure connection from the
> Web Server, through the firewall to the Production Server that can't be
> cracked by script kiddies and the like. I tried setting up a VPN tunnel
> using FreeS/WAN And Openswan and I can't get them working after a week,
> so it's time to try something else.
>
> The client insists that this be done in real-time, so I can't have a
> copy of the database on the web server.
>
> Any ideas?
>
> -- 
>
> Regards,
>
> Faber
>
> Linux New Jersey: Open Source Solutions for New Jersey
> http://www.linuxnj.com
>
>
>
> _______________________________________________
> talk mailing list
> talk at lists.nyphp.org
> http://lists.nyphp.org/mailman/listinfo/talk


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

Message: 11
Date: Wed, 24 Mar 2004 10:12:21 -0500
From: Mitch Pirtle <mitchy at spacemonkeylabs.com>
Subject: Re: [nycphp-talk] Secure (XML-RPC) connection
To: NYPHP Talk <talk at lists.nyphp.org>
Message-ID: <4061A555.20402 at spacemonkeylabs.com>
Content-Type: text/plain; charset=us-ascii; format=flowed

Matthew Terenzio wrote:

> I curious to see what others say, because I've never done this, 
> exactly.  It sounds like a typical web service, but I'm not sure why it 
> is needed to be done this way. With proper precaution, can't the web 
> server just interact directly with the database through an SSL?

That's the first thing I do with a fresh PostgreSQL installation, at 
least if the webservers are on separate hardware :)

Another alarming phenomenon I have observed is the everything-or-nothing 
approach, where the whole shebang is either completely in the open, or 
they encrypt everything - even stuff that is then public on the website...

For XML-RPC I've only seen the SSL approach, is there a better practice 
for stuff like this?

-- Mitch

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

Message: 12
Date: Wed, 24 Mar 2004 10:37:33 -0500
From: Chris Bielanski <Cbielanski at inta.org>
Subject: RE: [nycphp-talk] Secure (XML-RPC) connection
To: 'NYPHP Talk' <talk at lists.nyphp.org>
Message-ID: <C0CDB9F5E81C234FBB42D84E7853125DC1B933 at intamail1.inta>
Content-Type: text/plain;	charset="iso-8859-1"

SSL is just the poor-man's VPN for these types of things. Honestly, if SSL
had not already proved sufficient in a large number of cases, someone would
have spoken up saying "Use XYZ..."

The only token of opinion I can offer up beyond that is to build an IPSEC
tunnel between a couple of W2K boxes. Seems to me that all that does is use
OS-native functionality to build a VPN instead of a hardware-based secure
tunnel.

~Chris

> -----Original Message-----
> From: Mitch Pirtle [mailto:mitchy at spacemonkeylabs.com]
> Sent: Wednesday, March 24, 2004 10:12 AM
> To: NYPHP Talk
> Subject: Re: [nycphp-talk] Secure (XML-RPC) connection
> 
> 
> Matthew Terenzio wrote:
> 
> > I curious to see what others say, because I've never done this, 
> > exactly.  It sounds like a typical web service, but I'm not 
> sure why it 
> > is needed to be done this way. With proper precaution, 
> can't the web 
> > server just interact directly with the database through an SSL?
> 
> That's the first thing I do with a fresh PostgreSQL installation, at 
> least if the webservers are on separate hardware :)
> 
> Another alarming phenomenon I have observed is the 
> everything-or-nothing 
> approach, where the whole shebang is either completely in the 
> open, or 
> they encrypt everything - even stuff that is then public on 
> the website...
> 
> For XML-RPC I've only seen the SSL approach, is there a 
> better practice 
> for stuff like this?
> 
> -- Mitch
> _______________________________________________
> talk mailing list
> talk at lists.nyphp.org
> http://lists.nyphp.org/mailman/listinfo/talk
> 

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

_______________________________________________
talk mailing list
talk at lists.nyphp.org
http://lists.nyphp.org/mailman/listinfo/talk


End of talk Digest, Vol 10, Issue 46
************************************


This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity to
which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified that
any dissemination, distribution or copying of this e-mail is prohibited. If
you have received this e-mail in error, please notify the sender by replying
to this message and delete this e-mail immediately.



More information about the talk mailing list