[PD-dev] allow to connect to remote host: ./pd-gui.tcl [[<host>:]<port>]

IOhannes m zmoelnig zmoelnig at iem.at
Tue Jan 12 09:31:41 CET 2010


Hans-Christoph Steiner wrote:
> 
> Hey IOhannes,
> 
> http://pure-data.svn.sourceforge.net/viewvc/pure-data?view=rev&revision=12956
> 
> 
> Just checking out your commits.  The ./pd-gui.tcl [[<host>:]<port>]

thanks

> stuff looks interesting, but your commit removed that stringent test,

i hope it did not remove any stringent text.
the patch will only take effect, if there is _exactly_ a single argument
and this argument is either
- exactly an integer (<port>)
- or exactly a something followed by a ":" followed by an integer

so the only relaxation of tests i did was:
- remove the "5400" barrier for ports (what was that for?)
- additionally allow the number to be prefixed by a word ending with a
colon.

> which might be needed if "wish pd-gui.tcl" is going to be able to handle
> command line args like -stderr -open -verbose, etc.  

i have tested (see bug #2929975) and things like "wish ./pd-gui.tcl
-stderr delme.pd" still works as expected.
also "./pd-gui.tcl delme.pd" does what it should.

you cannot open patches named "localhost:5400" (in theory you should, by
using the "-open localhost:5400" syntax; but it seems like this triggers
an unrelated check (for .pd suffix?) which prevents opening a so-named file)

> Just something to
> test and look out for.

sure.

> 
> Also, what are the security implecations of this?

hmm, i think the implication is, that pd-gui can now be used to lauch a
DoS attack, simply by starting a lot of pd-gui's connecting to a remote
host.
apart from that, it brings back functionality lost during the rewrite:
the old Pd-Gui could be started as
./pd-gui 5600 remotehost
which would connect to remotehost:5600

the new syntax "./pd-gui remotehost:5600" is afaict more readable to
anybody who has ever worked with a networking app on the console.

i "heavily" use (read: rely on) this feature for peerdata.

fgamsr
IOhannes
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3636 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://lists.puredata.info/pipermail/pd-dev/attachments/20100112/2bf00c17/attachment.bin>


More information about the Pd-dev mailing list