His farewell speech at an Independence Day reception spotlighted U.S. alarm over the jailing of pro-democracy figures under the law, prompting a rare public rebuke from Hong Kong authorities.