is it possible to access the User/User Id from within a NiFi Processor?
I plan to develop a custom processor and I would like to change its behaviour according to the access rights of the current User.
For example a user should only be allowed to consume from a topic he has the access rights to.
None of the NiFi processor ever execute as the user who is logged in. There is one JVM which executes the code for all processors running on the NiFi canvas regardless of whom added them.
The NiFi authorization policies govern what interaction with the canvas are allowed for a given authenticated user.
NiFi also does not use sessions so there is no notion of a "current user". Every single request to NiFi must contain user authorization.
Not sure how you intent to code your custom processor to obtain a specific users access rights to a topic. Problem one is determining which user account to use. There could be multiple users "logged in" to the same NIFi UI.
@Matt Clarke laid it all out correctly, but I would add that usually the external system you are connecting to (sounds like you are talking about kafka) has authentication and authorization concepts so that is where the permissioning happens.