Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

тест2 /api/legal_entities накладання ЕЦП і відправка #4

Closed
romanm opened this issue Jun 12, 2017 · 0 comments

Comments

@romanm
Copy link
Owner

romanm commented Jun 12, 2017

Статус http 422 замість 200 при передачі даних підготовлених в medic.algoritmed.com .

Здубльовано ehealth-ua/api-spec#28
Данні збережених як файл registry_MSP_157.json, підписаних ЕЦП Key-6.dat з тестових даних за допомогою http://czo.gov.ua/sign (результатативний фай registry_MSP_157.json.p7s), закодований base64, base64 стрічка запакована в відповідний формат і відправлена HttpClient PUT http://demo.ehealth.world/api/legal_entities .

Папка з файлами даних https://github.com/romanm/algoritmed-mvp1-ehealth/tree/master/src/main/resources/test2_api__legal_entities
від первинних даних
https://github.com/romanm/algoritmed-mvp1-ehealth/blob/master/src/main/resources/test2_api__legal_entities/registry_MSP_157.json
до https://github.com/romanm/algoritmed-mvp1-ehealth/blob/master/src/main/resources/test2_api__legal_entities/registry_MSP_157_response.json .

Тестовий сервер з вказаним випадком:
http://medic.algoritmed.com/v/testMvpMedic?doc_id=157
Передача p7s даних кліент бровзер
https://github.com/romanm/algoritmed-mvp1-ehealth/blob/master/src/main/resources/static/f/mvp1/medic/msp/msp_registry_data_digitalsign.html#L31
Прийом p7s даних сервер
https://github.com/romanm/algoritmed-mvp1-ehealth/blob/master/src/main/java/org/algoritmed/mvp1/medic/EhealthUaRegistryFileUploadRest.java#L20
Кодування base64
https://github.com/romanm/algoritmed-mvp1-ehealth/blob/master/src/main/java/org/algoritmed/mvp1/medic/EhealthUaRegistryFileUploadRest.java#L25
Підготовка request контайнера поетапно:
https://github.com/romanm/algoritmed-mvp1-ehealth/blob/master/src/main/java/org/algoritmed/mvp1/medic/EhealthUaRegistryFileUploadRest.java#L29
https://github.com/romanm/algoritmed-mvp1-ehealth/blob/master/src/main/java/org/algoritmed/mvp1/util/EhealthUaRegistryWebClient.java#L25

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant