OK. Let's first provide some general references that describe the
specific devices used in a network and then how they affect the
transport of the Media Access Control (MAC) Address.
describes a number of network devices (hub, bridge, switch, and
router) and I expanded on those previously
another reference (not quite as well organized, but explains some
concepts better) that describes a hub, switch, router, bridge, and
gateway. Note in this reference the generalization is made that a
switch can be considered a "multi port" (not two port) bridge.
a glossary (one of several) that describes these terms as well as
several other network related terms.
For additional references, try a search phrase like
explain switch hub router
describe switch hub router
switch hub router gateway bridge
glossary switch hub router
Now, specifically let's review the devices that will allow (or
prevent) a MAC address to be relayed across the network.
As the simplest device, the hub will send MAC addresses since it
copies all messages to all ports.
The bridge will do the same, but only on messages that are generated
on one side of the bridge and expected on the other side of the
bridge. Most bridges "learn" the MAC addresses on both sides of the
bridge to determine which messages to send across.
The switch acts in a similar manner - for a single port, that port
will only get the messages that are destined to the machine at the
other end. Those can be broadcast messages or messages in response to
a machine that polls the other systems.
At the higher end, a router, gateway, or a proxy server manipulates
the messages at a "higher layer" than the layer where MAC addresses
are used. At webopedia, there is a reference for the OSI network model
which describes the MAC addresses at layer 2. The router or gateway
typically operates at layer 3 (the network layer). The proxy server
can operate at that level (for filtering by address) or more often at
higher layers (e.g., an HTTP cache server at layer 7).
Because of that manipulation, the MAC address used on the messages to
and from those kinds of devices will be for that device (or more
specifically for the interface connected to that device - a router
will often have a different MAC address for each interface). You won't
be able to get the MAC address from a machine on the other side of
that device unless you use a special capability such as the port
mirroring described at
which provides messages on the monitoring port that mirror those on another port.
If any portion of the answer is unclear or incomplete, please make a
clarification request. I would be glad to add to the answer as needed.