-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cellRtc: some improvements #15408
cellRtc: some improvements #15408
Conversation
Megamouse
commented
Apr 5, 2024
- implement Rfc3339 part of cellRtcParseDateTime
- simplify cellRtcParseRfc3339
- return a value in cellRtcGetCurrentSecureTick
I actually implemented cellRtc ~90% a year ago or so but didn't have time to finish it and just kinda forgot about it. Also here is my Ghidra export, maybe this is useful for you (doesn't include the actual binary, don't worry): |
a2e0382
to
5b5f3b9
Compare
This would have increased pos by one too many.
@@ -1189,6 +1187,8 @@ error_code cellRtcGetCurrentSecureTick(vm::ptr<CellRtcTick> tick) | |||
|
|||
// TODO | |||
|
|||
tick->tick = 0xe01d003a63a000; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can use cellRtcGetCurrentTick() for now if you want.
The syscall here returns the hardware clock corrected for drift. It is unaffected by the date and time settings in the XMB/VSH settings, which makes it "secure" I guess.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not gonna add stuff I haven't personally confirmed and I'm not gonna look into this any more for now.
I went over the decompilation for cellRtcParseRfc3339() again and your implementation seems correct. You can actually change the log level to notice, as there is nothing more to add I believe. Edit: not quite, see below |