MarVinPL / bank-api

Automatically exported from code.google.com/p/bank-api
1 stars 0 forks source link

Porpawka na "Alarm bezpieczeństwa! Nieprawidłowy Identyfikator lub Hasło..." #2

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Od wczoraj na siłę mBank prezentuje wybór nowy/stary serwis pod adresem 
https://www.mbank.com.pl i chyba po cookie rozpoznaje kto tam był.

Poprawka na to jest prosta:

w funkcji login() robimy tak:

        $this->readConfigFile();
        $this->setConnectionInfo('ssl://', 'www.mbank.com.pl', 443, 'https://www.mbank.com.pl');
        $this->connectToHost();
        $this->sendToHost('/', '/', 'http://www.mbank.pl/login/');
        $this->sendToHost('/', '/', 'http://www.mbank.pl/login/');

Original issue reported on code.google.com by eni...@gmail.com on 9 Oct 2013 at 1:02

GoogleCodeExporter commented 9 years ago
Dokładnie - dziś to samo dodałem, z później przeczyłem powyższy wpis. 
Potwierdzam to działa. Problemem jest mbank, który na siłę próbuje 
przepchnąć logowanie do nowej wersji serwisu. Natomiast w odniesieniu do 
wersji 0.5.1 należy dodać tylko

$this->sendToHost('/', '/');

Czyli 

    /**
     * Logowanie do systemu bankowości elektronicznej
     */
    public function login()
    {
        if (!file_exists($this->fileConfig)) exit(
        <<<EOF
        There's no config file.<br>
<br>Launch the script once using this example:
<pre>\$mbank = new API_mBank();
\$mbank->createConfigFile("Identyfikator", "Haslo");
</pre>
EOF
        );
        $this->readConfigFile();
        $this->setConnectionInfo('ssl://', 'www.mbank.com.pl', 443, 'https://www.mbank.com.pl');
        $this->connectToHost();
        $this->sendToHost('/', '/');
        $this->sendToHost('/', '/');
        $this->verifyContent();
        $this->_parseMainFormInputs();
        if (empty($this->config['customer']) || empty($this->config['password'])) {
            $this->exitMsg("Nieprawidłowy login lub hasło");
        }
        $addParams = array('customer' => $this->config['customer'], 'password' => $this->config['password']);
        $this->_prepareParams("", $addParams);
        $this->sendToHost('/logon.aspx', '/', $this->_params);
        $this->verifyContent(true);
        $this->clearData(false);
    }

Original comment by l.chol...@gmail.com on 10 Oct 2013 at 9:19

GoogleCodeExporter commented 9 years ago

Original comment by cer...@gmail.com on 14 Aug 2014 at 9:07

GoogleCodeExporter commented 9 years ago
mBank zaczął powoli wyłączać dostęp do starej wersji, od tygodnia mam 
dostęp tylko przez nową wersję

Original comment by triek...@gmail.com on 9 Oct 2014 at 9:14

GoogleCodeExporter commented 9 years ago
Witam,
z tego co widzę, to nadal jest dostępny - https://www.mbank.com.pl/logon.aspx 
(istnieje potrzeba dwa razy uruchomić ten adres).
Ale ma Pan rację - trzeba będzie przepisać skrypt pod nowy interfejs.
Zajmę się tym w najbliższym czasie (mam nadzieję, że do końca roku uda mi 
się to domknąć).
Pozdrawiam serdecznie.

Original comment by cer...@gmail.com on 9 Oct 2014 at 9:16