Bug 1136088

Summary: subnet mask validation
Product: Red Hat Satellite Reporter: Ales Dujicek <adujicek>
Component: ProvisioningAssignee: Christine Fouant <cfouant>
Status: CLOSED ERRATA QA Contact: Kedar Bidarkar <kbidarka>
Severity: low Docs Contact:
Priority: unspecified    
Version: 6.0.4CC: bkearney, dcleal, kbidarka, sthirugn
Target Milestone: UnspecifiedKeywords: Triaged
Target Release: Unused   
Hardware: Unspecified   
OS: Unspecified   
URL: http://projects.theforeman.org/issues/7430
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-08-12 05:15:55 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
subnet mask validation happens via UI none

Description Ales Dujicek 2014-09-01 15:57:51 UTC
Description of problem:

subnet mask can be set to any IP address like (255.1.2.3)

valid masks are only 128.0.0.0, 192..., 224..., etc.


Version-Release number of selected component (if applicable):
Satellite-6.0.4-RHEL-6-20140829.0 [Sat6-GA-Snap7-Compose3]

How reproducible:
always

Steps to Reproduce:
1. # hammer subnet create --name subnet_1 --network 140.20.1.0 --mask 255.1.2.3
Subnet created

Comment 3 Christine Fouant 2014-09-12 21:59:52 UTC
Created redmine issue http://projects.theforeman.org/issues/7430 from this bug

Comment 4 Bryan Kearney 2014-09-15 13:45:59 UTC
Moving to POST since upstream bug http://projects.theforeman.org/issues/7430 has been closed
-------------
Christine Fouant
Applied in changeset commit:7af45f0986480143e96d141390579279d62e526a.

Comment 8 Kedar Bidarkar 2015-02-13 12:37:02 UTC
VERIFIED With Sat6.1 Beta snap2

so subnet mask validation happens.

[root@xxxxx ~]# hammer -u admin -p changeme subnet create --name qe_libvirt_199 --network 192.168.105.0 --mask 255.1.2.3
/usr/lib/ruby/gems/1.8/gems/hammer_cli-0.1.4/lib/hammer_cli/./apipie/../abstract.rb:68: warning: already initialized constant DEFAULT_LABEL_INDENT
Could not create the subnet:
  Network mask is invalid
[root@xxxxx ~]# hammer -u admin -p changeme subnet create --name qe_libvirt_199 --network 192.168.105.0 --mask 192.3.4.5
/usr/lib/ruby/gems/1.8/gems/hammer_cli-0.1.4/lib/hammer_cli/./apipie/../abstract.rb:68: warning: already initialized constant DEFAULT_LABEL_INDENT
Could not create the subnet:
  Network mask is invalid

Comment 9 Kedar Bidarkar 2015-02-13 12:38:14 UTC
Created attachment 991362 [details]
subnet mask validation happens via UI

Comment 10 Bryan Kearney 2015-08-11 13:28:25 UTC
This bug is slated to be released with Satellite 6.1.

Comment 11 errata-xmlrpc 2015-08-12 05:15:55 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2015:1592