In 2001, Congress passed an Authorization for the Use of Military Force (AUMF), allowing the president “to use all necessary and appropriate force against those nations, organizations, or persons he determines planned, authorized, committed, or aided the terrorist attacks that occurred on September 11, 2001, or harbored such organizations or persons.”
Which means that if the Trump administration truly believes Iran and al-Qaeda have been in cahoots before or after 9/11, then it could claim war with Tehran already is authorized by law.