MySQL LOCAL INFILE has been leveraged to perform file exfiltration in the past.
Official documentation advise to disable this capability unless it is explicitly enabled.
To avoid LOAD DATA issues, clients should avoid using LOCAL unless proper client-side precautions have been taken.
May you consider disabling LOCAL INFILE by default in future mysql2 releases?
Following the affected code that in null-y case will default to 1 (enabled)
case MYSQL_OPT_LOCAL_INFILE:
intval = (value == Qfalse ? 0 : 1);
retval = &intval;
break;
MySQL LOCAL INFILE has been leveraged to perform file exfiltration in the past.
Official documentation advise to disable this capability unless it is explicitly enabled.
May you consider disabling
LOCAL INFILEby default in futuremysql2releases?Following the affected code that in null-y case will default to
1(enabled)