B4X FEED Problems wtih RSA encrypt/decrypt between B4A and PHP

اطلاعات موضوع

درباره موضوع در تاریخ, در دسته b4xfeed ایجاد شده و آغاز کننده آن practicalsoftمی باشد و موضوع آن: Problems wtih RSA encrypt\/decrypt between B4A and PHP است. این موضوع تا کنون 80 بازدید کننده و, 0 پاسخ داشته و 0 بار پسندیده شده...
نام دسته b4xfeed
نام موضوع Problems wtih RSA encrypt\/decrypt between B4A and PHP
آغاز کننده موضوع practicalsoft
تاریخ شروع
پاسخ‌ها
0
بازدیدها
80
پسندها
0
آخرین ارسال توسط PracticalSoft
Jun 6, 2020
11,559
4,422
I want to be able to encrypt some data in B4A and decrypt it with PHP on the server and vice versa. I use this to generate the public and private keys. Both PHP and B4A use same keys and the test data is "this is a test".

What I've achieved so far:
1. Encrypt and decrypt successfully within B4A
2. Encrypt and decrypt successfully within PHP

Problems I'm facing
1. B4A decrypted data encrypted by PHP with some issue: The expected result, "this is a test", is at the end. How to get rid of those unwanted chars before that?
Log data:

�������s��A�|y��yɍ�'0ռ׺�`z7<�j��R�����this is a test

2. PHP failed to decrypt data encrypted by B4A.
openssl_private_decrypt() failed and didn't return any related message.

I'm sure that I've made some mistakes. Could someone point me to the right direction? Test B4A project atttached.

TIA


php encrypt file:

کد:
محتوای بلوک کدها در دسترس شما نیست. برای مشاهده بلوک کدها، وارد انجمن شوید یاثبت نام کنید



 

عقب
بالا