Bug 737563 - Subscription Manager fails permissions on accessing subscriptions
Summary: Subscription Manager fails permissions on accessing subscriptions
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Satellite 6
Classification: Red Hat
Component: katello-agent
Version: 6.0.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium vote
Target Milestone: Unspecified
Assignee: Lukas Zapletal
QA Contact: Garik Khachikyan
URL:
Whiteboard:
Depends On:
Blocks: katello-blockers
TreeView+ depends on / blocked
 
Reported: 2011-09-12 14:58 UTC by Bryan Kearney
Modified: 2015-01-04 21:58 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-08-22 17:56:43 UTC


Attachments (Terms of Use)

Description Bryan Kearney 2011-09-12 14:58:40 UTC
Steps to reproduce:

1) Register the machine against katello
2) execute: ./subscription-manager list --available
3) The server will show this failure:

Started GET "/katello//api/consumers/af6d0339-f424-498e-adb4-69f29068c049/owner" for 10.11.228.61 at Mon Sep 12 11:13:22 -0400 2011
  Processing by Api::CandlepinProxiesController#get as JSON
  Parameters: {"id"=>"af6d0339-f424-498e-adb4-69f29068c049"}
Completed   in 1ms
  Processing by FailedAuthenticationController#unauthenticated_api as JSON
  Parameters: {"auth_username"=>"\005\253\"", "id"=>"af6d0339-f424-498e-adb4-69f29068c049", "auth_password"=>"[FILTERED]"}
Request is unauthenticated_api for 127.0.0.1
Completed 401 Unauthorized in 0ms

Comment 1 Lukas Zapletal 2011-09-13 08:58:39 UTC
Hmmm it worked for me.

Started GET "/api/consumers/bda2f6ed-5548-4022-8086-f159a51bf1d7/owner" for 127.0.0.1 at Tue Sep 13 10:36:49 +0200 2011
  Processing by Api::CandlepinProxiesController#get as JSON
  Parameters: {"id"=>"bda2f6ed-5548-4022-8086-f159a51bf1d7"}
Setting locale: en
Setting current user thread-local variable to bda2f6ed-5548-4022-8086-f159a51bf1d7
Sending GET request to Candlepin: /consumers/bda2f6ed-5548-4022-8086-f159a51bf1d7/owner
Rendered text template (0.0ms)
Setting current user thread-local variable to nil
Completed 200 OK in 272ms (Views: 1.6ms | ActiveRecord: 0.0ms)

But I got different error regarding update and then https://bugzilla.redhat.com/show_bug.cgi?id=737841. Working on them all. Looks like serious issue in our protection code once we switched over to the improved model. Nobody did test rhsm.

Comment 2 Lukas Zapletal 2011-09-13 09:01:40 UTC
Correcting the incorrect product on this BZ. Bugzilla changed it for me. I did not touch it. Is this a bug? ;-)

Comment 3 Lukas Zapletal 2011-09-13 11:03:20 UTC
Bryan I am not able to reproduce this. Could you send me the backtrace if you run into this issue again? I refactored way we check permissions for rhsm, now I am working on tests.

I am interested in the candlepin error log as well. I wonder how is possible you got 401. It is probably not from Katello, but from candlepin. Katello act as proxy in this request.

Comment 4 Lukas Zapletal 2011-09-13 15:17:09 UTC
I guess this has been fixed with

d738b1d 737563 - Subscription Manager fails permissions on accessing subscriptions

Please re-test and provide me full katello/candlepin logs when you encounter this again.

Comment 5 Lukas Zapletal 2011-09-14 14:50:10 UTC
This should be really fixed now.

Comment 6 Lukas Zapletal 2012-01-20 11:54:11 UTC
This is fixed.

Comment 8 Garik Khachikyan 2012-02-15 12:38:02 UTC
# VERIFIED

no issues since a while on subscription-manager list --available

checked recently (again) on:
---

katello-0.1.237-1.git.7.752d8de.el6.noarch
katello-cli-0.1.54-1.git.79.17c365f.el6.noarch
candlepin-0.5.17-1.el6.noarch
pulp-0.0.265-1.el6.noarch


Note You need to log in before you can comment on or make changes to this bug.