How to validate an IP Address using python?

It should reject the shorter addresses such as 192.168 instead of padding the rest of the bits the address with 0s

see the code snippet archive for my code

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.