Bug 488622 - kickstart.profile.addIpRange accepts values greater than 255 for IP range
kickstart.profile.addIpRange accepts values greater than 255 for IP range
Status: CLOSED CURRENTRELEASE
Product: Red Hat Satellite 5
Classification: Red Hat
Component: API (Show other bugs)
530
All Linux
low Severity medium
: ---
: ---
Assigned To: Brad Buckingham
Sayli Karmarkar
:
Depends On:
Blocks: 456996
  Show dependency treegraph
 
Reported: 2009-03-04 18:25 EST by Sayli Karmarkar
Modified: 2015-03-22 21:09 EDT (History)
1 user (show)

See Also:
Fixed In Version: sat530
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-09-10 15:54:40 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Sayli Karmarkar 2009-03-04 18:25:45 EST
Description of problem:
server.kickstart.profile.addIpRange(key, 'foobar', "999.999.999.998", "999.999.999.999");
returns 1 and when I see it in webui, it shows:

IP Address Range: 	231.231.231.230 - 231.231.231.231  	


Steps to Reproduce:
1. Create a kickstart profile foobar
2. Try using this api with following values: server.kickstart.profile.addIpRange(key, 'foobar', "999.999.999.998", "999.999.999.999");

  
Actual results:
1 (success)

Expected results:
We should see same error as we will see if we enter these values through webui:
"Error: IP range values must be between 0 and 255. Please check IP range you just entered and try again."

~SayliK
Comment 1 Brad Buckingham 2009-03-05 10:32:00 EST
git commit: 75790a57f3d5ed2615c3ced717397c7ca3d00374

Updated logic to perform the same 'validateIpRange' logic that is used by the UI.
Comment 2 Sayli Karmarkar 2009-03-10 19:16:53 EDT
verified.

server.kickstart.profile.addIpRange(key,  "ks2fMuHFS3GY1ET", "999.999.999.998", "999.999.999.999")

>>> xmlrpclib.Fault: <Fault 2800: 'redstone.xmlrpc.XmlRpcFault: Error: IP range values must be between 0 and 255. Please check IP range you just entered and try again.'>


>>> server.kickstart.profile.addIpRange(key,  "ks2fMuHFS3GY1ET", "255.255.255.254", "255.255.255.255")
1
Comment 3 Sayli Karmarkar 2009-08-25 19:48:38 EDT
server.kickstart.profile.addIpRange(key,  "testprofile", "999.999.999.998",
"999.999.999.999")
>>> xmlrpclib.Fault: <Fault 2800: 'redstone.xmlrpc.XmlRpcFault: Error: IP range values must be between 0 and 255. Please check IP range you just entered and try again.'>
Comment 4 Brandon Perkins 2009-09-10 15:54:40 EDT
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

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