Could I implement a new script engine in my plugin but limit the access only in the plugin

I have a custom plugin with a custom script engine, how could I limit the access scope of the script engine only in my plugin? How to make other plugins in Elasticsearch not able to submit the new type of script?