vBulletin Search Engine Optimization
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| On Apr 24, 3:04 am, bco...@example.com wrote: > In article <fukbc8$mej$1$8300d...@news.demon.co.uk>, Julian Brett wrote: > > Hi all. > > > I'm attempting to script an FTP transfer on my UnixWare 7.1.4 server. I've > > written numerous FTP transfer scripts before, but haven't really approached > > it this way. > > This sort of thing in a script file has always worked for me > under various unixen: > > cd_dir="somedir" > file="somefile.txt" > user="myusername" > host="myhost.com" > echo -n "Password for ${user} at ${host}: " > read pass > > echo " > open ${host} > user ${user} ${pass} > #passive > bin > hash > prompt > cd ${cd_dir} > pwd > ls > chmod 700 * > mdele * > put ${file} > chmod 000 * > ls > " | ftp -n Really? And how do you know when it fails and WHERE it failed? You don't, and that's why I recommend doing this with Perl. It's easy (I have sample scripts at the links I gave above) and you have total control of errors.. |
| |||
| Joe Dunning wrote: > > > On Tue, 22 Apr 2008, ThreeStar wrote: > >> >> Better security is better, even if it's not the best security >> (whatever that means). SCP fits the simple scenario the poster laid >> out, and avoids sending login credentials over the Internet in clear >> text like FTP does. > > There are FTP implementations available that support encryption. They > won't work through many firewalls, but as long as only one end has an > external firewall, they can be used. Most of them are not, in fact, FTP. 'sftp' is one such, and it's basically SCP with an interface, suffering most of the flaws of SCP and rcp access. The interface is far less flexible than FTP, it normally has no chroot capability and thus no way to restrict clients from browsing the rest of the filesystem, and it mishandles symlinks. These are reasons that I like WebDAV over HTTPS: it has most if not all of the features of FTP, it runs on the HTTPS port, and is easily implemented with a basic Apache installation with a great deal of flexibility. |
| |||
| In article <7f8d4cf6-5438-46b4-8b2d-00f17f53f84d@c65g2000hsa.googlegroups.com>, Tony Lawrence wrote: > On Apr 24, 3:04 am, bco...@example.com wrote: >> put ${file} >> chmod 000 * >> ls >> " | ftp -n > > Really? And how do you know when it fails and WHERE it failed? > Your right. This is only usefull as a quick and dirty one time script. Its not secure and adding any sort of robust error checking turns the simple script into something complicated enought that something like Perl quickly becomes the better solution. However, that said, sometimes one really wants or needs to do FTP and this is simple enough to remember and just type in. |
| ||||
| On Sat, 26 Apr 2008, Nico Kadel-Garcia wrote: > Joe Dunning wrote: >> >> >> On Tue, 22 Apr 2008, ThreeStar wrote: >> >> > >> > Better security is better, even if it's not the best security >> > (whatever that means). SCP fits the simple scenario the poster laid >> > out, and avoids sending login credentials over the Internet in clear >> > text like FTP does. >> >> There are FTP implementations available that support encryption. They >> won't work through many firewalls, but as long as only one end has an >> external firewall, they can be used. > > Most of them are not, in fact, FTP. Most, maybe. However, on my Gentoo boxes, FTP (net-ftp/ftp) is built with SSl support. However, this can be problematic, because, if one needs the NAT firewall to react properly to the ftp commands going across the firewall, it won't happen with an encrypted session. |