-
Notifications
You must be signed in to change notification settings - Fork 98
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
Fix CI #561
Fix CI #561
Conversation
@@ -418,8 +418,8 @@ impl<W: Write> SgxsWrite for W { | |||
let mut buf = [0u8; 64]; | |||
unsafe { | |||
let (tag, headerdst) = buf.split_at_mut(8); | |||
let tag = &mut *(&mut tag[0] as *mut _ as *mut u64); | |||
let headerdst = &mut headerdst[0] as *mut _; | |||
let tag = &mut *(&mut tag[0..8] as *mut _ as *mut u64); |
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.
Wow, so new nightly compiler will warn this ?
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.
Yes it surprised me too!
let tag = &mut *(&mut tag[0] as *mut _ as *mut u64); | ||
let headerdst = &mut headerdst[0] as *mut _; | ||
let tag = &mut *(&mut tag[0..8] as *mut _ as *mut u64); | ||
let headerdst = &mut headerdst[0..56] as *mut _; |
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.
@raoulstrackx Where is this 56 byte size mentioned? I understand in the line above that 8 bytes translate to u64
, but what is this type?
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.
It's size comes from how MRENCLAVE is being measured. See the sgxs documentation and Intel Manual vol 3D ch 36.4.1.1 At the Rust code level, there isn't one an explicit type for it. Based on what's being added (ECreate
, Unsized
,...) different types are used.
CI is currently broken due to a more intelligent nightly compiler and warnings being treated as errors. This PR fixes these errors.
Fixes #560