Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 147921 - net-proxy/sshproxy-0.5.0 version bump
Summary: net-proxy/sshproxy-0.5.0 version bump
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: Gentoo Network Proxy Developers (OBSOLETE)
URL: http://penguin.fr/sshproxy/
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-09-17 05:54 UTC by David Guerizec
Modified: 2007-03-24 01:03 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
net-proxy/sshproxy-0.5.0_beta4.ebuild (sshproxy-0.5.0_beta4.ebuild,2.11 KB, text/plain)
2006-09-17 05:56 UTC, David Guerizec
Details
net-proxy/sshproxy/files/sshproxy.ini (sshproxy.ini,505 bytes, text/plain)
2006-09-17 05:56 UTC, David Guerizec
Details
net-proxy/sshproxy/files/sshproxyd.confd (sshproxyd.confd,197 bytes, text/plain)
2006-09-17 05:57 UTC, David Guerizec
Details
net-proxy/sshproxy/files/sshproxyd.initd (sshproxyd.initd,414 bytes, text/plain)
2006-09-17 05:58 UTC, David Guerizec
Details
net-proxy/sshproxy-backend-mysql/sshproxy-backend-mysql-0.5.0_beta4.ebuild (sshproxy-backend-mysql-0.5.0_beta4.ebuild,2.11 KB, text/plain)
2006-09-17 05:59 UTC, David Guerizec
Details
net-proxy/sshproxy-extra-plugins/sshproxy-extra-plugins-0.5.0_beta4.ebuild (sshproxy-extra-plugins-0.5.0_beta4.ebuild,768 bytes, text/plain)
2006-09-17 05:59 UTC, David Guerizec
Details
net-proxy/sshproxy-clients/sshproxy-clients-0.5.0_beta4.ebuild (sshproxy-clients-0.5.0_beta4.ebuild,778 bytes, text/plain)
2006-09-17 06:01 UTC, David Guerizec
Details
net-proxy/sshproxy/metadata.xml (metadata.xml,1.75 KB, text/plain)
2006-09-17 06:04 UTC, David Guerizec
Details
net-proxy/sshproxy/sshproxy-0.5.0_beta5.ebuild (sshproxy-0.5.0_beta5.ebuild,3.86 KB, text/plain)
2006-09-19 17:02 UTC, David Guerizec
Details
net-proxy/sshproxy-0.5.0.ebuild (sshproxy-0.5.0.ebuild,4.36 KB, text/plain)
2006-09-26 03:02 UTC, David Guerizec
Details
/sshproxy-0.5.0.ebuild (sshproxy-0.5.0.ebuild,4.66 KB, text/plain)
2006-09-26 16:02 UTC, Alin Năstac (RETIRED)
Details
sshproxy.ini (sshproxy.ini,500 bytes, text/plain)
2006-09-26 16:03 UTC, Alin Năstac (RETIRED)
Details
sshproxyd.initd (sshproxyd.initd,444 bytes, text/plain)
2006-09-26 16:03 UTC, Alin Năstac (RETIRED)
Details
sshproxy-0.5.0.ebuild (sshproxy-0.5.0.ebuild,4.84 KB, text/plain)
2006-09-27 13:07 UTC, David Guerizec
Details

Note You need to log in before you can comment on or make changes to this bug.
Description David Guerizec 2006-09-17 05:54:07 UTC
New ebuilds for net-proxy/sshproxy-0.5.0_beta4

sshproxy can now be modular, so there are now 4 related ebuilds:

sshproxy
sshproxy-backend-mysql
sshproxy-extra-plugins
sshproxy-clients
Comment 1 David Guerizec 2006-09-17 05:56:00 UTC
Created attachment 97234 [details]
net-proxy/sshproxy-0.5.0_beta4.ebuild

This is the main ebuild
Comment 2 David Guerizec 2006-09-17 05:56:52 UTC
Created attachment 97235 [details]
net-proxy/sshproxy/files/sshproxy.ini

The default configuration file for sshproxy
Comment 3 David Guerizec 2006-09-17 05:57:38 UTC
Created attachment 97236 [details]
net-proxy/sshproxy/files/sshproxyd.confd

The conf.d configuration file for sshproxyd
Comment 4 David Guerizec 2006-09-17 05:58:12 UTC
Created attachment 97237 [details]
net-proxy/sshproxy/files/sshproxyd.initd

the init.d stratup script for sshproxyd
Comment 5 David Guerizec 2006-09-17 05:59:06 UTC
Created attachment 97238 [details]
net-proxy/sshproxy-backend-mysql/sshproxy-backend-mysql-0.5.0_beta4.ebuild

the optional mysql backend for sshproxy
Comment 6 David Guerizec 2006-09-17 05:59:57 UTC
Created attachment 97239 [details]
net-proxy/sshproxy-extra-plugins/sshproxy-extra-plugins-0.5.0_beta4.ebuild

A few optional plugins for sshproxy
Comment 7 David Guerizec 2006-09-17 06:01:48 UTC
Created attachment 97240 [details]
net-proxy/sshproxy-clients/sshproxy-clients-0.5.0_beta4.ebuild

The two client scripts pssh and pscp to connect to sshproxy
Comment 8 David Guerizec 2006-09-17 06:04:37 UTC
Created attachment 97242 [details]
net-proxy/sshproxy/metadata.xml

The metadata.xml file has not changed since version 0.4.x

Question: do I have to make a different metadata.xml for each ebuild, or is it OK to copy this one in other sshproxy-* ebuilds ?
Comment 9 Jakub Moc (RETIRED) gentoo-dev 2006-09-17 06:06:00 UTC
We don't need metadata.xml
Comment 10 David Guerizec 2006-09-18 15:51:35 UTC
I have the version 0.5.0-beta5 available, due to a minor security bug.

Do I need to open a new ticket for that, or can I post here the new ebuilds ?

They are not much different, only sshproxy-extra-plugins include a new plugin.

Thanks.
Comment 11 Alin Năstac (RETIRED) gentoo-dev 2006-09-18 23:38:20 UTC
Note: Please don't attach anything that hasn't changed.

Sorry but I see no reason for breaking sshproxy into 2 ebuilds. The "extra-plugins" ebuild install just 2 small bash scripts! Please attach the diff of the new ebuild if that is the case.

Other thing I want you to reconsider is dropping root privileges using setuid(). You really don't need to commute to root beside listen(). It would increase users security tremendously.
Comment 12 Alin Năstac (RETIRED) gentoo-dev 2006-09-18 23:42:21 UTC
Ah, it isn't extra-plugins the one that install just 2 bash script... 
Anyway, please unify these 2 ebuilds and consider using USE flags (preferably the global ones) for enabling installation of the optional parts.
Comment 13 David Guerizec 2006-09-19 17:02:23 UTC
Created attachment 97474 [details]
net-proxy/sshproxy/sshproxy-0.5.0_beta5.ebuild

New unified ebuild for beta5

sshproxy-clients has its own package, because there is no relation (dependency) with the server package.
Comment 14 David Guerizec 2006-09-19 17:05:57 UTC
(In reply to comment #11)
> Other thing I want you to reconsider is dropping root privileges using
> setuid(). You really don't need to commute to root beside listen(). It would
> increase users security tremendously.

This has been done in the git tree, and will be available in the next release.

Thanks for the advice.

Comment 15 Alin Năstac (RETIRED) gentoo-dev 2006-09-21 02:28:01 UTC
(In reply to comment #13)
> sshproxy-clients has its own package, because there is no relation (dependency)
> with the server package.

If you consider those 2 scripts as being part of another package, you should break the tarball in 2, the clients part having its own versioning scheme.
But I really don't want to submit yet another a-couple-of-scripts package into the tree!

Please make installation of the client scripts USE flag dependent. If you ask me, I would choose 2 local USE flag, one for client and the other for server. If neither is set, I would install both client & server.
Comment 16 David Guerizec 2006-09-23 05:38:30 UTC
(In reply to comment #15)
> If you consider those 2 scripts as being part of another package, you should
> break the tarball in 2, the clients part having its own versioning scheme.
> But I really don't want to submit yet another a-couple-of-scripts package
> into the tree!

What is the reason to be reluctant ?

> Please make installation of the client scripts USE flag dependent. If you ask
> me, I would choose 2 local USE flag, one for client and the other for server.
> If neither is set, I would install both client & server.

Can you provide me with an example package that does this ?

I'm sorry if I seem anal, but I don't see the point of having all in the same package, since there is clearly a server part, and a client one (which, I aggree, is only two shell wrappers around ssh for the moment).
In a production environment, the clients don't need to be installed on the server, so I see two different packages.

Please explain me your point.

David
Comment 17 Alin Năstac (RETIRED) gentoo-dev 2006-09-23 11:09:09 UTC
(In reply to comment #16)
> What is the reason to be reluctant ?

a) sshproxy-clients updates will be pointless. I think it is safe to say that those scripts will remain the same for all server versions.
b) users don't really need these scripts to connect to a proxy since all they do is building a ssh command lines from environment variables that were set by the user anyway.
c) the user must download the entire tarball just for installing 2 scripts which might fit very well in FILESDIR.

> Can you provide me with an example package that does this ?

Let me ask you another question. Can you give me an example of package foobar that have a corespondent foobar-clients ? Surely not packages like openssh or mysql, that's for sure.

> I'm sorry if I seem anal, but I don't see the point of having all in the same
> package, since there is clearly a server part, and a client one (which, I
> aggree, is only two shell wrappers around ssh for the moment).
> In a production environment, the clients don't need to be installed on the
> server, so I see two different packages.

Yes, those scripts aren't necessary on the server, but most server packages install client counterparts. Besides, what would be so wrong in installing them?

Personally, I would use these flags:
 - clientscripts - Install client scripts only
 - mysql - obvious
 - minimal

If you still insist in making 2 ebuilds, then I suggest to break the tarball in 2, representing packages with distinct versioning scheme.
Comment 18 David Guerizec 2006-09-26 03:02:44 UTC
Created attachment 98107 [details]
net-proxy/sshproxy-0.5.0.ebuild

This is the unified ebuild, as requested.

Note that the version is now 0.5.0

Thanks
Comment 19 Alin Năstac (RETIRED) gentoo-dev 2006-09-26 16:02:26 UTC
Created attachment 98179 [details]
/sshproxy-0.5.0.ebuild

Thank you for understanding!

I've made a series of improvements:
 - replaced clientsonly with client-only
 - moved logs in /var/log/sshproxy
 - fix dependencies
 - quote variables that may contain spaces
 - parameterize mysql host and port
 - add "use mysq" in init script
 - set hostname in pkey_id
 - cosmetic code style changes

I have a problem though, when I try to setup the proxy on a MySQL backend. The command "sshproxy-setup -c /etc/sshproxy -u sshproxy --add-admin mrness" don't have any effect on the MySQL database! Nothing appears in log files (beside loaded plugin lines, of course).
Do you have any idea what could be the cause of this behaviour?
Comment 20 Alin Năstac (RETIRED) gentoo-dev 2006-09-26 16:03:03 UTC
Created attachment 98180 [details]
sshproxy.ini
Comment 21 Alin Năstac (RETIRED) gentoo-dev 2006-09-26 16:03:34 UTC
Created attachment 98181 [details]
sshproxyd.initd
Comment 22 David Guerizec 2006-09-27 13:07:45 UTC
Created attachment 98257 [details]
sshproxy-0.5.0.ebuild

There was a little bug in the ebuild.

If mysql is used, we have to load the mysql_db plugin.
I'll fix that in the code in the next release, but for now, it works with this ebuild.

Thanks for your work!
Comment 23 Alin Năstac (RETIRED) gentoo-dev 2006-09-28 01:34:08 UTC
fixed in cvs. good job!

P.S. The secrets are now set to a hexadecimal number composed by 16 digits.
Comment 24 Wolfram Schlich (RETIRED) gentoo-dev 2006-10-13 03:53:06 UTC
hmm, I just installed sshproxy-0.5.0 with USE="mysql".

afterwards, I ran "emerge --config =net-proxy/sshproxy-0.5.0" just as
the ebuild suggested.

this appears:
--8<--
Configuring pkg...

Enter the MySQL host (default localhost):
Enter the MySQL port (default 3306):
 * When prompted for a password, enter your MySQL root password
 *
Enter password:
--8<--

I entered the password and the setup script hangs.

The MySQL database 'sshproxy' and the tables were successfully created
though.

An strace of the running process only shows this:
--8<--
12:47:17.527762 read(0,
--8<--
The process in question is
"/usr/bin/python /usr/bin/sshproxy-setup -u sshproxy -c /etc/sshproxy".

Oh, I just pressed 'Enter' 8 times in a row and some menu appeared... but
it is somewhat "broken".

Running "/usr/bin/sshproxy-setup -u sshproxy -c /etc/sshproxy" manually
works fine.
Comment 25 Wolfram Schlich (RETIRED) gentoo-dev 2006-10-13 04:16:34 UTC
Also, sshproxy does not come with *any* manual pages or other documentation
regarding /etc/sshproxy/sshproxy.ini :-((( This is *really* bad.
Even http://penguin.fr/sshproxy/wiki/SshProxy/DocV0.5 does not
explain pkey_id and auto_add_key (yes, that is an upstream problem, but as
upstream is subscribed to this bug... ;)).
Comment 26 Alin Năstac (RETIRED) gentoo-dev 2006-10-13 04:24:51 UTC
(In reply to comment #24)

Strange, it worked for me just fine. I will have to re-test it.
Comment 27 Alin Năstac (RETIRED) gentoo-dev 2006-10-13 10:17:59 UTC
Wolfram, I cannot reproduce it, even if I reinstall it like this:
  emerge -C sshproxy && rm -r /var/*/sshproxy /etc/sshproxy && emerge sshproxy && emerge --config sshproxy
Comment 28 Wolfram Schlich (RETIRED) gentoo-dev 2006-10-16 14:24:15 UTC
I experience this on 2 different machines:

Portage 2.1.1_pre4-r3 (default-linux/x86/2006.1/server, gcc-vanilla, glibc-2.3.6-r4, 2.6.16-gentoo-r8 i686)

Portage 2.1.2_pre2-r9 (hardened/x86/2.6, gcc-3.3.6, glibc-2.3.5-r2, 2.6.14.7-grsec-2.1.8 i686)
Comment 29 David Guerizec 2006-10-24 03:43:09 UTC
(In reply to comment #25)
> Also, sshproxy does not come with *any* manual pages or other documentation
> regarding /etc/sshproxy/sshproxy.ini :-((( This is *really* bad.
> Even http://penguin.fr/sshproxy/wiki/SshProxy/DocV0.5 does not
> explain pkey_id and auto_add_key (yes, that is an upstream problem, but as
> upstream is subscribed to this bug... ;)).

I plaid guilty about the man pages, and I will add them in the next release.
For explanations about pkey_id and auto_add_key, you have them in the menu of sshproxy-setup, when you select them in the interface:

Public key id string
====================

Enter the public key id string used to identify the proxy public key that can be put in a remote .ssh/authorized_keys file. This is typically in the form of an email address.

Public key id string [sshproxy@penguin.fr]

Auto-add public key
===================

If you want the auto-add-key feature, enter here the number of keys auto-added in the client keyring, or 'yes' for no limit. Saying 'no' disable this feature.
Attention: this feature, if enabled, can be dangerous.

Auto-add public key [no]

But I should (will) probably add a paragraph in the documentation.

Thanks for reporting.

David
Comment 30 David Guerizec 2006-10-24 03:46:26 UTC
> Oh, I just pressed 'Enter' 8 times in a row and some menu appeared... but
> it is somewhat "broken".
> 
> Running "/usr/bin/sshproxy-setup -u sshproxy -c /etc/sshproxy" manually
> works fine.

What shell/term combination are you using ?
Can you test and confirm (or infirm) that the bug occurs also with bash/konsole ? 

Comment 31 Wolfram Schlich (RETIRED) gentoo-dev 2006-10-24 04:40:22 UTC
(In reply to comment #29)
> (In reply to comment #25)
> > Also, sshproxy does not come with *any* manual pages or other documentation
> > regarding /etc/sshproxy/sshproxy.ini :-((( This is *really* bad.
> > Even http://penguin.fr/sshproxy/wiki/SshProxy/DocV0.5 does not
> > explain pkey_id and auto_add_key (yes, that is an upstream problem, but as
> > upstream is subscribed to this bug... ;)).
> 
> I plaid guilty about the man pages, and I will add them in the next release.

Great, thanks!

> For explanations about pkey_id and auto_add_key, you have them in the menu of
> sshproxy-setup, when you select them in the interface:

Well, not the best place for documentation I believe ;)

> Public key id string
> ====================
> 
> Enter the public key id string used to identify the proxy public key that can
> be put in a remote .ssh/authorized_keys file. This is typically in the form of
> an email address.
> 
> Public key id string [sshproxy@penguin.fr]

That's unclear :(
Where does the sshproxy daemon get the corresponding key from?
From the homedir of the sshproxy daemon user?
Where does it have to reside?
Also, ssh public keys have just *comments*, mostly in the form of an e-mail address, but not necessarily. Next, such comments cannot be used
to identify keys. Instead, fingerprints should be used.
But anyway, I don't see why one should not instead specify a full path to the
private key in the config. which looks like the best solution to me.

> Auto-add public key
> ===================
> 
> If you want the auto-add-key feature, enter here the number of keys auto-added
> in the client keyring, or 'yes' for no limit. Saying 'no' disable this feature.
> Attention: this feature, if enabled, can be dangerous.
> 
> Auto-add public key [no]

What does this mean?
It's unclear.
Does it mean remote SSH host public keys, that are usually added to ~/.ssh/known_hosts?

Please, improve the docs -- I am unable to use sshproxy right now
because I don't understand how it works :(

> Thanks for reporting.

np :-)
Comment 32 David Guerizec 2006-10-24 05:12:23 UTC
(In reply to comment #31)
> Please, improve the docs -- I am unable to use sshproxy right now
> because I don't understand how it works :(

May I ask you to ask your questions and continue this discution on the sshproxy@penguin.fr mailing list, so that all users can benefit the answers?

I take your comments as a valuable contribution.
Thank you.
Comment 33 Wolfram Schlich (RETIRED) gentoo-dev 2006-10-24 07:18:14 UTC
(In reply to comment #30)
> > Oh, I just pressed 'Enter' 8 times in a row and some menu appeared... but
> > it is somewhat "broken".
> > 
> > Running "/usr/bin/sshproxy-setup -u sshproxy -c /etc/sshproxy" manually
> > works fine.
> 
> What shell/term combination are you using ?
> Can you test and confirm (or infirm) that the bug occurs also with bash/konsole
> ? 

the client runs KDE and Konsole in a UTF-8 environment, logged in via SSH to the 2 mentioned machines (also UTF-8), "emerge --config sshproxy" running inside screen.

Comment 34 David Guerizec 2006-10-24 09:49:43 UTC
OK, I can reproduce it. I still don't know why, though...

Comment 35 Wolfram Schlich (RETIRED) gentoo-dev 2007-03-24 01:03:34 UTC
David, any news? :)