Skip to content

Access checks in JIT interface methods #13392

Closed

Description

@nattress

The final section of CEEInfo::getCallInfo (https://github.com/dotnet/coreclr/blob/5f93d3b1c48ba6916d5f31d79cb7c17d564eecef/src/vm/jitinterface.cpp#L5597) deals with access checks validating the declarative authority of a given caller to call the callee. This is currently missing in the CPAOT compiler. Similar checks needed in CEEInfo::getFieldInfo.

Activity

  1. transferred this issue fromdotnet/coreclron Jan 31, 2020
  2. added this to the 5.0 milestone on Jan 31, 2020
  3. davidwrighton commented on Jul 10, 2020

    @davidwrighton
    Member

    This isn't needed for the 5.0 release.

  4. modified the milestones: 5.0.0, 6.0.0 on Jul 10, 2020
  5. trylek commented on Feb 7, 2021

    @trylek
    Member

    I believe we need to either address this for the .NET 6 shipping release or at least convince ourselves that we don't need to. I think we do because silently violating access rights while emitting the R2R native image violates the principle of R2R vs. JIT equivalence. @jkotas, could you please correct me if I'm wrong?

  6. jkotas commented on Feb 8, 2021

    @jkotas
    Member

    Violating visibility rules is invalid IL. In general, invalid IL can lead to observable behavior difference between AOT and JIT, or between optimization levels. These differences are by design.

    I think that this is nice-to-fix. We should look at it together with all other types of invalid IL detection we can be doing. I think it would be fine to implement these additional checks reactively, only once somebody reports them as a problem.

  7. mangod9 commented on Jul 10, 2021

    @mangod9
    Member

    moving to 7 based on the discussion above.

  8. modified the milestones: 6.0.0, 7.0.0 on Jul 10, 2021
  9. davidwrighton commented on Jul 6, 2022

    @davidwrighton
    Member

    We don't need these.

  10. ghost locked as resolved and limited conversation to collaborators on Aug 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions