tigase / tigase-server

(M) Highly optimized, extremely modular and very flexible XMPP/Jabber server
https://tigase.net
GNU Affero General Public License v3.0
317 stars 106 forks source link

is possibile to configure update-login-time-query? #204

Closed davidemarrone closed 1 year ago

davidemarrone commented 1 year ago

Regarding this improvment, is it possible to configure from config.tdsl the SP query setting somewhere the key update-login-time-query ? How can I do it?

I didn't see it in the doc thanks

gradylu commented 1 year ago

Sorry, I can't resolve this issue. below is configuration file with setup(config.tdsl)

'config-type' = 'setup'

'vhost-man' () { 'defaults' () { 'domain-filter-policy' = null 's2s-secret' = null trusted = null 'vhost-disable-dns-check' = false 'vhost-max-users' = 0L 'vhost-message-forward-jid' = null 'vhost-presence-forward-jid' = null 'vhost-register-enabled' = true 'vhost-tls-required' = false } }

http () { setup () { 'admin-user' = 'admin' 'admin-password' = 'tigase' } }

woj-tek commented 1 year ago

@davidemarrone You should be able to set it via authRepository:

authRepository () {
    default () {
        'update-login-time-query' = '{ call TigUpdateLoginTime(?) }'
    }
}

See documentation for more details: https://docs.tigase.net/en/latest/Tigase_Administration/Security/_Security.html#tigase-custom-auth-connector


@gradylu please don't hijack issues with unrelated questions - create new one.

davidemarrone commented 1 year ago

@woj-tek thank you, somewhere I a comment (i do not remember where) I have read to use

authRepository () {
    default () {
        'update-login-time-query' = null
    }
}

but it does not work, I will use

authRepository () {
    default () {
        'update-login-time-query' = 'select 1'
    }
}