Two Hamas officials returning from Egypt were caught trying to cross the Gaza border Tuesday with nearly $850,000 stuffed into candy tins, an Egyptian security official said. Gaza's Hamas rulers are dependent on the smuggling of cash and goods to keep their government afloat because the coastal territory has been subject to an embargo since the Islamic group took control there in June 2007. The two Hamas members were in Egypt with a delegation taking part in reconciliation talks with rival Palestinian factions. The talks being mediated by Egypt have so far failed to produce an agreement on the formation of a unity government that would include Hamas and the more moderate Fatah movement that it ousted from Gaza. In response to the Hamas takeover of Gaza, Israel and Egypt have kept the territory's borders sealed to all but a trickle of aid and supplies, forcing Hamas to smuggle cash across the border. The Hamas officials stopped Tuesday were traveling in a bus carrying members of different Palestinian factions involved in the reconciliation talks. A search of the bus at the border turned up the tins of sweets stuffed with â‚¬454,000 and $260,000 in cash instead of candy, said an Egyptian security official. He spoke on condition of anonymity because he was not authorized to speak to the media. Under Egyptian law, it is illegal to leave the country with more than $10,000 in cash. Authorities also confiscated two generators, a night vision scope and mobile phones, the official said. Hamas will be allowed to deposit the money into an account in Egypt, but likely won't be able to access the funds from Gaza. Arab banks have generally refused to transfer money to Gaza for fear of running afoul of the United States, which considers Hamas a terrorist organization. The two men stopped Tuesday were not arrested and denied knowing what was in the candy tins, saying they were just told to carry the goods into Gaza by Hamas leaders in Egypt, the official said. There was no immediate comment from Hamas. In February, Hamas members were caught with suitcases containing $9 million and â‚¬2 million in cash.