I've been practicing some IPSec VPN scenarios, starting with the typical site-to-site VPN:
Router A
crypto map mymap 10 ipsec-isakmp
set peer 1.1.1.2
set transform-set myset
match address 101
access-list 101 permit ip 10.1.1.0 0.0.0.255 10.1.2.0 0.0.0.255
Router B
crypto map mymap 10 ipsec-isakmp
set peer 1.1.1.1
set transform-set myset
match address 101
access-list 101 permit ip 10.1.2.0 0.0.0.255 10.1.1.0 0.0.0.255
This works as expected. Traffic from 10.1.1.x on Router A gets picked up by the crypto map and sent to RouterB and vice versa. What is confusing me is a more advanced scenario where I'm tunnelling GRE over IPSec with OSPF (why? Because I can).
http://www.cisco.com/en/US/tech/tk583/tk372/technologies_configuration_example09186a008009438e.shtml
Everything works just fine, but I'm bothered by the ACLs being used in the example. I don't see how everthing should be working- OSPF is fat and happy, and if I ping one spoke from another spoke from a loopback interface, it works as well. In this case, is the network traffic being picked up by the Tunnel interface first, and all the crypto map sees is GRE traffic by the time the packets make it that far?