Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2018-10

fphttpclient.post

5 messages · 4 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Ched

Hello All,

I'm using fphttpclient.simpleget to make querries to webserver. It's very very simple to use this function ! "Du pur bonheur".

As some data which travel the world encoded in clear in the url of the get are sometime private (connecting password for example), I'd like to use the post method which crypts the data when using https.

There is a fphttpclient.simplepost method with various possibilities for the call, but it dosen't accept something like fphttpclient.simplepost(the-url, an-ansistring). It would also be very nice to have a function which returns also the result in an ansistring as fphttpclient.simplepost(myurl) do.

Yes, you guessed right: I'm not a specialist of networking in Freepascal and I don't understand why one have to manage TStrings and streams as the data of the request are probably very simple to build in an ansistring.

Bad- or good idea ? And how difficult would it be to build ?

Cheers, Ched'

Reply by email

Sven Barth
to Ched

Ched schrieb am Mi., 31. Okt.
2018, 23:43:

Show quoted text 11 lines
Hello All, I'm using fphttpclient.simpleget to make querries to webserver. It's very very simple to use this function ! "Du pur bonheur". As some data which travel the world encoded in clear in the url of the get are sometime private (connecting password for example), I'd like to use the post method which crypts the data when using https.

Your assumption is incorrect. The only part that is "transmitted" unencrypted is the host, because that one is resolved using DNS. The remaining URL is the first line of the already encrypted HTTP header.

Regards,
Sven

Reply by email

Unknown author
to Ched: I'm using fphttpclient.simpleget to make querries to webserver. It's very very simple to…
Ched wrote
As some data which travel the world encoded in clear in the url of the get are sometime private (connecting password for example), I'd like to use the post method which crypts the data when using https.

ummm... if you are using https, GETs are ""crypted"" as are the other http request methods HEAD, POST, PUT, DELETE, CONNECT, OPTIONS, TRACE and PATCH...

NOTE: No off-list assistance is given without prior approval. *Please keep mailing list traffic on the list unless* *a signed and pre-paid contract is in effect with us.*

Reply by email

Ched
to Sven Barth: Ched schrieb am Mi., 31. Okt. 2018, 23:43: Your assumption is incorrect. The only part…

Hello All,

Thank you, Sven and Wkitty42, for having corrected a false assumption about encryption of url.

Nevertheless, why not to have a simplepost(an-url, an-ansistring)::ansistring method available ?

Cheers, Ched'

Le 31.10.2018 à 22:51, Sven Barth via fpc-pascal a écrit :

Show quoted text 23 lines
Ched < > schrieb am Mi., 31. Okt. 2018, 23:43: Hello All, I'm using fphttpclient.simpleget to make querries to webserver. It's very very simple to use this function ! "Du pur bonheur". As some data which travel the world encoded in clear in the url of the get are sometime private (connecting password for example), I'd like to use the post method which crypts the data when using https. Your assumption is incorrect. The only part that is "transmitted" unencrypted is the host, because that one is resolved using DNS. The remaining URL is the first line of the already encrypted HTTP header. Regards, Sven On 10/31/18 6:43 PM, Ched wrote: > As some data which travel the world encoded in clear in the url of the get are sometime private (connecting password for example), I'd like to use the post method which crypts the data when using https. ummm... if you are using https, GETs are ""crypted"" as are the other http request methods HEAD, POST, PUT, DELETE, CONNECT, OPTIONS, TRACE and PATCH...

Reply by email

Michael Van Canneyt
to Ched
Ched wrote 7 lines
Hello All, Thank you, Sven and Wkitty42, for having corrected a false assumption about encryption of url. Nevertheless, why not to have a simplepost(an-url, an-ansistring)::ansistring method available ?

What should this do ? What does the ansistring contain ? What is the encoding ?

Michael.

Reply by email