NY Times, the following applies to Illinois:
Although law-enforcement officials can legally record civilians in private or public, audio-recording a law-enforcement officer, state’s attorney, assistant state’s attorney, attorney general, assistant attorney general or judge in the performance of his or her duties is a Class 1 felony, punishable by up to 15 years in prison.
The A.C.L.U. filed its lawsuit after several people throughout Illinois were charged in recent years with eavesdropping for making audio recordings of public conversations with the police. The A.C.L.U. argued that the act violates the First Amendment and hinders citizens from monitoring the public behavior of police officers and other officials.