-
-
Notifications
You must be signed in to change notification settings - Fork 14.8k
Tracking issue for stabilizing Error::type_id #60784
Copy link
Copy link
Open
Labels
A-error-handlingArea: Error handlingArea: Error handlingB-unstableBlocker: Implemented in the nightly compiler and unstable.Blocker: Implemented in the nightly compiler and unstable.C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCCategory: An issue tracking the progress of sth. like the implementation of an RFCLibs-TrackedLibs issues that are tracked on the team's project board.Libs issues that are tracked on the team's project board.PG-error-handlingProject group: Error handling (https://github.com/rust-lang/project-error-handling)Project group: Error handling (https://github.com/rust-lang/project-error-handling)T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.
Metadata
Metadata
Assignees
Labels
A-error-handlingArea: Error handlingArea: Error handlingB-unstableBlocker: Implemented in the nightly compiler and unstable.Blocker: Implemented in the nightly compiler and unstable.C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCCategory: An issue tracking the progress of sth. like the implementation of an RFCLibs-TrackedLibs issues that are tracked on the team's project board.Libs issues that are tracked on the team's project board.PG-error-handlingProject group: Error handling (https://github.com/rust-lang/project-error-handling)Project group: Error handling (https://github.com/rust-lang/project-error-handling)T-libs-apiRelevant to the library API team, which will review and decide on the PR/issue.Relevant to the library API team, which will review and decide on the PR/issue.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Updated Issue
This is a tracking issue for stabilizing the functionality of
Error::type_idsomehow. The subject of a historical security advisory the API was recently changed to prevent memory unsafety issues on all channels including nightly. The functionality, however, is still unstable, so we should stabilize it at some point!Original issue.
Reported by @seanmonstar to the security mailing list recently, it was discovered that the recent stabilization of
Error::type_idin Rust 1.34.0 is actually not memory safe. Described in a recent security announcement the stabilization ofError::type_idhas been reverted for stable, beta, and master.This leaves us, however, with the question of what to do about this API?
Error::type_idhas been present since the inception of theErrortrait, all the way back to 1.0.0. It's unstable, however, and is pretty rare as well to have a manual implementation of thetype_idfunction. Despite this we would ideally still like a path to stability which includes safety at some point.This tracking issue is intended to serve as a location to discuss this issue and determine the best way forward to fully removing
Error::type_id(so even nightly users are not affected by this memory safety issue) and having a stable mechanism for the functionality.