threads / discuss / 19167

[gitosis] unexpected error for a warning msg

Subject: [gitosis] unexpected error for a warning msg

## tl;dr

2 messages between May 3, 2009 and May 3, 2009.

replies: 1people: 2as markdown or json

Nicolas Sebrecht· May 3, 2009, 23:23 UTC · lore
Hi,

I had the following issue using gitosis today: http://colabti.org/irclogger/irclogger_log/git?date=2009-05-03#l2233

The name of the key file was 'keydir/Jacques@BLACK_ANTEC.pub' which gave the warning (when pushing): WARNING:gitosis.ssh:Unsafe SSH username in keyfile: Jacques@BLACK_ANTEC.pub

Changing the filename into Jacques.pub solved the issue.

I was expecting an error message instead (not a warning) as it seems to _not_ permit such a filename.

Why the initial filename is fobidden? Could the warning be substituted by an error?

Thanks,
-- 
Nicolas Sebrecht
Robin H. Johnson· May 3, 2009, 23:54 UTC · re: Nicolas Sebrecht · lore

Re: [gitosis] unexpected error for a warning msg

On Mon, May 04, 2009 at 01:23:00AM +0200, Nicolas Sebrecht wrote:
Show 14 quoted lines
> I had the following issue using gitosis today:
> http://colabti.org/irclogger/irclogger_log/git?date=2009-05-03#l2233
> 
> The name of the key file was 'keydir/Jacques@BLACK_ANTEC.pub' which gave
> the warning (when pushing): 
> WARNING:gitosis.ssh:Unsafe SSH username in keyfile: Jacques@BLACK_ANTEC.pub
> 
> Changing the filename into Jacques.pub solved the issue.
> 
> I was expecting an error message instead (not a warning) as it seems to
> _not_ permit such a filename.
> 
> Why the initial filename is fobidden?
> Could the warning be substituted by an error?
They are meant to be valid usernames, which don't include the @ symbol.

For the git.overlays.gentoo.org site, where we use gitosis, we had some issues that were best solved by fixing Gitosis itself (like being able to pass SSH key options, eg "from=" to restrict hosts). Another one that bugged me was that the string at the end of an ssh key is NOT a username, it's a freeform (well, no newline) text field.

I've tried to send the patches to upstream on several occasions, but never gotten any response.

I didn't disable the warning you're complaining about, as I wanted it still, but I do agree it's probably better to upgrade to an error.

You can find the Gentoo fork here: http://git.overlays.gentoo.org/gitweb/?p=proj/gitosis-gentoo.git;a=summary

-- 
Robin Hugh Johnson
Gentoo Linux Developer & Infra Guy
E-Mail     : robbat2@gentoo.org
GnuPG FP   : 11AC BA4F 4778 E3F6 E4ED  F38E B27B 944E 3488 4E85

← back to recent threads