I thought a data packet from another subnet is always rejected. But when I have two hosts (h1 and h2) in two different subnets (s1 and s2) and one router (r) with activated ip_forward and access to both subnets, I can ping h1 from h2. I understand how the packet is routed to h1, but I don't understand why h1 is accepting a packet from another subnet. If masquerading is done all is clear to me. But without masquerading I can not understand it.
Does this mean that in TCP/IP protocol a packet from another subnet is always accepted if it reaches the host? So the problem without router is only that the sending host is not sending a packet with destination in another subnet?