50 votes5 comments · [Closed] Entity Framework Core Feature Suggestions · Flag idea as inappropriate… · Admin →
Resetting status to reflect current state of EF Core. Some of this functionality is available to EF6-based applications: only access to store DbExpression trees and DbCommand are available, and there are no plans for adding a LINQ level interception point.Mohammad M commented
I believe it would be much beneficial if it was possible to intercept queries like, select, where etc.
The important thing for me would be that when intercepting, then the query result should be viewable.
I need this to make security check regarding if the user querying the database also has access right the data he querying.
This is unfortunately not possible now using interception e.g.:
var listener = _context.GetService<DiagnosticSource>();
(listener as DiagnosticListener).SubscribeWithAdapter(new CommandListener());
using commercial tools like postSharp to do this is not the way I want to go.Mohammad M supported this idea ·