Fixes for MySQL
Started authentication
Added authorization checks