I've seen things like:
user:password@smtpserver:port
In the past, but I'm not sure if the some library parsed that to build a properties to create a session or is there some sort of accepted format.
Using an URI for specifying a network resource, such as an SMTP server is probably the cloeset thing to a "accepted" format you'd see, an SMTP URI, would be something like smtp://user:host@example.com:port or perhaps just smtp://example.com . You'd use a generic URI parsing library to extract the various components.
There's also an old RFC draft for SMTP URLs