Compare commits

..

No commits in common. "7c617dc32698f3b0b1322ebafe263eeb8004bfde" and "d67cd197941729e37b7b9dc238b2e3a8316ed00d" have entirely different histories.

View file

@ -221,22 +221,18 @@ foreach ($raw_array as $sub_array)
* *
* Add info * Add info
* 1. generation time (now), * 1. generation time (now),
* 2. expire time (now + 3 days), * 2. expire time (now+7d),
* 3. number of routes * 3. number of routes
*
* Numbers must be unquoted integers, and timeformat must
* be epoch format. TImezone is set to Etc/UTC.
*/ */
$roaRegistryCount = (int)count($roas["roas"]); $roaFileCreated = (int)( date_format( new \DateTime( "now", new \DateTimeZone( "UTC" ) ), "U" ) );
$roaFileDateTimeCreated = (int)( date_format( new \DateTime( "now", new \DateTimeZone( "UTC" ) ), "U" ) ); $roaFileExpire = (int)( date_format( date_modify( new \DateTime( "now", new \DateTimeZone( "UTC" ) ), "+3 day" ), "U" ) );
$roaFileDateTimeExpire = (int)( date_format( date_modify( new \DateTime( "now", new \DateTimeZone( "UTC" ) ), "+3 day" ), "U" ) );
$roas["metadata"]["counts"] = $roaRegistryCount; $roas["metadata"]["counts"] = (int)count($roas["roas"]);
$roas["metadata"]["generated"] = $roaFileDateTimeCreated; $roas["metadata"]["generated"] = $roaFileCreated;
$roas["metadata"]["valid"] = $roaFileDateTimeExpire; $roas["metadata"]["valid"] = $roaFileExpire;
/* /*
$roas["metadata"]["signature"] = ""; $roas["metadata"]["signature"] = "";
$roas["metadata"]["signatureData"] = ""; $roas["metadata"]["signatureData"] = "";
*/ */