I want to lock some fields/columns in a MySQL-Database, is this somehow possible?
Backgorund: We are using Revive also known as OpenX (of course the latest version) but it get hacked all the time. Especially the fields prepend
and append
in the ox_zone
table.
What we already did to secure the system:
adxmlrpc.php
Because its known as entry point for attackersBut still sometimes the columns prepend
and append
are compromised, so I thought it would be great if we could lock these fields or set them to read only.
But I am of course up for any other solution.
Move your mouse over the "Read Only" text to fix the read-only table in MySQL Workbench.
You can set privileges on the column-level (and therefore only grant SELECT and INSERT) to the user that needs to be on read-only :
GRANT SELECT (column), INSERT (column) ON table TO user;
By replacing column
, table
and user
with the appropriate values. GRANT documentation
You also need to be sure not to grant higher levels (table, data or global) privileges otherwise it would override the table-level privilege.
Best,
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With