client/tools/rhncfg/config_common/transactions.py
| 2 +-
java/code/src/com/redhat/rhn/frontend/action/configuration/validation/configFileForm.xsd
| 1 -
java/code/src/com/redhat/rhn/frontend/strings/java/StringResource_en_US.xml
| 6 ++++++
schema/spacewalk/oracle/procs/lookup_config_info.sql
| 2 +-
schema/spacewalk/postgres/manual/rhnConfigInfo.sql
| 1 +
schema/spacewalk/postgres/procs/lookup_config_info.sql
| 2 +-
schema/spacewalk/upgrade/spacewalk-schema-0.5-to-spacewalk-schema-0.6/150-rhnConfigInfo_selinux.sql
| 2 +-
7 files changed, 11 insertions(+), 5 deletions(-)
New commits:
commit 04be74121059b81d3d4895ff645dd9be5d2bf731
Merge: a04b216... 123ae73...
Author: Joshua Roys <joshua.roys(a)gtri.gatech.edu>
Date: Wed Aug 5 17:33:16 2009 -0400
Merge branch 'master' of ssh://pkilambi@git.fedorahosted.org/git/spacewalk
commit a04b2169abc1974cee1a27cc15be4c4f9ba60dc1
Author: Joshua Roys <joshua.roys(a)gtri.gatech.edu>
Date: Wed Aug 5 17:32:48 2009 -0400
bugfix patch on selinux config file deploy
diff --git a/client/tools/rhncfg/config_common/transactions.py
b/client/tools/rhncfg/config_common/transactions.py
index cdd7ac0..9b00e07 100644
--- a/client/tools/rhncfg/config_common/transactions.py
+++ b/client/tools/rhncfg/config_common/transactions.py
@@ -145,7 +145,7 @@ class DeployTransaction:
if file_info.has_key('selinux_ctx'):
sectx = file_info.get('selinux_ctx')
- if sectx is not None:
+ if sectx is not None and sectx is not "":
log_debug(1, "selinux context: " + sectx);
if setfilecon(temp_file_path, sectx) < 0:
raise Exception("failed to set selinux context on %s" %
dest_path)
diff --git
a/java/code/src/com/redhat/rhn/frontend/action/configuration/validation/configFileForm.xsd
b/java/code/src/com/redhat/rhn/frontend/action/configuration/validation/configFileForm.xsd
index c2c6eba..8629faa 100644
---
a/java/code/src/com/redhat/rhn/frontend/action/configuration/validation/configFileForm.xsd
+++
b/java/code/src/com/redhat/rhn/frontend/action/configuration/validation/configFileForm.xsd
@@ -22,7 +22,6 @@
</attribute>
<attribute name="cffSELinuxCtx">
<simpleType baseType="string">
- <minLength value="0" />
<maxLength value="64" />
</simpleType>
</attribute>
diff --git a/java/code/src/com/redhat/rhn/frontend/strings/java/StringResource_en_US.xml
b/java/code/src/com/redhat/rhn/frontend/strings/java/StringResource_en_US.xml
index 63108c2..74ec95e 100644
--- a/java/code/src/com/redhat/rhn/frontend/strings/java/StringResource_en_US.xml
+++ b/java/code/src/com/redhat/rhn/frontend/strings/java/StringResource_en_US.xml
@@ -6866,6 +6866,12 @@ Follow this url to see the full list of inactive systems:
<context
context-type="sourcefile">/rhn/configuration/file/FileDetails.do</context>
</context-group>
</trans-unit>
+ <trans-unit id="cffSELinuxCtx">
+<source>SELinux context</source>
+ <context-group name="ctx">
+ <context
context-type="sourcefile">/rhn/configuration/file/FileDetails.do</context>
+ </context-group>
+ </trans-unit>
<trans-unit id="cffMacroStart">
<source>Macro start tag</source>
<context-group name="ctx">
diff --git a/schema/spacewalk/oracle/procs/lookup_config_info.sql
b/schema/spacewalk/oracle/procs/lookup_config_info.sql
index 65e238b..71a968e 100644
--- a/schema/spacewalk/oracle/procs/lookup_config_info.sql
+++ b/schema/spacewalk/oracle/procs/lookup_config_info.sql
@@ -34,7 +34,7 @@ is
and username = username_in
and groupname = groupname_in
and filemode = filemode_in
- and selinux_ctx = selinux_ctx_in;
+ and nvl(selinux_ctx, ' ') = nvl(selinux_ctx_in, ' ');
begin
for r in lookup_cursor loop
return r.id;
diff --git a/schema/spacewalk/postgres/manual/rhnConfigInfo.sql
b/schema/spacewalk/postgres/manual/rhnConfigInfo.sql
index ef594c3..77d16c7 100644
--- a/schema/spacewalk/postgres/manual/rhnConfigInfo.sql
+++ b/schema/spacewalk/postgres/manual/rhnConfigInfo.sql
@@ -30,6 +30,7 @@ rhnConfigInfo
filemode numeric not null,
created timestamp default (current_timestamp) not null,
modified timestamp default (current_timestamp) not null,
+ selinux_ctx varchar(64),
constraint rhn_confinfo_ugf_uq unique ( username, groupname, filemode )
-- tablespace [[4m_tbs]]
)
diff --git a/schema/spacewalk/postgres/procs/lookup_config_info.sql
b/schema/spacewalk/postgres/procs/lookup_config_info.sql
index d307d74..ab49472 100644
--- a/schema/spacewalk/postgres/procs/lookup_config_info.sql
+++ b/schema/spacewalk/postgres/procs/lookup_config_info.sql
@@ -33,7 +33,7 @@ declare
where username = username_in
and groupname = groupname_in
and filemode = filemode_in
- and selinux_ctx = selinux_ctx_in;
+ and nvl(selinux_ctx, ' ') = nvl(selinux_ctx_in, ' ');
begin
for r in lookup_cursor loop
return r.id;
diff --git
a/schema/spacewalk/upgrade/spacewalk-schema-0.5-to-spacewalk-schema-0.6/150-rhnConfigInfo_selinux.sql
b/schema/spacewalk/upgrade/spacewalk-schema-0.5-to-spacewalk-schema-0.6/150-rhnConfigInfo_selinux.sql
index f348e11..06ddefa 100644
---
a/schema/spacewalk/upgrade/spacewalk-schema-0.5-to-spacewalk-schema-0.6/150-rhnConfigInfo_selinux.sql
+++
b/schema/spacewalk/upgrade/spacewalk-schema-0.5-to-spacewalk-schema-0.6/150-rhnConfigInfo_selinux.sql
@@ -30,7 +30,7 @@ IS
AND username = username_in
AND groupname = groupname_in
AND filemode = filemode_in
- AND selinux_ctx = selinux_ctx_in;
+ AND nvl(selinux_ctx, ' ') = nvl(selinux_ctx_in, ' ');
BEGIN
FOR r IN lookup_cursor LOOP
RETURN r.id;
Show replies by date