Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Nov 16 18:35
    rlebeau commented #201
  • Nov 14 18:08
    wqmeng commented #201
  • Nov 14 18:04
    arvanus commented #201
  • Nov 14 17:43
    wqmeng commented #201
  • Nov 14 17:37
    arvanus commented #201
  • Nov 14 17:31
    wqmeng commented #201
  • Nov 14 12:00
    arvanus commented #201
  • Nov 14 09:07
    wqmeng commented #201
  • Nov 14 09:05
    wqmeng commented #201
  • Oct 30 16:15
    rlebeau edited #260
  • Oct 16 04:22
    rlebeau labeled #269
  • Oct 16 04:22
    rlebeau opened #269
  • Oct 08 19:00

    Fulgan on Restructure

    Bug fix for a typo in TIdIMAP4.… (compare)

  • Oct 08 19:00

    Fulgan on master

    Bug fix for a typo in TIdIMAP4.… (compare)

  • Oct 02 21:00

    Fulgan on Restructure

    Updating TIdIMAP4's InternalSea… (compare)

  • Oct 02 21:00

    Fulgan on master

    Updating TIdIMAP4's InternalSea… (compare)

  • Sep 20 21:50

    Fulgan on master

    Embarcadero patch for race cond… (compare)

  • Sep 20 21:50

    Fulgan on Restructure

    Embarcadero patch for race cond… (compare)

  • Sep 10 18:50
    rlebeau closed #268
  • Sep 10 18:50
    rlebeau commented #268
JNP Software de Franca Ltda
@JNPSoftware
You can share something with me?, tks.
Kudzu
@czhower
the protocol looks pretty simple and straightforward on quick glance.
JNP Software de Franca Ltda
@JNPSoftware
Hi @czhower, glad to now you are here too.
I would like to develop a backend with Indy to hear and reply information using a ISO and a front end in IW to see this information formatted.
Remy Lebeau
@rlebeau
@JNPSoftware the thing about protocol standards is that they are library-agnostic. If you have C and C# examples that work, they can very likely be ported to Indy.
@JNPSoftware ok, so what's stopping you? What are you stuck on exactly?
JNP Software de Franca Ltda
@JNPSoftware
First, i would like to know is INDY is a secure choice to create a server to receive this kind of message?
I've read that I could use "TClientSocket" for this, but I find it weak
Remy Lebeau
@rlebeau
@JNPSoftware Indy has client and server components, you would just have to write the send/receive logic to handle whatever protocol you want, and they can encrypt the connection using SSL/TLS if needed
JNP Software de Franca Ltda
@JNPSoftware
It's sound good to use indy to make a server can receive this messages.
@rlebeau It's a good idea develop a server to receive and a client to response this messages or do all in one place?
Remy Lebeau
@rlebeau
@JNPSoftware that is up to you to decide
but you said you wanted an IW frontend, but IW is web-based so its also a backend, too. Unless you mean you want IW communicating with yet another backend, then it would make sense to use Indy for communications between IW and that other backend, in which case you would likely have IW act as a server for the web browser and a client for the other backend
JNP Software de Franca Ltda
@JNPSoftware
@rlebeau, i'm sorry, i'm confusing things. I would like to develop separated parts. IW is accessing a database with information of cards numbers, value, transactions list, etc.
Indy server receive/write ISO messages and use a same database of IW. But they are totally separated.
Remy Lebeau
@rlebeau
@JNPSoftware where are the ISO messages coming from?
JNP Software de Franca Ltda
@JNPSoftware
image.png
I'm will act like a bank for authorizing a card transaction. I will receive ISO messages from another systems. this is my problem, how can i create a server to receive these messages, and response then in a ISO format.
JNP Software de Franca Ltda
@JNPSoftware
It's is for a small company have a 500/600 cards only. I have a mobile app. But now they need a ISO messages.
Kudzu
@czhower

Since EMBT forums are funky/down again.. .we have put some Delphi as well as Indy forums up to test.. join in!

https://www.atozed.com/forums/forumdisplay.php?fid=10

Remy Lebeau
@rlebeau
@JNPSoftware well, the ISO 8583 protocol is fairly straight forward (see https://www.codeproject.com/Articles/100084/Introduction-to-ISO), so what is not clear about it to you exactly? Do you even know how to use Indy in general? Let's start with that.
Kudzu
@czhower
JNP Software de Franca Ltda
@JNPSoftware
@rlebeau, thank you for your support. I need more research to think about.
Ludwig Behm
@lbehm
Has someone tips for implementing a CalDAV client? Would like to run it on Indy (c++ project)
Also a CalDAV server implementation would be very nice!
Matthijs ter Woord
@mterwoord
caldav is based on http
implementing http clients and servers is easy with indy..
Remy Lebeau
@rlebeau
@mterwoord @lbehm It is a little more involved than that. CalDAV is an extension to WebDAV. It is basically iCalendar wrapped in XML and transmitted with WebDAV over HTTPS. Indy does has a (very) minimal WebDAV client , TIdWebDAV, but no WebDAV server. I'm sure a CalDAV client/server could be made with TIdHTTP/TIdHTTPServer, with some manual work
Ludwig Behm
@lbehm
Thank you @rlebeau. I assume you didn't know of an existing c++/delphi CalDAV project?
Remy Lebeau
@rlebeau
@lbehm There are plenty available (https://devguide.calconnect.org/CalDAV/libraries/, http://libcaldav.sourceforge.net, etc), but none using Indy that I am aware of.
Kudzu
@czhower

There are Indy forums over here too on the linked web forums.

https://www.atozed.com/2018/04/embt-squirrel-on-vacation-again/

^^ Embarcadero Squirrel on Vacation Again
The squirrel on a wheel which powers the Embarcadero Forums has gone on vacation – again. The Embarcadero forums are thus down and....
Jacek
@jaclas
I need to clone a completed TIdMessage object. How to do it correctly? Is SaveToStream / LoadFromStream enough?
Kudzu
@czhower
that should get most, if not all.
Remy Lebeau
@rlebeau
@jaclas that depends on how you have populated the TIdMessage, and what the values of the NoEncode and NoDecode properties are set to
Ludwig Behm
@lbehm
I have a question about TIdMessage, too. I need to insert a TGraphic into a HTML-Mail. I assume I have to use TIdAttachmentMemory and reference the filename in the img-src?
More important: how would you import a TGraphic into a TIdAttachmentMemory?
Remy Lebeau
@rlebeau
@lbehm See http://www.indyproject.org/Sockets/Blogs/RLebeau/2005_08_17_A.aspx and http://www.indyproject.org/Sockets/Blogs/RLebeau/20080116.aspx for how to produce HTML emails with embedded images. As for using TGraphic, you can save it to a TStream first, such as TMemoryStream, and then construct the TIdAttachmentMemory from that TStream. Or, you can save the TGraphic to a temp file and use TIdAttachmentFile with its FileIsTempFile property set to True so the file will be deleted when the attachment is freed. Or, you could write your own TIdAttachment class that overrides OpenLoadStream() and CloseLoadStream() to return/free a temp TStream that the TGraphic has been saved to and which Indy will read from to get the data to send.
Ludwig Behm
@lbehm
Awesome, thank you!
Ludwig Behm
@lbehm
@rlebeau I ended up creating multiple message parts: text/html, text/plain, multipart/alternative, multipart/related... And figured out that TIdMessageClient.SendBody() goes into an endless loop if the message parts aren't created in the correct order. I create every part with new TIdText(pMessage->MessageParts, NULL) and set the correct ParentPartid. Is there a way to reorder them based on the ParentPart id?
Ludwig Behm
@lbehm
ok throw everything away and used TIdMessageBuilderHtml - this works for now...
Remy Lebeau
@rlebeau
@lbehm yes, order matters (the parts are sent in the order they are listed, and MIME is very sensitive to the order - something I plan to address in the future: IndySockets/Indy#139), however I have never seen SendBody() get stuck in an infinite loop before. Can you provide an example that causes this?
Ludwig Behm
@lbehm
Something like this should break it:
TIdText *t = new TIdText(pMessage->MessageParts, NULL);
t->ContentType = "text/plain";
t->Body->Text = "Test";
TIdText *h = new TIdText(pMessage->MessageParts, NULL);
h->ContentType = "text/html";
h->Body->Text = "Test";
TIdText *a = new TIdText(pMessage->MessageParts, NULL);
a->ContentType = "multipart/alternative";
a->ParentPart = -1;
t->ParentPart = a->Index;
h->ParentPart = a->Index;
Ludwig Behm
@lbehm
I intended to build up the message parts as they are needed. If someone just sets the text/plain content no message part is needed. If HTML is added, the text/plain is converted and both parts are appended to the alternative part. Same with related if a graphic is added earlier or later.
Just tried to reduce some copying.
Remy Lebeau
@rlebeau
@lbehm that is definately the wrong way to prepare a multipart email. You need to add the "multipart/alternative" part first, then add the "text/plain" and "text/html" parts after it and link their ParentPart to the previous "multipart/alternative" part. In short, ParentPart should always refer to an earlier part, never to a later part. If you want to convert an email from one layout to another, you basically need to start fresh with a new message and make sure you add parts to it in the correct order, copying data from old parts to new parts as needed. This will be much easier once IndySockets/Indy#139 is implemented, as you will be able to just move parts around from one collection to another. But for now, you have to do thing manually to make it work correctly. I suppose a possible workaround would be to update TIdMessage to scan the MessageParts for items with ParentPart=-1, then rescan for ParentPart=0, =1, etc. But that is a lot more work, especially for how it currently tracks and pops used MIME boundaries. Easier to just make sure the parts in the right order to begin with
Ludwig Behm
@lbehm
@rlebeau No problem. As I mentioned I switched to using TIdMessageBuilderHtmlwhich is working fine.
But maybe an exception would be nice to prevent that loop?
Remy Lebeau
@rlebeau
@lbehm perhaps. It is easy enough to detect if the while loop runs out of MIME boundaries to send, indicating a malformed email. Raising an exception while sending an email would cause communication issues for NNTP and SMTP at least, so I would have to update them to close the socket if TIdMessage fails to encode. That would be a minor change, thoguh
Remy Lebeau
@rlebeau
@lbehm I just added IndySockets/Indy#209 for you