Hanley is a full international who has played his club football for the likes of Radcliffe, Chorley and Northampton Town.
18-year-old Rooney, meanwhile, will gain further experience in men's football away from the League One side.
He won U18s Player of the Year at the Shrimps last season.
The pair could go straight into contention this weekend as Linnets welcome Glossop North End to the APEC Taxis Stadium.
Keep up-to-date with our exclusive email newsletters.
Subscribe