[RADIATOR] "AuthBy URL" with linotp check

Klara Mall klara.mall at kit.edu
Mon Nov 18 12:44:45 UTC 2024


Hi Charly, hi all,

thanks for your suggestion. I think I actually want to parse the json 
data instead of depending on the structure of the textual representation.
I found "Authby External" where I can use a command to do the https 
query and return the suitable exit code. This now seems to work very 
good with a python script which gets username and password from stdin, 
querys the linotp url and returns the appropriate exit code.

One strange thing is that I see in the radiator log:
"External command exited with status 256 local7.debug" where we are 
actually returning 1. But it is working anyway.

Best regards
Klara


On 11/16/24 23:05, Karl Gaissmaier via radiator wrote:
> Hi Klara,
> 
> please try:
> 
>         AuthOKKeyword       "status": true, "value": true
>         BadPasswordKeyword  "status": true, "value": false
> 
> Greetings
>     Charly
> 
> 
> Am 16.11.24 um 16:16 schrieb Klara Mall via radiator:
>> Hi,
>>
>> we have been using "AuthBy URL" successfully with a LinOTP url 
>> validate/ simplecheck for years.
>>
>> <AuthBy URL>
>>          Debug 1
>>          AuthUrl https://my.linotp.url/validate/simplecheck
>>          Timeout 5
>>          UserParam user
>>          PasswordParam pass
>>          UrlMethod GET
>>          BadPasswordKeyword :-\(
>>          BadUserKeyword :-/
>>          AuthOKKeyword :-\)
>>          PasswordEncryption Clear
>> </AuthBy>
>>
>> Now we have to switch from simplecheck (which is deprecated) to check. 
>> Check will not return the smileys as simplecheck does but json. Example:
>> {
>>     "version": "LinOTP 2.10.4",
>>     "jsonrpc": "2.0802",
>>     "result": {
>>        "status": true,
>>        "value": false
>>     },
>>     "id": 0
>> }
>>
>> For example piping this through "jq .result.value" would give me false 
>> or true which I could check in BadPasswordKeyword and AuthOKKeyword.
>>
>> But in the radiator documentation I see no way to pipe the output to a 
>> command. Do you have any idea how I can do this?
>>
>> Thanks in advance and best regards
>> Klara
> 
> _______________________________________________
> radiator mailing list
> radiator at lists.open.com.au
> https://lists.open.com.au/mailman/listinfo/radiator

-- 
Karlsruher Institut für Technologie (KIT)
Scientific Computing Center (SCC)

Klara Mall
Abteilungsleiter Netze und Telekommunikation (NET)
Zirkel 2, Geb. 20.20, R. 155
76131 Karlsruhe
Telefon: +49 721 608-48946
E-Mail: klara.mall at kit.edu
Web: http://www.scc.kit.edu

Sitz der Körperschaft:
Kaiserstraße 12, 76131 Karlsruhe

KIT – Die Forschungsuniversität in der Helmholtz-Gemeinschaft

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5081 bytes
Desc: S/MIME Cryptographic Signature
URL: <https://lists.open.com.au/pipermail/radiator/attachments/20241118/7d6e4ac1/attachment.p7s>


More information about the radiator mailing list