It’s a violation of US law to give money or arms to Hamas, but it NOT a violation of US law for the USA to give humanitarian aid to Palestinian civilians, through an agency such as UNRWA. And note here that Israel does not have ANY PROBLEM AT ALL in passing through humanitarian aid through their checkpoints and into Gaza.
In fact, just a couple of days ago, the Israeli Ambassador spoke at the UN Human Rights Council and said that Israel is not against the residents of Gaza, but Israel is against Hamas.
One further point here is that both the USA and Israel have given money and aid to the Palestinian Authority and it is not against the law in the USA to do that (with the PA). Hamas is listed officially in the USA as a “Foreign Terrorist Organization” but the Palestinian Authority is not.
The US under Obama is funding Hamas in blatant and flagrant violation of US law.
http://www.commentarymagazine.com/2014/06/04/not-first-time-palestinian-aid-violated-the-law/