-
Notifications
You must be signed in to change notification settings - Fork 145
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
Seperate admin calls into seperate package #59
Comments
I understand your issue. Since you're using this in a dedicated schema for your entire database is it an issue that people are setting/unsetting it often? If the issue is on a dev machine I'd recommend leaving it unlocked and let developers have control of it. That being said it should probably remain in debug mode for dev instances. If the issue is on prod machines I completely agree that you don't want everyone changing the system level configurations. Perhaps instead they can turn on client specific logging levels (see http://www.talkapex.com/2013/05/logger-200-enable-session-specific.html) Though currently this still requires admin access. I'm hesitant to create an entirely new package/procedure for admin functions but am open to removing the admin check on client specific logging. Would that work for you? If you still need more specific fine grained security perhaps you could leave PROTECT_ADMIN_PROCS on. In UTL_LOGGER you can then create a custom package to manage all the admin calls and then grant execute access to specific users. You would only need to do this once and is fairly easy to implement. Please let me know what you do and if you want to move the client specific logging outside of admin privileges. |
Yes, I have set at DEBUG level on non-production databases, and INFO on production databases. We should not change this very often (if ever), if I do, then I normally update the logger_prefs table directly. Although that is not ideal, as I don't think there is any validation of value using that method. Yes you are correct about creating a separate package, I hadn't considered that. Removing admin check for client logging would probably get me what I want, ie allow developers to change logging for testing without allowing change to entire database. Could you a little explain the reasoning for not wanting an extra package. Is it because normally people will install to application schema and you want to keep namespace pollution to minimum? |
Starting in 2.2.0 I have changed it that admin_security_checks get bypassed for set_level when setting it for a client specific session. This allows developers to change 1 session but not affect the entire database. I think this is a happy medium. Before introducing another package I really want to see why I want to do it. It's also another package to support etc. We may introduce another package in the near future but for very specific reasons. |
This issue was moved to OraOpenSource#60 |
We have logger installed into dedicated schema (UTL_LOGGER), and have locked this schema for security. I believe my options for changing settings (via logger.set_level) are as follows:
Suggest a better way would be to separate the admin functions into a seperate package (LOGGER_CONFIG/LOGGER_ADMIN/????). Execute permission could then be granted or revoked on this package using standard Oracle security. I think in that case, the PROTECT_ADMIN_PROCS mechanism could be removed, simplifying the code.
The text was updated successfully, but these errors were encountered: