Project

General

Profile

Actions

Bug #32744

closed

enabled repositories upload fails with not subscribed error, when run as non-root user.

Added by Lucy Fu over 3 years ago. Updated over 3 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Client/Agent
Target version:
Difficulty:
Triaged:
Yes
Fixed in Releases:
Found in Releases:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1766653

Description of problem:
The enabled repositories plugin cannot run as a non-root user. however, it displays the following error, indicating the server is no longer subscribed to Satellite:

[provisioner@sirtgpu01 ~]$ yum search htop
Loaded plugins: enabled_repos_upload, package_upload, product-id, search-disabled-repos, subscription-manager ============================================================================================= N/S matched: htop ==============================================================================================
htop.x86_64 : Interactive process viewer

Name and summary matches only, use "search all" for everything.
Uploading Enabled Repositories Report
2019-10-29 09:21:44,038 [INFO] yum:240513:Dummy-1 @connection.py:905 - Connection built: host=sirt-satellite01.homeoffice.wal-mart.com port=443 handler=/rhsm auth=identity_cert ca_dir=/etc/rhsm/ca/ insecure=False
Loaded plugins: product-id, subscription-manager
2019-10-29 09:21:44,046 [WARNING] yum:240513:Dummy-1 @logutil.py:142 - logging already initialized
Cannot upload enabled repos report, is this client registered?
[provisioner@sirtgpu01 ~]$

Version-Release number of selected component (if applicable):*
Latest Client tools provided with Sat 6.6

How reproducible:*
completely

Steps to Reproduce:*
1.Run a yum command as a non root user
2.
3.

Actual results:

You get the error

Expected results:
The plugin checks if it is running as root or not, and you either get a warning you are a non-root user, or it logs the warning silently.

Additional info:
This creates confusion when non-root users run yum commands. This could be avoided with better messaging or security context awareness.

Actions #1

Updated by The Foreman Bot over 3 years ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/Katello/katello-host-tools/pull/117 added
Actions #2

Updated by James Jeffers over 3 years ago

  • Subject changed from enabled repositories upload fails with not subscribed error, when run as non-root user. to enabled repositories upload fails with not subscribed error, when run as non-root user.
  • Target version set to Katello 4.2.0
Actions #3

Updated by James Jeffers over 3 years ago

  • Triaged changed from No to Yes
Actions #4

Updated by The Foreman Bot over 3 years ago

  • Assignee set to Lucy Fu
Actions #5

Updated by Lucy Fu over 3 years ago

  • Status changed from Ready For Testing to Closed
Actions

Also available in: Atom PDF