Summary
Broadcasting is a powerful technique for discovering resources on the local area network. Sending broadcasts is simple, provided that you know the correct subnet-directed broadcast IP address to use. If not, you can determine it at runtime using the IO::Interface module (either the pure-Perl version developed here or the C extension module available from CPAN).
Receiving broadcasts is even easier. Any datagram-based server will receive broadcasts without any overt action on the programmer's part.
Broadcasting has some important limitations. It is useful only in the local area subnetwork because routers will not forward broadcast packets. Broadcasting is not selective. A host machine cannot opt out of receiving broadcasts any more than ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access