indy10

Indy 10 Multipart upload to OneDrive Error

假装没事ソ 提交于 2020-01-06 18:10:32
问题 I am trying to do Multipart upload to OneDrive using POST and get 'HTTP/1.1 400 Bad Request'. IdLogFile: Stat Connected. Sent 10.02.2017 12:50:08: POST /v1.0/drive/root::/children HTTP/1.0`<EOL>`Content-Type: multipart/related; boundary="Boundary"`<EOL>`Content-Length: 254`<EOL>`Authorization: Bearer EwA...%3d`<EOL>`Host: api.onedrive.com`<EOL>`Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8`<EOL>`Accept-Encoding: identity`<EOL>`User-Agent: Mozilla/3.0 (compatible;

Indy 10 Multipart upload to OneDrive Error

泄露秘密 提交于 2020-01-06 18:10:24
问题 I am trying to do Multipart upload to OneDrive using POST and get 'HTTP/1.1 400 Bad Request'. IdLogFile: Stat Connected. Sent 10.02.2017 12:50:08: POST /v1.0/drive/root::/children HTTP/1.0`<EOL>`Content-Type: multipart/related; boundary="Boundary"`<EOL>`Content-Length: 254`<EOL>`Authorization: Bearer EwA...%3d`<EOL>`Host: api.onedrive.com`<EOL>`Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8`<EOL>`Accept-Encoding: identity`<EOL>`User-Agent: Mozilla/3.0 (compatible;

Indy and smtps: cannot connect

我的未来我决定 提交于 2020-01-04 06:58:05
问题 I am trying to send emails from smtps (secure smtp) using Indy and the technique exaplined in this Marco Cantù article. This is what I am using: object SMTP: TIdSMTP IOHandler = IdSSLIOHandlerSocketOpenSSL1 SASLMechanisms = <> UseTLS = utUseExplicitTLS Left = 32 Top = 196 end and SMTP.Host := 'smtps.pec.aruba.it';; SMTP.Port := 465;; SMTP.Username := 'myaddress@pec.it'; SMTP.Password := 'myPassw0rd'; MailMessage.Encoding := meDefault; MailMessage.From.Address := 'myaddress@pec.it';

Indy and smtps: cannot connect

左心房为你撑大大i 提交于 2020-01-04 06:57:28
问题 I am trying to send emails from smtps (secure smtp) using Indy and the technique exaplined in this Marco Cantù article. This is what I am using: object SMTP: TIdSMTP IOHandler = IdSSLIOHandlerSocketOpenSSL1 SASLMechanisms = <> UseTLS = utUseExplicitTLS Left = 32 Top = 196 end and SMTP.Host := 'smtps.pec.aruba.it';; SMTP.Port := 465;; SMTP.Username := 'myaddress@pec.it'; SMTP.Password := 'myPassw0rd'; MailMessage.Encoding := meDefault; MailMessage.From.Address := 'myaddress@pec.it';

How should I adapt my code for compatibility between TBytes and TIdBytes?

℡╲_俬逩灬. 提交于 2020-01-03 15:22:29
问题 I am having the same problem as mentioned in "Delphi XE4 Indy compatibility issue between TBytes and TidBytes ", i.e. compatibility issues between TBytes(Delphi RTL) and TIdBytes(Indy) datatypes when compiling with the Delphi XE4. The source of my problem is that the code is not exactly according to Indy's interface and some of functions use TBytes, instead of TIdBytes, when calling native Indy IO procedures. So I was wondering what will the best fix be? As I see it there are two approaches:

How do I send a command to a single client instead of all of them?

£可爱£侵袭症+ 提交于 2019-12-30 06:49:57
问题 I am writing a simple client/server chat program with Indy 10. My server (idtcpserver) sends a command to the client, and the client answers, but when more than one client is connected and the server sends a command, all the clients connected send data to the server. How I can send a command to a specified client and not all? 回答1: The only way a command could be sent to all connected clients is if your code is looping through all of the clients sending the command to each one. So simply

How to use a dll outside of the system path

僤鯓⒐⒋嵵緔 提交于 2019-12-28 05:33:07
问题 I made an application that uses the openssl dlls ( libeay32.dll and ssleay32.dll ). It is indy using them, I don't call the dlls directly. The simplest workaround i found to avoid an installer (i just delpoy an exe and i am ok with this approach) is to: put the dlls as resources of the exe on program start I extract them in the exe folder the exe uses them This is perfect but I would like to improve the approach by extracting the dlls in a temp folder and not on the exe folder (that in many

send and recive TStringStream with indyTcp server and client

浪子不回头ぞ 提交于 2019-12-25 18:27:08
问题 I am trying to send a TStringStream from client to server, then send it back from server to client, using Indy TCP components. Here is my client code: var Jpg: TJPEGImage; StringStream: TStringStream; strcams, StringImageData: String; byt, i: integer; procedure SendCommandWithParams(Command, Params: String); begin Lock; try if not FTCP.Connected then begin exit; end; FTCP.Socket.WriteLn('1' + Command, IndyTextEncoding_UTF8); FTCP.Socket.WriteLn(Params, IndyTextEncoding_UTF8); finally Unlock;

Is there an equivalent of Indy 9's ReadBuffer() in Indy 10?

戏子无情 提交于 2019-12-25 17:14:29
问题 This code is written in Borland C++Builder 6 using Indy 9: void __fastcall TfrmMain::ServerConnect(TIdPeerThread *AThread) { BKUK_PACKET Pkt; ----------(中略)--------------------------------------- AThread->Connection->ReadBuffer((BYTE *)&Pkt,sizeof(BKUK_PACKET)); ----------(中略)--------------------------------------- } The function named ReadBuffer() is not found in Indy 10. Is there an equivalent function? BKUK_PACKET is a structure of about 1200 bytes. typedef struct _BKUK_PACKET_ { BYTE head

idHttp : error 500 internal server when site is https

喜你入骨 提交于 2019-12-25 09:36:35
问题 I am working on a project involving login and download, for more than 20 site, in some cases, the sites are very alike, even their structure is the same i have encountered a problem recently, some of the same structured sites are http and some are Https , the Http ones are ok and work fine but the Https ones at the very first post return an error 500 internal server when i try to login, the response code shows for security reasons you can not access ... do i need to change my approach with