The Washington, DC law doesn't apply to people passing through:
Originally Posted By: https://www.nraila.org/articles/20150101/guide-to-the-interstate-transportation
the certificate requirement for possession of firearms and ammunition does not apply to non-residents who are “participating in any lawful recreational firearm-related activity within the District, or on [their] way to or from such activity in another jurisdiction.” To qualify for this exception, a person must, upon demand of a law enforcement officer, “exhibit proof that he is on his way to or from such activity” and that the person’s possession of the firearm is lawful in the person’s place of residence.

The exception here may be a bit squishy-sounding but if you're diverted to a DC airport you're either in Virginia (DCA and IAD) or Maryland (BWI), so the DC law wouldn't apply to you anyway.

The FOID law in Illinois has a big exception that applies to air travelers:
Originally Posted By: (430 ILCS 65/2) (from Ch. 38, par. 83-2)
...
(b) The provisions of this Section regarding the possession of firearms, firearm ammunition, stun guns, and tasers do not apply to:
...
(9) Nonresidents whose firearms are unloaded and enclosed in a case;

Another Google search reveals that flying into and out of Chicago airports with declared firearms in checked baggage is a non-issue.

I was imprecise earlier in that I didn't exclude international destinations; I meant only US airports.