The CIA has been sharply criticized for intelligence failures leading up to the 2001 September 11 terrorist attacks and the Iraq war .