client/tools/rhncfg/config_client/rhncfgcli_verify.py | 16 +++++++++++
java/code/src/com/redhat/rhn/manager/audit/AuditManager.java | 5 ---
2 files changed, 17 insertions(+), 4 deletions(-)
New commits:
commit 98385232ab52e6e48383baf695f213d712a6ad93
Author: Joshua Roys <joshua.roys(a)gtri.gatech.edu>
Date: Fri Apr 9 13:23:24 2010 +0000
Remove spammy audit types from default search
This removes the hundreds, and possibly thousands, of cron entries
from the default search view.
diff --git a/java/code/src/com/redhat/rhn/manager/audit/AuditManager.java
b/java/code/src/com/redhat/rhn/manager/audit/AuditManager.java
index 4bef7e3..f109f3f 100644
--- a/java/code/src/com/redhat/rhn/manager/audit/AuditManager.java
+++ b/java/code/src/com/redhat/rhn/manager/audit/AuditManager.java
@@ -143,12 +143,9 @@ public class AuditManager /* extends BaseManager */ {
types.put("default", new String[]{
"USER",
- "LOGIN",
"USER_AUTH",
- "USER_ACCT",
"USER_MGMT",
- "USER_START",
- "USER_END",
+ "USER_ERR",
"USER_LOGIN",
"USER_LOGOUT",
"ADD_USER",
commit da20ecf89687c4151ab725b84f2725abdcd53b34
Author: Joshua Roys <joshua.roys(a)gtri.gatech.edu>
Date: Thu Apr 15 15:35:35 2010 +0000
Add an 'only' mode of operation to rhncfg-client verify
This will only display files that differ.
diff --git a/client/tools/rhncfg/config_client/rhncfgcli_verify.py
b/client/tools/rhncfg/config_client/rhncfgcli_verify.py
index ca9e6a1..caa30b5 100644
--- a/client/tools/rhncfg/config_client/rhncfgcli_verify.py
+++ b/client/tools/rhncfg/config_client/rhncfgcli_verify.py
@@ -36,6 +36,12 @@ class Handler(handler_base.HandlerBase):
action="count",
help="Increase the amount of output detail.",
),
+ handler_base.HandlerBase._option_class(
+ '--only',
+ "-o",
+ action="count",
+ help="Only show files that differ.",
+ ),
]
# Main function to be run
@@ -122,6 +128,14 @@ class Handler(handler_base.HandlerBase):
if len(fdict['selinux']) > 0:
(src_selinux, dst_selinux) =
fdict['selinux'].split('|')
+ if self.options.only:
+ sum = 0
+ for key in fdict.keys():
+ if key != 'file':
+ sum += len(fdict[key])
+ if sum == 0:
+ continue
+
print outstring % {
"status" : formatstr %
(maxlenarr['status'], fdict['status']),
"owner" : formatstr %
(maxlenarr['owner'], fdict['owner']),
@@ -144,6 +158,8 @@ class Handler(handler_base.HandlerBase):
outstring = "%*s %s"
maxlen = max(map(lambda x: len(x['status']), ret)) + 1
for fdict in ret:
+ if self.options.only and len(fdict['status']) == 0:
+ continue
print outstring % (maxlen, fdict['status'],
fdict['file'])
def _process_file(self, *args):
Show replies by date