cookie maxAge和expiry之间有什么区别?

我在NodeJS,快递应用程序,我正在使用Cookie的一些function,我的应用程序。 我需要设置cookie的一个月的生活。

为此,我将cookie maxAge设置为days*hoursPerDay*minutesPerHour*secondsPerMinute*1000以实现一个月的时间30*24*60*60*1000 = 2592000000

然而,在我的cookies的浏览器到期时间接近10个小时。

我错过了什么,我的计算错了? 或者我正在使用错误的属性( maxAge )?

还有什么是cookies的maxAgeexpiry属性之间的区别?

maxAge应设置为毫秒(我错了,因为我提到客户端部分) https://developer.mozilla.org/en-US/docs/Web/API/document.cookie

你是否像下面设置苦力?

res.cookie('rememberme','1',{maxAge:900000,httpOnly:true}) http://expressjs.com/api.html#res.cookie

据我所知, maxAge不会保存在cookie的规格中。
由于不信任Cookie setMaxAge展示了, maxAge的机制就像更改/操作cookie的过期date(基于SERVER_SIDE),但浏览器检查cookie的到期date,基于CLIENT_SIDE。
从我的angular度来看,这是不良行为。 因为为了使max-age按预期工作,客户机/服务器的DateTime应该是同步的。