It is allowed. There is no callback function, but your plugin can use add_buffer. Files are looked for first in the buffers, then in the path and then in the WRS. Some files, for instance media files, are not opened by the engine, so you can't use your plugin for them.