View ProjeQtOr On SourceForge.net
ProjeQtOr - Project Management Tool
Supportez nous sur Capterra
OIN - Open Invention Network
ProjeQtOr free project management software - Encoding data method for the API key - ProjeQtOr

Prochaines Sessions

Les prochaines formations et démonstrations sont ouvertes, inscrivez-vous rapidement !

 

Démonstration de ProjeQtOr

(gratuit, sur inscription)
 

13 mai 2025 (10h30-12h)

5 juin 2025 (16h-17h30)

 
 

Planifiez avec ProjeQtOr

14 et 15 mai 2025 (9h-12h30)

18 et 19 juin 2025 (9h-12h30)

 
 

Administrez avec ProjeQtOr

20 et 21 mai (9h-12h30)

25 et 26 juin (9h-12h30)

 

 

 

Encoding data method for the API key

More
22 Mar 2018 11:22 - 22 Mar 2018 11:50 #1 by sogeti
Hi,

We have a problem with the using of the API Key.
We used the GET method and succeeded seeing datas. Then, we encrypted the datas in AES 256 but we are facing a problem when we tried to use the POST method.
We have this error : {"error":"invalid API query", "message":"'data' is not correctly encoded for method POST. Request for correct API KEY"}. We tried several times and have the same error.

Do you think this problem can be caused by the encoding data method. Are we supposed to use base64 for the API ?
Also, where can we modify the AES encryption code, in which file ?

Thank you in advance.
Last edit: 22 Mar 2018 11:50 by sogeti.

Please Connexion or Create an account to join the conversation.

More
22 Mar 2018 16:08 #2 by babynus
You must encrypt with AES 128, using API Key.
Unless you define $aesKeyLength in parameters.php default is 128 (not 256 as it is illegal in some countries)
$data=AesCtr::encrypt($data, $apiKey, Parameter::getGlobalParameter('aesKeyLength'));

Babynus
Administrator of ProjeQtOr web site

Please Connexion or Create an account to join the conversation.

More
22 Mar 2018 17:51 #3 by sogeti
We checked the file fileconfig/parameters.php but we don't have $data and $aesKeyLength.
Is it normal ?
Are we supposed to add them ?

Please Connexion or Create an account to join the conversation.

More
22 Mar 2018 17:53 #4 by babynus
Yes it is normal.
$aesKeyLength is not defined by default, and encryption uses 128bits.
You must define it yourself if you want to change this

Babynus
Administrator of ProjeQtOr web site

Please Connexion or Create an account to join the conversation.

More
22 Mar 2018 17:59 #5 by sogeti
Thank you.
But we don't have the line with $data neither.

Please Connexion or Create an account to join the conversation.

More
22 Mar 2018 18:27 #6 by babynus
No, the line is an example of what you have to write to encode data.

Babynus
Administrator of ProjeQtOr web site

Please Connexion or Create an account to join the conversation.

Moderators: babynusprotion
Time to create page: 0.050 seconds

Paramétrages de cookies

×

Cookies fonctionnels

Ce site utilise des cookies pour assurer son bon fonctionnement et ne peuvent pas être désactivés de nos systèmes. Nous ne les utilisons pas à des fins publicitaires. Si ces cookies sont bloqués, certaines parties du site ne pourront pas fonctionner.

Session

Veuillez vous connecter pour voir vos activités!

Autres cookies

Ce site web utilise un certain nombre de cookies pour gérer, par exemple, les sessions utilisateurs.