Hello community, here is the log from the commit of package rug checked in at Wed May 31 03:06:20 CEST 2006. -------- --- rug/rug.changes 2006-05-22 23:22:01.000000000 +0200 +++ rug/rug.changes 2006-05-31 02:50:11.000000000 +0200 @@ -1,0 +2,9 @@ +Wed May 31 02:49:20 CEST 2006 - maw@suse.de + +- New source drop (r29084) which: +- Removes some debug spew that was inadvertently left in a + previous commit +- Handles catalogs with empty 'DisplayName's (#178646) +- Adds key commands kl, ka, and kd. + +------------------------------------------------------------------- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ rug.spec ++++++ --- /var/tmp/diff_new_pack.m3nfdP/_old 2006-05-31 03:05:55.000000000 +0200 +++ /var/tmp/diff_new_pack.m3nfdP/_new 2006-05-31 03:05:55.000000000 +0200 @@ -14,7 +14,7 @@ BuildRequires: gtkdoc mono-basic mono-data-sqlite mono-devel zmd-devel URL: http://www.novell.com Version: 7.1.1.0 -Release: 19 +Release: 20 License: GPL BuildRoot: %{_tmppath}/%{name}-%{version}-build Summary: Command Line Client for zmd @@ -78,6 +78,12 @@ %_mandir/*/*/*.gz %changelog -n rug +* Wed May 31 2006 - maw@suse.de +- New source drop (r29084) which: +- Removes some debug spew that was inadvertently left in a + previous commit +- Handles catalogs with empty 'DisplayName's (#178646) +- Adds key commands kl, ka, and kd. * Mon May 22 2006 - maw@suse.de - New source drop (r28766) which: - Eats "permission denied" exception if the argument isn't a ++++++ rug-7.1.1.0.tar.bz2 ++++++ diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/rug-7.1.1.0/src/Catalogs.cs new/rug-7.1.1.0/src/Catalogs.cs --- old/rug-7.1.1.0/src/Catalogs.cs 2006-05-15 17:16:15.000000000 +0200 +++ new/rug-7.1.1.0/src/Catalogs.cs 2006-05-26 17:32:34.000000000 +0200 @@ -80,11 +80,6 @@ string displayNameInitials = GetInitials (displayName, true); string displayNameInitialsAlt = GetInitials (displayName, false); - Console.WriteLine ("'{0}' '{1}' '{2}' '{3}' '{4}' '{5}'", - name, displayName, - nameInitials, nameInitialsAlt, - displayNameInitials, displayNameInitialsAlt); - if (info.Name == catalog || info.DisplayName == catalog || name == catalogLower || displayName == catalogLower || nameInitials == catalogLower || nameInitialsAlt == catalogLower || @@ -110,6 +105,9 @@ } private static string GetInitials (string c, bool replaceDots) { + if (c == null || c == String.Empty) + return null; + if (replaceDots) c = c.Replace ('.', ' '); diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/rug-7.1.1.0/src/ChangeLog new/rug-7.1.1.0/src/ChangeLog --- old/rug-7.1.1.0/src/ChangeLog 2006-05-22 17:18:46.000000000 +0200 +++ new/rug-7.1.1.0/src/ChangeLog 2006-05-26 17:32:34.000000000 +0200 @@ -1,3 +1,16 @@ +2006-05-25 Tambet Ingo <tambet@ximian.com> + + * Catalogs.cs: Remove some debug spew I forgot to take out from the + previous commit. Handle catalogs with empty DisplayName. + Fixes #178646. + +2006-05-23 Dan Mills <thunder@ximian.com> + + * Makefile.am: Add KeyCommands.cs. + + * KeyCommands.cs: Adds key-list (kl), key-add (ka), and key-delete + (kd) to manage trusted keys. + 2006-05-22 Tambet Ingo <tambet@ximian.com> * PackageCommands.cs (FindLocalPackage): Eat "permission denied" diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/rug-7.1.1.0/src/KeyCommands.cs new/rug-7.1.1.0/src/KeyCommands.cs --- old/rug-7.1.1.0/src/KeyCommands.cs 1970-01-01 01:00:00.000000000 +0100 +++ new/rug-7.1.1.0/src/KeyCommands.cs 2006-05-23 20:46:17.000000000 +0200 @@ -0,0 +1,174 @@ +/* + * Copyright (c) 2005 Novell, Inc. All Rights Reserved. + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of version 2 of the GNU General Public License + * as published by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, contact Novell, Inc. + * + * To contact Novell about this file by physical or electronic mail, + * you may find current contact information at www.novell.com. + * + */ + +using System; +using System.Collections; +using Novell.Zenworks.Zmd.Public; +using Novell.Zenworks.Zmd.Packaging.Public; +using Novell.Zenworks.Utility; + +namespace Novell.Zenworks.Rug { + + class KeyWhitelistCommand : Command { + + private IKeyManager keyManager = null; + + protected IKeyManager KeyManager { + get { + if (keyManager == null) + keyManager = (IKeyManager) Activate ("IKeyManager", typeof (IKeyManager)); + return keyManager; + } + } + } + + class KeyListCommand : KeyWhitelistCommand { + + public override string Name { + get { return "key-list"; } + } + + public override string Description { + get { return GetString ("Display whitelisted keys for a service"); } + } + + public override string Category { + get { return GetString ("Security"); } + } + + public override string[] Aliases { + get { return new string[] { "kl" }; } + } + + public override void Execute () { + IPreferenceManager prefs = (IPreferenceManager) Activate ("IPreferenceManager", + typeof (IPreferenceManager)); + string level = (string) prefs.GetValue ("security-level"); + if (level != "signature") { + Error (GetString ("Signature verification is not enabled.")); + } + + IKey[] keys = KeyManager.Keys; + + if (keys.Length == 0) { + Error (GetString ("No whitelisted keys found.")); + return; + } + + Formatter formatter = new Formatter (GetString ("Name"), GetString ("ID"), GetString ("Fingerprint")); + foreach (IKey key in keys) { + formatter.AddRow (key.Name, key.Id, key.Fingerprint); + } + + Console.WriteLine (formatter); + } + } + + class KeyAddCommand : KeyWhitelistCommand { + + public override string Name { + get { return "key-add"; } + } + + public override string Description { + get { return GetString ("Add to the list of whitelisted keys for a service"); } + } + + public override string Category { + get { return GetString ("Security"); } + } + + public override string[] Aliases { + get { return new string[] { "ka" }; } + } + + public override string Arguments { + get { return "<keyname> <keyid>"; } + } + + public override void Execute () { + if (this.RemainingArguments.Length < 3) { + Error (GetString ("A name, id, and fingerprint are required. You may use blank values (\"\") for some if desired.")); + return; + } + if (this.RemainingArguments.Length > 3) { + Error (GetString ("Too many arguments.")); + return; + } + + KeyManager.Add (RemainingArguments[0], RemainingArguments[1], RemainingArguments[2]); + + Console.WriteLine (GetString ("Key added.")); + } + } + + class KeyDeleteCommand : KeyWhitelistCommand { + + public override string Name { + get { return "key-delete"; } + } + + public override string Description { + get { return GetString ("Remove from the list of whitelisted keys for a service"); } + } + + public override string Category { + get { return GetString ("Security"); } + } + + public override string[] Aliases { + get { return new string[] { "kd" }; } + } + + public override string Arguments { + get { return "<keyid>"; } + } + + public override void Execute () { + if (this.RemainingArguments.Length < 1) { + Error (GetString ("No key was specified.")); + return; + } + if (this.RemainingArguments.Length == 2) { + Error (GetString ("Must specify either one argument (matches anything with that string), or three (matches one key exactly).")); + return; + } + if (this.RemainingArguments.Length > 3) { + Error (GetString ("Too many arguments.")); + return; + } + + IKey k; + if (this.RemainingArguments.Length == 1) { + k = KeyManager.LookupKey (RemainingArguments[0]); + } else { + k = KeyManager.LookupKey (RemainingArguments[0], RemainingArguments[1], RemainingArguments[2]); + } + + if (k == null) { + Error (GetString ("Could not find key.")); + return; + } + + KeyManager.Remove (k); + Console.WriteLine (GetString ("Key removed.")); + } + } +} diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/rug-7.1.1.0/src/Makefile.am new/rug-7.1.1.0/src/Makefile.am --- old/rug-7.1.1.0/src/Makefile.am 2006-04-10 14:42:58.000000000 +0200 +++ new/rug-7.1.1.0/src/Makefile.am 2006-05-23 20:46:17.000000000 +0200 @@ -16,6 +16,7 @@ Command.cs \ DaemonHelper.cs \ Formatter.cs \ + KeyCommands.cs \ LogCommands.cs \ PackageCommands.cs \ CommandLineParser.cs \ diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/rug-7.1.1.0/src/Makefile.in new/rug-7.1.1.0/src/Makefile.in --- old/rug-7.1.1.0/src/Makefile.in 2006-05-16 00:07:04.000000000 +0200 +++ new/rug-7.1.1.0/src/Makefile.in 2006-05-26 17:32:56.000000000 +0200 @@ -198,6 +198,7 @@ Command.cs \ DaemonHelper.cs \ Formatter.cs \ + KeyCommands.cs \ LogCommands.cs \ PackageCommands.cs \ CommandLineParser.cs \ ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun...
participants (1)
-
root@suse.de