Here is a question I have asked in a lot of machine rooms, and the answer almost always comes with a pause when I ask “What is *PUBLIC authority set to on the library that holds your most sensitive data?”
The pause is the problem. Because *PUBLIC is the authority that applies to everyone who is not specifically granted something else, and on a surprising number of systems, the library holding payroll, or customer data, or financials, is sitting at *PUBLIC *CHANGE or even *ALL. Nobody decided that on purpose. It is almost always a default that came in when the library was created years or decades ago, and no one has looked since.
You can look right now. Point this at the library that matters most:
SELECT SYSTEM_OBJECT_NAME, OBJECT_TYPE, OWNER, OBJECT_AUTHORITY
FROM QSYS2.OBJECT_PRIVILEGES
WHERE SYSTEM_OBJECT_SCHEMA = 'YOURLIB' AND AUTHORIZATION_NAME = '*PUBLIC' ORDER BY OBJECT_AUTHORITY DESC, SYSTEM_OBJECT_NAME;
That shows you exactly what every object in that library grants to the public. Read it the way an auditor would, and the ones that say *CHANGE or *ALL are the ones to justify or fix.
Here is the principle I keep coming back to on security: a lock on the front door means nothing if the back door is standing open, and *PUBLIC is the back door almost nobody checks. You can have beautiful, carefully built private authorities and still be wide open, because the public authority underneath them quietly grants everyone the run of the place.
Pick your most sensitive library and run this today. Then do your second most sensitive one tomorrow. You will sleep better knowing, and if you do not like what you see, you will be very glad you looked before someone else did.
The job you save, maybe your own.
#IBMi #IBMCHAMPION
Originally posted on LinkedIn. Join the conversation there.
Leave a Reply