By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,206 Members | 1,020 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,206 IT Pros & Developers. It's quick & easy.

Validating IP & MAC Addresses ...

P: n/a
Hi,

- Is there a function that can validate IP addresses?
- Is there a function that can validate MAC addresses?

Hugo
Nov 17 '05 #1
Share this Question
Share on Google+
5 Replies


P: n/a
Maybe, and No...

However:

A MAC is simply a char[6] (6 bytes, not actually a string) and any 6 bytes
are valid - but some manufacturers / card ID's wont have been assigned. No
way to tell...

IP Wise look up illegal addresses and such.

- MR

"H.B." <hbcrdv@_hotmail_.com> wrote in message
news:11***************@news.drenet.dnd.ca...
Hi,

- Is there a function that can validate IP addresses?
- Is there a function that can validate MAC addresses?

Hugo

Nov 17 '05 #2

P: n/a
I believe you have to write your own Api to validate correct IP adress and
Mac Address as Microsoft Doesn't rpovide any api yet to check that.
--

With Regards
Alok Gupta
Visit me at http://alok.bizhat.com

"I Believe this will Help"
"H.B." <hbcrdv@_hotmail_.com> wrote in message
news:11***************@news.drenet.dnd.ca...
Hi,

- Is there a function that can validate IP addresses?
- Is there a function that can validate MAC addresses?

Hugo

Nov 17 '05 #3

P: n/a
It depends on your definition of valid MAC address and valid IP address.

"H.B." <hbcrdv@_hotmail_.com> wrote in message
news:11***************@news.drenet.dnd.ca...
Hi,

- Is there a function that can validate IP addresses?
- Is there a function that can validate MAC addresses?

Hugo

Nov 17 '05 #4

P: n/a
It's about syntax ...

I must validate syntax for two strings : IP string (xxx.xxx.xxx.xxx) and
MAC string. (xx-xx-xx-xx-xx-xx)

"Alexander Grigoriev" <al***@earthlink.net> wrote in message
news:e7**************@TK2MSFTNGP15.phx.gbl...
It depends on your definition of valid MAC address and valid IP address.

"H.B." <hbcrdv@_hotmail_.com> wrote in message
news:11***************@news.drenet.dnd.ca...
Hi,

- Is there a function that can validate IP addresses?
- Is there a function that can validate MAC addresses?

Hugo


Nov 17 '05 #5

P: n/a
"H.B." <hbcrdv@_hotmail_.com> wrote in message
news:11***************@news.drenet.dnd.ca...
It's about syntax ...

I must validate syntax for two strings : IP string (xxx.xxx.xxx.xxx) and
MAC string. (xx-xx-xx-xx-xx-xx)


That should be easy enough, the IP segments are between 0-255 and MAC
segments should be in the range (hex) 00-FF.

--
============
Frank Hickman
Microsoft MVP
NobleSoft, Inc.
============
Replace the _nosp@m_ with @ to reply.
Nov 17 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.