# New to cakePHP 5 - Auth problem

**URL:** <https://discourse.cakephp.org/t/new-to-cakephp-5-auth-problem/11711>\
**Category:** Need Help\
**Created:** [November 29, 2023, 5:44pm UTC](https://discourse.cakephp.org/t/new-to-cakephp-5-auth-problem/11711 "2023-11-29T17:44:48Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![eric](https://avatars.discourse-cdn.com/v4/letter/e/898d66/32.png) [@eric](https://discourse.cakephp.org/u/eric)\
**Post date:** [November 29, 2023, 5:44pm UTC](https://discourse.cakephp.org/t/new-to-cakephp-5-auth-problem/11711/1 "2023-11-29T17:44:48Z")

</div>

I’m trying to get a login page working on my newly-created site, but I’m having problems.

I keep getting this error:

object(Authentication\Authenticator\Result)#142 (3) { [“\_status”:protected]=\> string(26) “FAILURE\_IDENTITY\_NOT\_FOUND” [“\_data”:protected]=\> NULL [“\_errors”:protected]=\> array(1) { [“Password”]=\> array(0) { } } }

I’ve created a table called tUsers (which I noted in the Model).

I think the problem is with the authentication service, but I’m not sure. When I print out $authenticationServer, it’s blank:

```
    $authenticationService->loadIdentifier('Authentication.Password', [
        'fields' => [
            'username' => 'username',
            'password' => 'password',
        ],
    ]);

```

Can anyone help?

Thanks!

---

<div class="post-metadata">

**Author:** ![shadowx.jb](https://avatars.discourse-cdn.com/v4/letter/s/a88e4f/32.png) [@shadowx.jb](https://discourse.cakephp.org/u/shadowx.jb)\
**Post date:** [November 30, 2023, 8:02am UTC](https://discourse.cakephp.org/t/new-to-cakephp-5-auth-problem/11711/2 "2023-11-30T08:02:56Z")

</div>

Try

```auto
        $fields = [
            AbstractIdentifier::CREDENTIAL_USERNAME => 'username',
            AbstractIdentifier::CREDENTIAL_PASSWORD => 'password',
        ];

        $service->loadIdentifier('Authentication.Password', [
            'fields' => $fields,
        ]);

```

Table name `tUsers` or `Users`? I have table `Users`
