Skip to content
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

Block usage of default interfaces feature in COM scenarios #23970

Merged
merged 6 commits into from Apr 19, 2019

Conversation

AaronRobinsonMSFT
Copy link
Member

@AaronRobinsonMSFT AaronRobinsonMSFT commented Apr 13, 2019

Block usage of default interfaces within a COM scenario. This accomplished by validating any interface that is being passed into the COM world only contains abstract methods.

Tests:

  • Validate activation as an IUnknown
  • Validate manual activation via IClassFactory
  • Validate activation failing as an interface containing non-abstract methods
  • Validate activation from an interface with all abstract methods but class does implement an interface that contains non-abstract methods
  • Validate QueryInterface() fails when requesting an interface with non-abstract methods

Fixes #15683

cc @MichalStrehovsky @davidwrighton @jkoritzinsky @jeffschwMSFT

Copy link
Member

@davidwrighton davidwrighton left a comment

Changes to the type system look good. Changes to interop look fine to my somewhat unpracticed eye.

@AaronRobinsonMSFT
Copy link
Member Author

@AaronRobinsonMSFT AaronRobinsonMSFT commented Apr 18, 2019

@davidwrighton et al Also note that I ran all COM tests through GCStress and verified no issues and manually confirmed no memory leaks during COM object activation.

@AaronRobinsonMSFT
Copy link
Member Author

@AaronRobinsonMSFT AaronRobinsonMSFT commented Apr 19, 2019

@dotnet-bot test Ubuntu arm Cross Checked crossgen_comparison Build and Test please
@dotnet-bot test Ubuntu arm Cross Release crossgen_comparison Build and Test please

@AaronRobinsonMSFT AaronRobinsonMSFT merged commit df6b6f6 into dotnet:master Apr 19, 2019
41 checks passed
@AaronRobinsonMSFT AaronRobinsonMSFT deleted the coreclr_15683 branch Apr 19, 2019
picenka21 pushed a commit to picenka21/runtime that referenced this issue Feb 18, 2022
…reclr#23970)

* Block default interface usage in COM scenarios

Add additional test cases and move some CCW functions to a more
consolidated layout.


Commit migrated from dotnet/coreclr@df6b6f6
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants