You will need to define the "Cookie Jar" to allow NROD to set the session cookie and redirect to the AWS S3 bucket. This should help you out.
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, '
https://datafeeds.networkrail.co.uk/ntrod/SupportingFileAuthenticate?type=CORPUS');
curl_setopt($ch, CURLOPT_VERBOSE, 1);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
// update here per requirements... jobs/threads....
curl_setopt($ch, CURLOPT_COOKIEJAR, tempnam('/tmp', 'nrod-cookie'));
curl_setopt($ch, CURLOPT_USERPWD, $username . ":" . $password);
$result = curl_exec($ch);
curl_close($ch);
$json = gzdecode($result);
var_dump(json_decode($json, true));