Bug 484435

Summary: shared child channel from one org is listed in the base channel selection for the shared org
Product: Red Hat Satellite 5 Reporter: Preethi Thomas <pthomas>
Component: OtherAssignee: Shannon Hughes <shughes>
Status: CLOSED CURRENTRELEASE QA Contact: Preethi Thomas <pthomas>
Severity: medium Docs Contact:
Priority: high    
Version: 530CC: shughes, tlestach
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: sat530 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-09-10 18:14:34 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 456998, 486216    

Description Preethi Thomas 2009-02-06 19:23:17 UTC
Description of problem:

If a child channel from org1 is shared with org2, under alter channel subscription, the child channel is also listed in the base channel selection
Version-Release number of selected component (if applicable):


How reproducible:
rhn-satellite-5.1.1-28-redhat-linux-as-i386-4-embedded-oracle.iso

Steps to Reproduce:
1. create 2 orgs org1 & org2 with trust between two
2.login to org1 and create a org1_channel1 (select None for parent) make it public
3.create another custom channel org1_channel_child as a child of org1_channel1
4. login as org2
5. register a system to org2
6. go to the SDC of the registered system
7. Select Alter Channel Subscription
8. Look in the base software channel list
  
Actual results:

 See that the child channel is listed in the list.  Select a child channel and click confirm and click on modify base channel. See the ISE.

Expected results:
 shared child channels should not be listed in the base software channels

Additional info:


The following exception occurred while executing this request:
POST /rhn/systems/details/SystemChannels.do

Date:2/6/09 12:14:49 PM EST
Headers:
  host: fjs-0-07.rhndev.redhat.com
  user-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.0.2) Gecko/2008091816 Red Hat/3.0.2-3.el5 Firefox/3.0.2
  accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
  accept-language: en-us,ar;q=0.8,ja;q=0.5,ml;q=0.3
  accept-encoding: gzip,deflate
  accept-charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7
  Keep-Alive: 300
  connection: keep-alive
  referer: https://fjs-0-07.rhndev.redhat.com/rhn/systems/details/SystemChannels.do?sid=1000010021
  cookie: JSESSIONID=DDCAA6ACBA8118574AE594B0C92F3C08; rh_omni_tc=70160000000H4AjAAK; s_vi=[CS]v1|48EE249D00003447-A3A085D0000017A[CE]; pxt-session-cookie=128x75f4a57199023fedf9548323e8c3f88f
  content-type: application/x-www-form-urlencoded
  content-length: 76

Request:
Local Name = fjs-0-07.rhndev.redhat.com
Server Name = fjs-0-07.rhndev.redhat.com
Requested Session Id came from Cookie
Requested Session Valid = true
Session = org.apache.catalina.session.StandardSessionFacade@236c236c[session=StandardSession[DDCAA6ACBA8118574AE594B0C92F3C08]]
Protocol = https
Request Locale = en_US
Request Character Encoding = UTF-8
Attribute Names = rhnActiveLang, javax.servlet.jsp.jstl.fmt.timeZone.request, javax.servlet.request.key_size, __sitemesh__filterapplied, javax.servlet.request.ssl_session, systemChannelsForm, javax.servlet.request.cipher_suite, org.apache.struts.action.MESSAGE, session, org.apache.struts.action.mapping.instance, requestedUri, org.apache.struts.action.MODULE,

Form Variables:
  submitted: true
  sid: 1000010021
  new_base_channel_id: 164
  dispatch: Modify Base Software Channel


User Information:
User org_1 (id 22, org_id 3)

Exception:
javax.servlet.ServletException: Invalid channel
        at org.apache.struts.action.RequestProcessor.processException(RequestProcessor.java:535)
        at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:433)
        at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:237)
        at com.redhat.rhn.frontend.struts.RhnRequestProcessor.process(RhnRequestProcessor.java:82)
        at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
        at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:432)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
        at com.redhat.rhn.frontend.servlets.AuthFilter.doFilter(AuthFilter.java:73)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
        at com.opensymphony.module.sitemesh.filter.PageFilter.parsePage(PageFilter.java:142)
        at com.opensymphony.module.sitemesh.filter.PageFilter.doFilter(PageFilter.java:58)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
        at com.redhat.rhn.frontend.servlets.LocalizedEnvironmentFilter.doFilter(LocalizedEnvironmentFilter.java:67)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
        at com.redhat.rhn.frontend.servlets.EnvironmentFilter.doFilter(EnvironmentFilter.java:108)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
        at com.redhat.rhn.frontend.servlets.SessionFilter.doFilter(SessionFilter.java:55)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
        at com.redhat.rhn.frontend.servlets.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:97)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:215)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:210)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:172)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
        at org.apache.jk.server.JkCoyoteHandler.invoke(JkCoyoteHandler.java:200)
        at org.apache.jk.common.HandlerRequest.invoke(HandlerRequest.java:283)
        at org.apache.jk.common.ChannelSocket.invoke(ChannelSocket.java:773)
        at org.apache.jk.common.ChannelSocket.processConnection(ChannelSocket.java:703)
        at org.apache.jk.common.ChannelSocket$SocketConnection.runIt(ChannelSocket.java:895)
        at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:685)
        at java.lang.Thread.run(Thread.java:735)
Caused by: com.redhat.rhn.frontend.xmlrpc.InvalidChannelException: Invalid channel
        at com.redhat.rhn.manager.system.UpdateBaseChannelCommand.store(UpdateBaseChannelCommand.java:69)
        at com.redhat.rhn.frontend.action.systems.sdc.SystemChannelsAction.updateBaseChannel(SystemChannelsAction.java:266)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:59)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:39)
        at java.lang.reflect.Method.invoke(Method.java:612)
        at org.apache.struts.actions.DispatchAction.dispatchMethod(DispatchAction.java:270)
        at org.apache.struts.actions.DispatchAction.execute(DispatchAction.java:187)
        at org.apache.struts.actions.LookupDispatchAction.execute(LookupDispatchAction.java:150)
        at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)
        ... 40 more

Comment 1 Jesus M. Rodriguez 2009-02-12 19:46:05 UTC
fixed in 016d11072ebc20e6f6b4f75d1694ffd47d20b3d0

Comment 2 Preethi Thomas 2009-02-24 14:44:03 UTC
fails_qa

now the child channels is not listed with base channels, but if you chose the custom channel as the base channel, the child channel is not displayed underneath it subscribe.

1. create 2 orgs org1 & org2 with trust between two
2.login to org1 and create a org1_channel1 (select None for parent) make it
public
3.create another custom channel org1_channel_child as a child of org1_channel1
4. login as org2
5. register a system to org2
6. go to the SDC of the registered system
7. Select Alter Channel Subscription
8. Select the org1_channel1 from the base software channel list and confirm and Modify base software channel.
9. Notice that under the  Software Channel Subscriptions section only the base channel is displayed. So there is no way the system can subscribe to the the custom child channel of the base channel

Comment 4 Shannon Hughes 2009-04-07 18:43:38 UTC
added union to rhnsharedchannelview to bring in shared channel access for channel.hbm.xml

Comment 5 Shannon Hughes 2009-04-13 15:57:07 UTC
mass move to onqa

Comment 6 Preethi Thomas 2009-04-15 12:19:49 UTC
verified.
Satellite-5.3.0-RHEL5-re20090413.0-i386-embedded-oracle.iso
tested both the test plans from above. installed packages from shared channel & shared child channel

Comment 7 Tomas Lestach 2009-09-07 10:09:03 UTC
Child channel not listed in the base channels list. If a systems is subscribed to the custom base channel, the custom child channel is available and subscribable.

Stage validated -> RELEASE_PENDING

Comment 8 Brandon Perkins 2009-09-10 18:14:34 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHEA-2009-1434.html