Jump to content
  • entries
    18
  • comments
    89
  • views
    3,972

Засвет пароля от mysql

Sign in to follow this  
Yoda

2,207 views

А знаете вы, что в классе Mysqli, при включенных ошибках и отсутствии коннкета к базе светится пароль базы?
А знаете вы что Даниэль сказал, что это не баг а фича ?

https://github.com/opencart/opencart/issues/5027

  • +1 3
Sign in to follow this  


3 Comments


Recommended Comments

кому надо, исправляется вот так:

в mysqli.php это:


		if ($this->connection->connect_error) {
			throw new \Exception('Error: ' . $this->connection->error . '<br />Error No: ' . $this->connection->errno);
		}

заменить по аналогии на это:

		if ($this->connection->connect_error) {
			trigger_error('Error: Could not make a database link (' . $this->connection->connect_errno . ') ' . $this->connection->connect_error);
			exit();
		}

 

  • +1 2

Share this comment


Link to comment

если set error display to off, то как понять что у тебя возникли проблемы? постоянно мониторить error log?

Share this comment


Link to comment
Guest
You are posting as a guest. If you have an account, please sign in.
Add a comment...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    No registered users viewing this page.

×

Important Information

On our site, cookies are used and personal data is processed to improve the user interface. To find out what and what personal data we are processing, please go to the link. If you click "I agree," it means that you understand and accept all the conditions specified in this Privacy Notice.