Bug 1271127 - Register to Satellite successfully using system name with max characters (length>249).
Summary: Register to Satellite successfully using system name with max characters (len...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Candlepin
Version: 6.1.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: Unspecified
Assignee: Barnaby Court
QA Contact: Katello QA List
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-10-13 08:27 UTC by qianzhan
Modified: 2016-03-04 20:28 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-03-04 20:28:06 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description qianzhan 2015-10-13 08:27:05 UTC
Description of problem:
Register to Satellite successfully using system name with more than 249 characters.

Version-Release number of selected component (if applicable):
Satellite-6.1.0

How reproducible:
always

Steps to Reproduce:
1. Register RHEL-7.2-20151008.0 to Satellite-6.1.0 by specifying the system name with more than 249 characters.
 
# subscription-manager register --username=admin --password='admin' --name=qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345

Registering to: satellite-ab4a1678-be6c-4045-86a9-5dca9918d2b.novalocal:443/rhsm

The system has been registered with ID: 0cf54e4b-9d68-4856-a48f-d9e8bef79a4e

Actual results:
As step 1.

Expected results:
The registration should not be successful when using system name with more than 249 characters

# subscription-manager register --username=admin --password=admin --name=adminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadminadmin
Name of the unit must be shorter than 250 characters.


Additional info:

Comment 2 Barnaby Court 2016-03-04 20:28:06 UTC
Subscription management supports a name of up to 255 characters. The supplied name is 251 characters.

When I ran the command with a longer name it errored appropriately:

[root@localhost ca]# subscription-manager register --username=admin --password='changeme' --name='qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345qwert12345applepear'
Registering to: sat-test-rhel7.example.com:443/rhsm
Validation failed: Name is too long (maximum is 255 characters)
[root@localhost ca]#


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