README for SOCKS module for python interpreter
==============================================

  Daniel W. Connolly, HaL Software Systems <connolly@hal.com>

  $Id: README,v 1.5 1994/07/08 00:38:15 connolly Exp $

What Is socksForPython?
-----------------------

  This is a python module that works just like the socket module, but
  uses the SOCKS protocol to make connections through a firewall
  machine. See README.socks for more info on SOCKS.

  This has been tested with
* python 1.0.1, python 1.0.2	
* Beta release of version 4.2 of SOCKS.CSTC, dated March 21, 1994
* gcc  2.5.8
* SunOS 4.1.3

How Do I Build/Install/Use it?
------------------------------

* Download
  http://www.hal.com/%7Econnolly/dist/socksForPython-19940707.tar.gz_
  (Mosaic users: use "Load to local Disk")

* Get and build python_

* Get and build SOCKS
  ( I can't seem to find version 4.2 source through archie.
    Perhaps the author <ylee@syl.dl.nec.com> could help.
    Perhaps version 4.1 would be enough for your purposes.
    Archie lists
    ftp://arthur.cs.purdue.edu/pub/pcert/tools/unix/socks.cstc.4.1.tar.gz_
    size: 227733 date: Dec 16 00:00 among others)

* Put this directory in the python source tree under python/Extensions

* Edit the Makefile to point to your python and SOCKS installations

* If you're using SunOS 4.1.3 and you have gcc installed, you can
  build a dynamically linked module. Just invoke 'make' and you'll end
  up with SOCKSmodule.so . Put that in your $PYTHONPATH, and you're
  all set. (This might work for other platforms too, but I have no way
  to find out!)

* Otherwise, you can build socksmodule.o and link it into the
  interpreter using the normal python Extensions mechanism.
  See Makefile.pre.in for details.

* Set up the SOCKS server, and set your ~$SOCKS_SERVER~ appropriately
  (I assume you or somebody at your site knows how to set up the
  socks server, or you wouldn't be interested in this package in
  the first place.)

* To use the SOCKS module in python code, I just replace:

	import socket

  with

	try:
		import SOCKS; socket = SOCKS
	except ImportError:
		import socket

* included is a patch to ftplib.py that will make it (1) import SOCKS
  as above, and (2) set up the data connection in a way that SOCKS can
  handle.


Bugs/Limitations
----------------

  Note that SOCKS makes some assumptions about the way the socket
  library is used. See ~What_SOCKS_expects~.

  XXX socksmodule.c should be tweaked to raise exceptions for things
  that SOCKS doesn't support.


Copyright Info
--------------

  Technically speaking, this is copyright (c) 1994 by HaL Computer
  Systems, since I developed it using their resources. There's so
  little novel work here that I don't see the point in reserving any
  copyrights. Anyway...

  Copyright 1994 by HaL Computer Systems.

                        All Rights Reserved

  Permission to use, copy, modify, and distribute this software and
  its documentation for any purpose and without fee is hereby granted,
  provided that the above copyright notice appear in all copies and
  that both that copyright notice and this permission notice appear in
  supporting documentation, and that the names of HaL Computer Systems
  not be used in advertising or publicity pertaining to distribution
  of the software without specific, written prior permission.

  HAL COMPUTER SYSTEMS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS
  SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
  FITNESS, IN NO EVENT SHALL HAL COMPUTER SYSTEMS BE LIABLE FOR ANY
  SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER
  RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF
  CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
  CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.


.. References:
.. _python http://www.cwi.nl/ftp/python/index.html
..   or use archie to find python.*.tar.gz
..
