install on custom port and AuthLogRecord

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • item
    Active Community Member
    • Mar 2017
    • 1476

    install on custom port and AuthLogRecord

    Hi,
    it's just a basic question, who use espocrm on non default port ( other than 80 or 443) (of course 443 is default) ?
    i have just remark that :

    application/Espo/Core/Authentication/Authentication.php
    line +- : 590

    PHP Code:
    $requestUrl =
                $request->getUri()->getScheme() . '://' .
                $request->getUri()->getHost() .
                $request->getUri()->getPath();
    
            if (!$username && $user) {
                $username = $user->getUserName();
            }
    
            $authLogRecord
                ->setUsername($username)
                ->setIpAddress($this->util->obtainIpFromRequest($request))
                ->setRequestTime($request->getServerParam('REQUEST_TIME_FLOAT'))
                ->setRequestMethod($request->getMethod())
                ->setRequestUrl($requestUrl)
                ->setAuthenticationMethod($method)
                ->setPortalId($this->isPortal() ? $this-
    don't take the port, so in AuthLogRecord, the port is missing.

    solution is add : $request->getUri()->getPort()

    but it's this important ? that is the question.
    for me not.


    Attached Files
    Last edited by item; 08-17-2023, 07:09 PM.
    If you could give the project a star on GitHub. EspoCrm believe our work truly deserves more recognition. Thanks.​
Working...