[opensuse-buildservice] Keyring support in osc
Hi some time ago I wrote a patch for storing osc credentials in Gnome keyring instead of ~/.oscrc. It uses keyring only if available otherwise it falls back to using configuration file. Any comments on committing this into svn? The patch is available in bugzilla: https://bugzilla.novell.com/show_bug.cgi?id=460540 -- Michal Čihař | http://cihar.com | http://blog.cihar.com
Hi, On 2009-05-07 10:25:55 +0200, Michal Čihař wrote:
some time ago I wrote a patch for storing osc credentials in Gnome keyring instead of ~/.oscrc. It uses keyring only if available otherwise it falls back to using configuration file.
Any comments on committing this into svn?
The patch is available in bugzilla: https://bugzilla.novell.com/show_bug.cgi?id=460540
I thought about this patch for some time. Overall the patch looks good to me but "design wise" I'm a bit hesitant. There might be someone who wants support for kwallet or another password manager so he adds his kwallet specific code to the conf.py module. So it might be a good idea to add something like a base class for all these user/password stuff, e.g. class OscPasswdMgr(): def getUser(...) def setUser(...) etc. class OscGnomeKeyring(OscPasswdMgr): ... This way we would have a "clean" conf.py. This might be something for the future... feel free to commit your patch (at least there are no objections from my side:) ). Marcus -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-buildservice+help@opensuse.org
2009/5/7 Marcus Hüwe
Hi,
On 2009-05-07 10:25:55 +0200, Michal Čihař wrote:
some time ago I wrote a patch for storing osc credentials in Gnome keyring instead of ~/.oscrc. It uses keyring only if available otherwise it falls back to using configuration file.
Any comments on committing this into svn?
The patch is available in bugzilla: https://bugzilla.novell.com/show_bug.cgi?id=460540
I thought about this patch for some time. Overall the patch looks good to me but "design wise" I'm a bit hesitant. There might be someone who wants support for kwallet or another password manager so he adds his kwallet specific code to the conf.py module. So it might be a good idea to add something like a base class for all these user/password stuff, e.g. class OscPasswdMgr(): def getUser(...) def setUser(...) etc. class OscGnomeKeyring(OscPasswdMgr): ...
This way we would have a "clean" conf.py. This might be something for the future... feel free to commit your patch (at least there are no objections from my side:) ).
This is not more simply to crypt/decrypt password before read/write password in ~/.oscrc , like i do in MonoOSC ?
Marcus -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-buildservice+help@opensuse.org
-- Cordially. Small Eric Quotations of the days: --------------------------------------------------------------------------- If one day one reproaches you that your work is not a work of professional, say you that: Amateurs built the arch of Noah, and professionals the Titanic. --------------------------------------------------------------------------- Few people are done for independence, it is the privilege of the powerful ones. --------------------------------------------------------------------------- No key was wounded during the drafting of this message. -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-buildservice+help@opensuse.org
Hi
Dne Thu, 7 May 2009 11:06:59 +0200
Petit Eric
This is not more simply to crypt/decrypt password before read/write password in ~/.oscrc , like i do in MonoOSC ?
What you mean by crypt/decrypt? Some text mangling? Well it does not change much to current situation. While using some keyring manager passwords are stored safely. -- Michal Čihař | http://cihar.com | http://blog.cihar.com
Am Donnerstag, 7. Mai 2009 11:06:59 schrieb Petit Eric:
2009/5/7 Marcus Hüwe
: Hi,
On 2009-05-07 10:25:55 +0200, Michal Čihař wrote:
some time ago I wrote a patch for storing osc credentials in Gnome keyring instead of ~/.oscrc. It uses keyring only if available otherwise it falls back to using configuration file.
Any comments on committing this into svn?
The patch is available in bugzilla: https://bugzilla.novell.com/show_bug.cgi?id=460540
I thought about this patch for some time. Overall the patch looks good to me but "design wise" I'm a bit hesitant. There might be someone who wants support for kwallet or another password manager so he adds his kwallet specific code to the conf.py module. So it might be a good idea to add something like a base class for all these user/password stuff, e.g. class OscPasswdMgr(): def getUser(...) def setUser(...) etc. class OscGnomeKeyring(OscPasswdMgr): ...
This way we would have a "clean" conf.py. This might be something for the future... feel free to commit your patch (at least there are no objections from my side:) ).
This is not more simply to crypt/decrypt password before read/write password in ~/.oscrc , like i do in MonoOSC ?
And where do store the crypt/decrypt key ? Or do you want to ask always the user to enter it ? -- Adrian Schroeter SUSE Linux Products GmbH email: adrian@suse.de -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-buildservice+help@opensuse.org
2009/5/7 Adrian Schröter
Am Donnerstag, 7. Mai 2009 11:06:59 schrieb Petit Eric:
2009/5/7 Marcus Hüwe
: Hi,
On 2009-05-07 10:25:55 +0200, Michal Čihař wrote:
some time ago I wrote a patch for storing osc credentials in Gnome keyring instead of ~/.oscrc. It uses keyring only if available otherwise it falls back to using configuration file.
Any comments on committing this into svn?
The patch is available in bugzilla: https://bugzilla.novell.com/show_bug.cgi?id=460540
I thought about this patch for some time. Overall the patch looks good to me but "design wise" I'm a bit hesitant. There might be someone who wants support for kwallet or another password manager so he adds his kwallet specific code to the conf.py module. So it might be a good idea to add something like a base class for all these user/password stuff, e.g. class OscPasswdMgr(): def getUser(...) def setUser(...) etc. class OscGnomeKeyring(OscPasswdMgr): ...
This way we would have a "clean" conf.py. This might be something for the future... feel free to commit your patch (at least there are no objections from my side:) ).
This is not more simply to crypt/decrypt password before read/write password in ~/.oscrc , like i do in MonoOSC ?
And where do store the crypt/decrypt key ? Or do you want to ask always the user to enter it ? no
--
Adrian Schroeter SUSE Linux Products GmbH email: adrian@suse.de
-- Cordially. Small Eric Quotations of the days: --------------------------------------------------------------------------- If one day one reproaches you that your work is not a work of professional, say you that: Amateurs built the arch of Noah, and professionals the Titanic. --------------------------------------------------------------------------- Few people are done for independence, it is the privilege of the powerful ones. --------------------------------------------------------------------------- No key was wounded during the drafting of this message. -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-buildservice+help@opensuse.org
Am Donnerstag, 7. Mai 2009 11:05:05 schrieb Marcus Hüwe:
Hi,
On 2009-05-07 10:25:55 +0200, Michal Čihař wrote:
some time ago I wrote a patch for storing osc credentials in Gnome keyring instead of ~/.oscrc. It uses keyring only if available otherwise it falls back to using configuration file.
Any comments on committing this into svn?
The patch is available in bugzilla: https://bugzilla.novell.com/show_bug.cgi?id=460540
I thought about this patch for some time. Overall the patch looks good to me but "design wise" I'm a bit hesitant. There might be someone who wants support for kwallet or another password manager so he adds his kwallet specific code to the conf.py module. So it might be a good idea to add something like a base class for all these user/password stuff, e.g. class OscPasswdMgr(): def getUser(...) def setUser(...) etc. class OscGnomeKeyring(OscPasswdMgr): ...
This way we would have a "clean" conf.py. This might be something for the future... feel free to commit your patch (at least there are no objections from my side:) ).
Do you avoid dependencies to Gnome/KDE via that as well ? (osc should still work on a minimal installation). bye adrian -- Adrian Schroeter SUSE Linux Products GmbH email: adrian@suse.de -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-buildservice+help@opensuse.org
Hi
Dne Thu, 7 May 2009 11:29:22 +0200
Adrian Schröter
Do you avoid dependencies to Gnome/KDE via that as well ? (osc should still work on a minimal installation).
With my patch it still works as before if no keyring is found or if user has stored password in config file. -- Michal Čihař | http://cihar.com | http://blog.cihar.com
On 2009-05-07 11:29:22 +0200, Adrian Schröter wrote:
Am Donnerstag, 7. Mai 2009 11:05:05 schrieb Marcus Hüwe:
Hi,
On 2009-05-07 10:25:55 +0200, Michal Čihař wrote:
some time ago I wrote a patch for storing osc credentials in Gnome keyring instead of ~/.oscrc. It uses keyring only if available otherwise it falls back to using configuration file.
Any comments on committing this into svn?
The patch is available in bugzilla: https://bugzilla.novell.com/show_bug.cgi?id=460540
I thought about this patch for some time. Overall the patch looks good to me but "design wise" I'm a bit hesitant. There might be someone who wants support for kwallet or another password manager so he adds his kwallet specific code to the conf.py module. So it might be a good idea to add something like a base class for all these user/password stuff, e.g. class OscPasswdMgr(): def getUser(...) def setUser(...) etc. class OscGnomeKeyring(OscPasswdMgr): ...
This way we would have a "clean" conf.py. This might be something for the future... feel free to commit your patch (at least there are no objections from my side:) ).
Do you avoid dependencies to Gnome/KDE via that as well ? (osc should still work on a minimal installation).
What I had in mind was that osc doesn't care from where and how the credentials are retrieved. You simply add something like "credentials = 'gnome_keyring'" to your ~/.oscrc (for each apiurl section) and osc will try to create an instance of the class 'gnome_keyring' and then retrieve the credentials... These classes can be packaged as plugins for osc etc. so we don't have new deps. Marcus -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-buildservice+help@opensuse.org
Marcus Hüwe wrote:
What I had in mind was that osc doesn't care from where and how the credentials are retrieved. You simply add something like "credentials = 'gnome_keyring'" to your ~/.oscrc (for each apiurl section) and osc will try to create an instance of the class 'gnome_keyring' and then retrieve the credentials... These classes can be packaged as plugins for osc etc. so we don't have new deps.
When you use try/except around import you don't introduce new dependencies. -- Best Regards / S pozdravom, Pavol RUSNAK SUSE LINUX, s.r.o Package Maintainer Lihovarska 1060/12 PGP 0xA6917144 19000 Praha 9, CR prusnak[at]suse.cz http://www.suse.cz -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-buildservice+help@opensuse.org
On 2009-05-07 16:28:40 +0200, Pavol Rusnak wrote:
Marcus Hüwe wrote:
What I had in mind was that osc doesn't care from where and how the credentials are retrieved. You simply add something like "credentials = 'gnome_keyring'" to your ~/.oscrc (for each apiurl section) and osc will try to create an instance of the class 'gnome_keyring' and then retrieve the credentials... These classes can be packaged as plugins for osc etc. so we don't have new deps.
When you use try/except around import you don't introduce new dependencies.
Yes that's what Michal's code is currently doing - it's just an idea to keep the module "clean"... but for now the current patch should be committed IMHO. The restructuring can be done later (if needed). Marcus -- To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-buildservice+help@opensuse.org
Hi
Dne Thu, 7 May 2009 19:03:02 +0200
Marcus Hüwe
On 2009-05-07 16:28:40 +0200, Pavol Rusnak wrote:
Marcus Hüwe wrote:
What I had in mind was that osc doesn't care from where and how the credentials are retrieved. You simply add something like "credentials = 'gnome_keyring'" to your ~/.oscrc (for each apiurl section) and osc will try to create an instance of the class 'gnome_keyring' and then retrieve the credentials... These classes can be packaged as plugins for osc etc. so we don't have new deps.
When you use try/except around import you don't introduce new dependencies.
Yes that's what Michal's code is currently doing - it's just an idea to keep the module "clean"... but for now the current patch should be committed IMHO. The restructuring can be done later (if needed).
Okay, commited. -- Michal Čihař | http://cihar.com | http://blog.cihar.com
participants (5)
-
Adrian Schröter
-
Marcus Hüwe
-
Michal Čihař
-
Pavol Rusnak
-
Petit Eric