The Library of Congress email systems were hacked earlier this year by a “foreign adversary,” officials confirmed Sunday.