Bug 2073153

Summary: IPs with leading zeros should still be valid in the apiserver
Product: OpenShift Container Platform Reporter: Abu Kashem <akashem>
Component: kube-apiserverAssignee: Antonio Ojea <aojeagar>
Status: CLOSED ERRATA QA Contact: Ke Wang <kewang>
Severity: high Docs Contact:
Priority: high    
Version: 4.9CC: aos-bugs, mfojtik, vlaad, xxia
Target Milestone: ---Keywords: FastFix
Target Release: 4.9.z   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-05-03 07:35:34 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:
Bug Depends On: 2042493    
Bug Blocks: 2069310, 2075043    

Description Abu Kashem 2022-04-07 18:51:01 UTC
https://bugzilla.redhat.com/show_bug.cgi?id=2043807 is in ERRATA, but we still see the unit test fail.


: Run test unit - container test expand_more	13m49s
k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/validation: TestIsValidIP expand_less	0s
{Failed  === RUN   TestIsValidIP
    validation_test.go:340: expected true for "1.1.1.01": [must be a valid IP address, (e.g. 10.9.8.7 or 2001:db8::ffff)]
--- FAIL: TestIsValidIP (0.00s)
}



https://prow.ci.openshift.org/view/gs/origin-ci-test/pr-logs/pull/openshift_kubernetes/1233/pull-ci-openshift-kubernetes-release-4.9-unit/1511357899316662272
It's blocking https://github.com/openshift/kubernetes/pull/1233. 

I do see the proper GOFLAGS in 4.9, and yet the unit test fails.
https://github.com/openshift/kubernetes/blob/release-4.9/openshift-hack/images/hyperkube/Dockerfile.rhel#L4-L9

> RUN make GOFLAGS='-mod=vendor -p=4 -tags=unsupportedGolang116OnlyUseDeprecatedParseIPv4' \
>         WHAT='cmd/kube-apiserver cmd/kube-controller-manager cmd/kube-scheduler cmd/kubelet cmd/watch-termination' && \

Comment 8 Ke Wang 2022-04-15 02:33:21 UTC
Based on Comment 5 and PR change, this is for test fix. Checked the latest unit test results: https://prow.ci.openshift.org/view/gs/origin-ci-test/pr-logs/pull/openshift_kubernetes/1223/pull-ci-openshift-kubernetes-release-4.9-unit/1514325256490192896, the related test TestIsValidIP passed, so move the bug VERIFIED.

Comment 13 errata-xmlrpc 2022-05-03 07:35:34 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 (OpenShift Container Platform 4.9.31 bug fix update), 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/RHBA-2022:1605