Proxy certificate generation


Allows for generating a user proxy certificate with a default lifetime (12 hours)

URL /api/userproxy
Method GET
URL params None
Data params None
Headers USER-LOGIN - User login (required)
USER-PASSWORD - Base64 encoded user password (required)
PRIVATE-KEY-PASSWORD - Base64 encoded private key password (required)
Success response

Code: 200

Example:

-----BEGIN CERTIFICATE-----
...
...
...
-----END CERTIFICATE-----
Error response

Error response: 422 | 423 | 500

Example:

{
  "status":"error",
  "exit_code":0,
  "error_message":"error message...",
}
Sample call

Bash (with read, tr, base64 and curl)

read -p "Provide user login: " userLogin
read -s -p "Provide user password: "; userPassword=`echo $REPLY | tr -d '\n' | base64`
read -s -p "Provide private key password: "; privateKeyPassword=`echo $REPLY | tr -d '\n' | base64`
curl -k -X GET --header "USER-LOGIN:$userLogin" --header "USER-PASSWORD:$userPassword" \
--header "PRIVATE-KEY-PASSWORD:$privateKeyPassword" https://submit.plgrid.pl/api/userproxy
Notes Two unsuccessful attempts to generate a user proxy certificate will block proxy generation for 10 minutes