Closed
Description
Describe the bug
The service keeps authenticating over again
See logs
2023-07-11 13:23:02,236|I| ############ Starting IBeam version 0.4.6 ############
2023-07-11 13:23:02,264|I| Secrets source: env
2023-07-11 13:23:02,276|I| Health server started at port=5001
2023-07-11 13:23:02,276|I| Environment variable configuration:
{'INPUTS_DIR': '/srv/inputs/', 'OUTPUTS_DIR': '/srv/outputs', 'GATEWAY_DIR': '/srv/clientportal.gw', 'CHROME_DRIVER_PATH': '/usr/bin/chromedriver', 'GATEWAY_STARTUP': 20, 'GATEWAY_PROCESS_MATCH': 'ibgroup.web.core.clientportal.gw.GatewayStart', 'MAINTENANCE_INTERVAL': 60, 'SPAWN_NEW_PROCESSES': False, 'LOG_LEVEL': 'INFO', 'LOG_TO_FILE': True, 'LOG_FORMAT': '%(asctime)s|%(levelname)-.1s| %(message)s', 'REQUEST_RETRIES': 1, 'REQUEST_TIMEOUT': 15, 'RESTART_FAILED_SESSIONS': True, 'RESTART_WAIT': 15, 'REAUTHENTICATE_WAIT': 15, 'IBEAM_HEALTH_SERVER_PORT': 5001, 'GATEWAY_BASE_URL': 'https://localhost:5000', 'ROUTE_AUTH': '/sso/Login?forwardTo=22&RL=1&ip2loc=on', 'ROUTE_USER': '/v1/api/one/user', 'ROUTE_VALIDATE': '/v1/portal/sso/validate', 'ROUTE_REAUTHENTICATE': '/v1/portal/iserver/reauthenticate?force=true', 'ROUTE_AUTH_STATUS': '/v1/api/iserver/auth/status', 'ROUTE_TICKLE': '/v1/api/tickle', 'ROUTE_LOGOUT': '/v1/api/logout', 'USER_NAME_EL': None, 'PASSWORD_EL': 'password', 'SUBMIT_EL': 'button.btn.btn-lg.btn-primary', 'ERROR_EL': None, 'SUCCESS_EL_TEXT': 'Client login succeeds', 'OAUTH_TIMEOUT': 15, 'PAGE_LOAD_TIMEOUT': 15, 'ERROR_SCREENSHOTS': False, 'MAX_FAILED_AUTH': 2, 'MIN_PRESUBMIT_BUFFER': 5, 'MAX_PRESUBMIT_BUFFER': 30, 'MAX_IMMEDIATE_ATTEMPTS': 10, 'IBKEY_PROMO_EL_CLASS': 'ibkey-promo-skip', 'TWO_FA_EL_ID': 'twofactbase', 'TWO_FA_NOTIFICATION_EL': 'login-step-notification', 'TWO_FA_INPUT_EL_ID': 'chlginput', 'TWO_FA_HANDLER': None, 'STRICT_TWO_FA_CODE': True, 'TWO_FA_SELECT_EL_ID': 'sf_select', 'TWO_FA_SELECT_TARGET': 'IB Key'}
2023-07-11 13:23:02,277|I| Gateway not found, starting new one...
2023-07-11 13:23:02,277|I| Note that the Gateway log below may display "Open https://localhost:5000 to login" - ignore this command.
2023-07-11 13:23:02,277|I| Starting Gateway as Linux process with params: ['bash', 'bin/run.sh', 'root/conf.yaml']
running
runtime path : root:dist/ibgroup.web.core.iblink.router.clientportal.gw.jar:build/lib/runtime/*
config file : root/conf.yaml
2023-07-11 13:23:03,310|I| Gateway started with pid: 14
2023-07-11 13:23:03,349|I| Cannot ping Gateway. Retrying for another 20 seconds
2023-07-11 13:23:04,351|I| Cannot ping Gateway. Retrying for another 19 seconds
2023-07-11 13:23:05,353|I| Cannot ping Gateway. Retrying for another 18 seconds
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by io.netty.util.internal.ReflectionUtil (file:/srv/clientportal.gw/build/lib/runtime/netty-common-4.1.15.Final.jar) to constructor java.nio.DirectByteBuffer(long,int)
WARNING: Please consider reporting this to the maintainers of io.netty.util.internal.ReflectionUtil
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
2023-07-11 13:23:06,355|I| Cannot ping Gateway. Retrying for another 17 seconds
-> mount demo on /demo
Java Version: 11.0.18
****************************************************
version: 485dc2d762781c4ff3954ac4fb66a9469a1405f7 Mon, 20 Mar 2023 14:39:35 -0400
****************************************************
This is the Client Portal Gateway
for any issues, please contact [email protected]
and include a copy of your logs
****************************************************
https://www.interactivebrokers.com/api/doc.html
****************************************************
Open https://localhost:5000 to login
App demo is available after you login under: https://localhost:5000/demo#/
2023-07-11 13:23:07,357|I| Cannot ping Gateway. Retrying for another 16 seconds
2023-07-11 13:23:09,883|I| Gateway connection established
2023-07-11 13:23:10,327|I| No active sessions, logging in...
2023-07-11 13:23:10,328|I| Loading auth webpage at https://localhost:5000/sso/Login?forwardTo=22&RL=1&ip2loc=on
2023-07-11 13:23:24,075|I| Gateway auth webpage loaded
2023-07-11 13:23:24,076|I| Login attempt number 1
2023-07-11 13:23:29,382|I| Submitting the form
2023-07-11 13:23:30,518|I| Webpage displayed "Client login succeeds"
2023-07-11 13:23:32,518|I| Cleaning up the resources. Display: <pyvirtualdisplay.display.Display object at 0x7ff51f7c5710> | Driver: <selenium.webdriver.chrome.webdriver.WebDriver (session="2d8b3814bcca3a5462cc61b02ad8b650")>
2023-07-11 13:23:32,852|I| Authentication process succeeded
2023-07-11 13:23:35,961|E| Gateway session active but not authenticated
2023-07-11 13:23:35,982|I| Waiting 15 seconds to reauthenticate before restarting.
2023-07-11 13:23:50,983|I| Logging out and restarting the Gateway
2023-07-11 13:23:51,087|I| Gateway logout successful
2023-07-11 13:23:51,150|I| Gateway session found but not authenticated, authenticating...
2023-07-11 13:23:51,150|I| Loading auth webpage at https://localhost:5000/sso/Login?forwardTo=22&RL=1&ip2loc=on
2023-07-11 13:23:58,688|I| Gateway auth webpage loaded
2023-07-11 13:23:58,688|I| Login attempt number 1
2023-07-11 13:24:03,995|I| Submitting the form
2023-07-11 13:24:05,098|I| Webpage displayed "Client login succeeds"
2023-07-11 13:24:07,099|I| Cleaning up the resources. Display: <pyvirtualdisplay.display.Display object at 0x7ff51f7e9d50> | Driver: <selenium.webdriver.chrome.webdriver.WebDriver (session="7c6cc168602cedd44c23b3d5ba6da3fb")>
2023-07-11 13:24:07,129|I| Authentication process succeeded
2023-07-11 13:24:10,190|E| Gateway session active but not authenticated
2023-07-11 13:24:10,206|I| Waiting 15 seconds to reauthenticate before restarting.
Environment
IBeam version: the latest
Docker image or standalone: Docker
Additional context
The login info is correct, can login on the IB web site.