It seems that you have provided the answer to your own question. With OSPF as with some other protocols when you configure a summary address the IOS creates a route for the summary address pointed at null0. The purpose for this is to prevent looping as you have said.
If we look more closely at the logic it is like this: you will be advertising the summary route to your neighbors, for example 22.214.171.124/24 which tells your neighbors that if they need to get to that network that they should forward to you and you can get to the destination. Lets assume that your router has learned these subnets from its OSPF neighbors 126.96.36.199/26, 188.8.131.52/26, and 184.108.40.206/26 but it does not have a route to 220.127.116.11/26 (which includes the 18.104.22.168 address). If a neighbor forwards to your router a packet with destination 22.214.171.124 what should you do? Lets also assume that you have learned your default route from that neighbor. If you forward toward your default route it would be forwarding back to the neighbor who sent you the packet and a loop is created. So OSPF creates the null0 route so that if you do not know how to forward to the destination address you will discard the packet.
I'm working on a project that includes basic router configurations. I configurated everything including: line console 0, line vty 0 15 and secret passwords. There are 3 routers in the network and every LAN is going t...
Desire to create Terminal Server ("TS" in this document) out of 2811 Cisco Router with HWIC-16A card (with Octal cables)
Desire to use SSH over Telnet
TS is ip'ed, SSH access configured (to the TS)
Python based Script to BULK Import/Delete devices using Cisco Prime API
Check my Repo on GitHub for all the details ( see below link )