Bug 7859 - hsftp is a SSH connection with ftp functions - it is an old Mandrake package and it lets you "get" and "put" files from remote locations
Summary: hsftp is a SSH connection with ftp functions - it is an old Mandrake package ...
Status: RESOLVED WORKSFORME
Alias: None
Product: Mageia
Classification: Unclassified
Component: New RPM package request (show other bugs)
Version: Cauldron
Hardware: i586 Linux
Priority: Normal normal
Target Milestone: ---
Assignee: Mageia Bug Squad
QA Contact:
URL: http://bjoernvold.com/forum/viewtopic...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-10-21 14:33 CEST by thomas bjo
Modified: 2012-10-22 19:18 CEST (History)
1 user (show)

See Also:
Source RPM: http://distrib-coffee.ipsl.jussieu.fr/pub/linux/MandrivaLinux/official/2010.2/i586/media/contrib/release/hsftp-1.15-3mdv2009.0.i586.rpm
CVE:
Status comment:


Attachments

Description thomas bjo 2012-10-21 14:33:55 CEST
Description of problem:


hsftp is brilliant for servers or transfering files via CLI.
Normally you have to do a:
.......
scp berserk@viking-pc:/home/berserk/berserkfiles/document.txt ~/berserkfiles/document.txt
......
To copy FROM a remote location and

..............
scp ~/berserkfiles/document.txt berserk@remote-pc:~/berserkfiles/document.txt
..........
To copy TO a remote location

With hsftp you use it instead of SSH to connect and simply use: put/get document.txt  
It will put/get the document to the active directory.
Comment 1 Shlomi Fish 2012-10-21 15:14:35 CEST
I guess we can package it, but what is wrong with:

1. lftp over the sftp:// protocol.

2. The FISH protocol, supported by konqueror, and other file managers.

Regards,

-- Shlomi Fish

CC: (none) => shlomif

Comment 2 thomas bjo 2012-10-21 21:11:06 CEST
I can connect with lftp in CLI but then I always get a 30 second countdown - Before it fails - that seems wrong with lftp.
But it looks interesting.
Comment 3 thomas bjo 2012-10-21 21:17:43 CEST
Actually I got it working now - and the big difference is that hsftp has normal Linux syntax so I can use ls instead of !ls
Comment 4 thomas bjo 2012-10-21 21:30:38 CEST
...And you can change directory in hsftp I have been unable to manage that in lftp.
Comment 5 Shlomi Fish 2012-10-22 10:26:12 CEST
(In reply to comment #4)
> ...And you can change directory in hsftp I have been unable to manage that in
> lftp.

From man lftp:

       lcd ldir

       Change current local directory ldir. The previous  local  directory  is
       stored as `-'. You can do `lcd -' to change the directory back.

       cd rdir

       Change current remote directory.   The  previous  remote  directory  is
       stored  as  `-'.  You  can do `cd -' to change the directory back.  The
       previous directory for each site is also stored on disk, so you can  do
       `open site; cd -' even after lftp restart.
Comment 6 thomas bjo 2012-10-22 12:51:00 CEST
Ok thanks! It can pretty much do the same as hsftp with it then, but the obvious advantage of hsftp is that you do not have to learn a different syntax.
So I can do a cd Documents instead of lcd lDocuments.
In fact the command that works is lcd Documents (not lDocuments).

lftp has some instances with prepending ! and some with l - I am sure it is all explained - but it sure does not beat the familiar syntax.

So hsftp is easier to use and easier to understand :) 
That might be a good reason for a user-friendly! distro IMHO. 

As a final example to get a file from the remote box I need to do a

<rfile> and store it to local file <lfile>.
(I never got it to work)

in hsftp you do a <get file> (no "l" or "r") and it will be automatically stored in your current directory on your box.

(you can specify and make it more complicated - but there is no need)

So far that is the answer to "What is wrong with lftp"
Comment 7 Shlomi Fish 2012-10-22 13:38:35 CEST
Hi thomas,

well, I tried building the old Mandriva hsftp package, and ran into a few problems:

gcc -DHAVE_CONFIG_H -DPACKAGE=\"hsftp\" -DVERSION=\"1.15\" -I. -I.    -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fPIC  -o hsftp.o -c ./hsftp.c
gcc -DHAVE_CONFIG_H -DPACKAGE=\"hsftp\" -DVERSION=\"1.15\" -I. -I.    -O2 -g -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fPIC  -o piper.o -c ./piper.c
./hsftp.c: In function âmainâ:
./hsftp.c:1236:7: error: format not a string literal and no format arguments [-Werror=format-security]
./piper.c: In function ârestore_ttyâ:
./piper.c:357:8: warning: ignoring return value of âchownâ, declared with attribute warn_unused_result [-Wunused-result]
./hsftp.c:1426:11: warning: ignoring return value of âsystemâ, declared with attribute warn_unused_result [-Wunused-result]
cc1: some warnings being treated as errors
make: *** [hsftp.o] Error 1
make: *** Waiting for unfinished jobs....
error: Bad exit status from /var/tmp/rpm-tmp.oI6kpZ (%build)

I don't feel motivated enough to fix it, so if you want hsftp in Mageia, you'll need to provide me with an up-to-date package with all these patches. Or install hsftp from source or just use lftp. It seems that hsftp has not been maintained since at least 2006, and that the source distribution lacks a changes-log, an INSTALL file and other files that are common in other quality source packages. So I don't feel confident in packaging it.

Regards,

-- Shlomi Fish
Comment 8 thomas bjo 2012-10-22 14:45:26 CEST
OK I undertstand.
Here is a package that should have been maintained in 2008
http://distrib-coffee.ipsl.jussieu.fr/pub/linux/MandrivaLinux/official/2011/i586/media/contrib/release/hsftp-1.15-3mdv2009.0.i586.rpm

But it will not work out of the box either. 
We can live with lftp I guess.
thomas bjo 2012-10-22 19:18:47 CEST

Status: NEW => RESOLVED
Resolution: (none) => WORKSFORME


Note You need to log in before you can comment on or make changes to this bug.