President Barack Obama has asked US executives for closer cooperation in defending against hackers after major attacks on companies like Sony that exposed weaknesses in US cyber defences.

Speaking at Stanford University on Friday, Obama told Silicon Valley and financial services CEOs that they needed to share more information more quickly both with each other and with his administration.

"Government cannot do this alone. But the fact is that the private sector can't do it alone either because it's government that often has the latest information on new threats," he told a gathering of CEOs.

Obama has moved cybersecurity towards the top of his 2015 agenda after the recent breaches but senior figures from the tech world who are at odds with the administration over government surveillance stayed away from his speech.

The Sony attack was particularly worrying for US officials, who blamed North Korea for stealing data, debilitating computers and pressuring the studio to halt the release of The Interview, a satirical film about leader Kim Jong-un.

"There's only one way to defend America from these cyber threats and that is through government and industry working together, sharing appropriate information as true partners," Obama said.

He privately met a small group of business leaders in Silicon Valley to try to mend fences with tech companies still smarting over damage to their businesses when government surveillance practices were exposed by Edward Snowden, former National Security Agency contractor.

Upset about the lack of reforms to surveillance programmes, the CEOs of Google, Facebook and Yahoo stayed away from Friday's conference.

Tim Cook, Apple's chief executive, gave an address and CEOs from PayPal, Intel Corporation, Visa and other financial services companies attended, where Cook warned about unspecified threats to privacy.

"We still live in a world where not all people are treated equally. Too many people are not free to practise their religion, or speak their mind, or love who they choose," Cook said.

"If those of us in positions of responsibility fail to do everything in our power to protect the right to privacy, we risk far more than money ... we risk our way of life."

Source: Reuters