Closed jakubjedelsky closed 11 years ago
It's not a direct api exposed by RT.
However if you're using CookieAuthenticator
you could do something like:
auth = CookieAuthenticator(
"john.foo",
"john.foo",
"http://rt.easter-eggs.org/demos/stable/REST/1.0/",
)
auth._login()
z4rimac:~ Z4R$ curl "http://rt.easter-eggs.org/demos/stable/REST/1.0/" -d "user=john.foo&pass=john.foo"
RT/4.0.5-116-g591e06a 200 Ok
....
z4rimac:~ Z4R$ curl "http://rt.easter-eggs.org/demos/stable/REST/1.0/" -d "user=john.foo&pass=john.fool"
RT/4.0.5-116-g591e06a 401 Credentials required
Your username or password is incorrect
Is it possible to add some kind of check if login details are ok? Just check if user is correctly logged in RT and return True / False?