[Seaside] Re: [Pharo-project] Has anyone used Zodiac and Seaside to for https?

Sven Van Caekenberghe sven at stfx.eu
Thu Apr 18 20:23:53 UTC 2013


Hi there Mariano,

On 18 Apr 2013, at 22:03, Mariano Martinez Peck <marianopeck at gmail.com> wrote:

> Hi. Let's say I have a seaside running over HTTP with a ZnZincServerAdaptor. Is there a Zodiac adaptor I can use to have my seaside app running over HTTPS?
> 
> Thanks, 
> 
> -- 
> Mariano
> http://marianopeck.wordpress.com

This is Pharo Smalltalk, of course you can do that ;-)

The trick is to use #server: to give the adaptor a specific server instance to use, in this case a configured ZnSecureServer instance.

Something along these lines (I haven't actually tried it)

| httpsServer |

(httpsServer  := ZnSecureServer on: 1443)
	certificate: '/home/sven/ssl/key-cert.pem'.

ZnZincServerAdaptor default
	server: httpsServer;
	configureDelegate; 
	configureServerForBinaryReading;
	start.

You could best test the httpsServer on its own (you need to get the certificate right).
Problem is, this won't work on Mac OS X.

If you can't get it to work, let me know and I can try on a Linux machine (but not right away).

Sven

PS: Maybe ZnZincServerAdaptor>>#server: should send the 2 #configure messages itself, now that I look at it.

--
Sven Van Caekenberghe
Proudly supporting Pharo
http://pharo.org
http://association.pharo.org
http://consortium.pharo.org






More information about the seaside mailing list