From e8ab4d2957681932aea6fb9f979662b77c6c1da7 Mon Sep 17 00:00:00 2001 From: Philipp Keck Date: Sun, 9 Nov 2025 13:00:32 +0100 Subject: [PATCH] =?UTF-8?q?Log=20a=20warning=20when=20R=C3=BCckmeldungscod?= =?UTF-8?q?e=209391=20is=20received?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/Fhp/FinTs.php | 10 ++++++++++ lib/Fhp/Segment/HIRMS/Rueckmeldungscode.php | 8 ++++++++ 2 files changed, 18 insertions(+) diff --git a/lib/Fhp/FinTs.php b/lib/Fhp/FinTs.php index e69ef2af..bd0f6d6e 100644 --- a/lib/Fhp/FinTs.php +++ b/lib/Fhp/FinTs.php @@ -375,6 +375,16 @@ private function processServerResponse(BaseAction $action, Message $response): v if ($action instanceof PaginateableAction && $action->hasMorePages()) { $this->execute($action); } + + // Check whether the server requested a Kundensystem-ID refresh. + if ($response->findRueckmeldung(Rueckmeldungscode::NEUE_KUNDENSYSTEM_ID_HOLEN) !== null) { + // TODO Properly implement the refresh here, see https://github.com/nemiah/phpFinTS/issues/458. + $this->logger->warning( + 'The server asked us to refresh the Kundensystem-ID in response to a ' . gettype($action) . + ' action, but that is not implemented yet. This could result in authentication errors or extraneous ' . + ' re-authentication prompts from the bank.' + ); + } } /** diff --git a/lib/Fhp/Segment/HIRMS/Rueckmeldungscode.php b/lib/Fhp/Segment/HIRMS/Rueckmeldungscode.php index 8136e0d3..d401cbbb 100644 --- a/lib/Fhp/Segment/HIRMS/Rueckmeldungscode.php +++ b/lib/Fhp/Segment/HIRMS/Rueckmeldungscode.php @@ -2,6 +2,8 @@ namespace Fhp\Segment\HIRMS; +use Fhp\Protocol\DialogInitialization; + /** * Enum for the response codes that the server can send. * @@ -128,6 +130,12 @@ public static function isError(int $code): bool */ public const TEILWEISE_FEHLERHAFT = 9050; + /** + * Neue Kundensystem-ID anfordern. + * Als Antwort auf eine Dialoginitialisierungsnachricht ({@link DialogInitialization}). + */ + public const NEUE_KUNDENSYSTEM_ID_HOLEN = 9391; + /** * Kreditinstitutsseitige Beendigung des Dialoges */