Problem sending data with HTTPS  using client authentication.

Hi,
I�m tryingto send a message to a secure server using for this client certificate, apparently if I make a GET of "/" (server root) , everything works fine (authentication, and data received), from the moment that I try to ways send data to the "/pvtn " directory i obtain the following error.
This is a sample of the code i�m using:
import com.sun.net.ssl.KeyManagerFactory;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.OutputStreamWriter;
import java.io.Writer;
import java.net.Socket;
import java.security.*;
import java.security.GeneralSecurityException;
import java.security.Principal;
import java.security.PublicKey;
import java.util.Collection;
import java.util.Date;
import javax.net.ssl.SSLSocket;
import javax.net.ssl.SSLSocketFactory;
import javax.security.cert.*;
import javax.security.cert.X509Certificate;
public class Test
public static final String TARGET_HTTPS_SERVER = "mymachine.mydomain.pt";
public static final int TARGET_HTTPS_PORT = 443;
public static void main(String[] args) throws Exception
System.setProperty("javax.net.ssl.trustStore","/certificados/truststore.txt");
System.setProperty("javax.net.ssl.trustStorePassword","trustpwd");
System.setProperty("javax.net.ssl.keyStore","/certificados/truststore.txt");
System.setProperty("javax.net.ssl.keyStorePassword","trustpwd");
java.security.Security.removeProvider("SunJSSE");
java.security.Security.insertProviderAt(new com.sun.net.ssl.internal.ssl.Provider(),2);
KeyManagerFactory kmf= KeyManagerFactory.getInstance("SunX509", "SunJSSE") ;
//Socket
SSLSocket jsslSoc = (SSLSocket) SSLSocketFactory.getDefault().createSocket(TARGET_HTTPS_SERVER, TARGET_HTTPS_PORT);
String [] ciphers = jsslSoc.getSupportedCipherSuites() ;
//// Select the ciphers you want and put them.
//// Here we will put all availabel ciphers
jsslSoc.setEnabledCipherSuites(ciphers);
//// We are creating socket in client mode
jsslSoc.setUseClientMode(true);
//// Do SSL handshake
jsslSoc.startHandshake();
// Print negotiated cipher
System.out.println("Negotiated Cipher Suite: " + jsslSoc.getSession().getCipherSuite());
System.out.println("");
X509Certificate[] peerCerts = ((javax.net.ssl.SSLSocket)jsslSoc).getSession().getPeerCertificateChain();
if (peerCerts != null)
System.out.println("Printing server information:");
for(int i =0; i < peerCerts.length; i++)
System.out.println("Peer Certificate ["+i+"] Information:");
System.out.println("- Subject: " + peerCerts.getSubjectDN().getName());
System.out.println("- Issuer: " + peerCerts[i].getIssuerDN().getName());
System.out.println("- Version: " + peerCerts[i].getVersion());
System.out.println("- Start Time: " + peerCerts[i].getNotBefore().toString());
System.out.println("- End Time: " + peerCerts[i].getNotAfter().toString());
System.out.println("- Signature Algorithm: " + peerCerts[i].getSigAlgName());
System.out.println("- Serial Number: " + peerCerts[i].getSerialNumber());
else
System.out.println("Failed to get peer certificates");
try
Writer out = new OutputStreamWriter(jsslSoc.getOutputStream(), "ISO-8859-1");
//THIS WAY WORKS FINE
out.write("GET / HTTP/1.1\r\n");
// HERE COMES THE TROUBLES
//out.write("GET /pvtn?someparameter=paramvalue HTTP/1.1\r\n");
out.write("Host: " + TARGET_HTTPS_SERVER + ":" + TARGET_HTTPS_PORT + "\r\n");
out.write("Proxy-Connection: Keep-Alive\r\n");
out.write("User-Agent: SSL-TEST \r\n");
out.write("\r\n");
out.flush();
BufferedReader in = new BufferedReader(new InputStreamReader(jsslSoc.getInputStream(), "ISO-8859-1"));
String line = null;
while ((line = in.readLine()) != null)
System.out.println(line);
finally
jsslSoc.close();
the ssl log until sending the GET is
main, WRITE: SSL v3.1 Handshake, length = 36
main, READ: SSL v3.1 Change Cipher Spec, length = 1
main, READ: SSL v3.1 Handshake, length = 36
Plaintext after DECRYPTION: len = 36
0000: 14 00 00 0C 71 AB 40 CC 6C 33 92 05 E9 69 4B 8F [email protected].
0010: D1 77 3F 6E 3C DB F0 A0 B7 9C CF 49 B6 6D C8 17 .w?n<......I.m..
0020: 7E 03 52 14 ..R.
*** Finished, v3.1
verify_data: { 113, 171, 64, 204, 108, 51, 146, 5, 233, 105, 75, 143 }
%% Cached client session: [Session-1, SSL_RSA_WITH_RC4_128_SHA]
[read] MD5 and SHA1 hashes: len = 16
0000: 14 00 00 0C 71 AB 40 CC 6C 33 92 05 E9 69 4B 8F [email protected].
Negotiated Cipher Suite: SSL_RSA_WITH_RC4_128_SHA
When i send the GET
Plaintext before ENCRYPTION: len = 247
0000: 47 45 54 20 2F 70 76 74 6E 3F 41 30 33 30 3D 4D GET /pvtn?A030=M
main, WRITE: SSL v3.1 Application Data, length = 247
main, READ: SSL v3.1 Handshake, length = 24
Plaintext after DECRYPTION: len = 24
*** HelloRequest (empty)
%% Client cached [Session-1, SSL_RSA_WITH_RC4_128_SHA]
%% Try resuming [Session-1, SSL_RSA_WITH_RC4_128_SHA] from port 3535
*** ClientHello, v3.1
RandomCookie: GMT: 1131988975 bytes = { 45, 113, 241, 212, 81, 255, 244, 169, 74, 41, 160, 227, 197, 210, 155, 211, 47, 237, 18, 179, 238, 47, 28, 86, 30, 253, 157, 253 }
Session ID: {208, 18, 243, 174, 216, 156, 80, 201, 121, 136, 63, 162, 31, 196, 186, 95, 193, 143, 238, 172, 173, 79, 64, 219, 17, 149, 14, 138, 53, 95, 18, 96}
Cipher Suites: { 0, 5, 0, 4, 0, 9, 0, 10, 0, 18, 0, 19, 0, 3, 0, 17, 0, 2, 0, 1, 0, 24, 0, 26, 0, 27, 0, 23, 0, 25 }
Compression Methods: { 0 }
[write] MD5 and SHA1 hashes: len = 105
Plaintext before ENCRYPTION: len = 125
main, WRITE: SSL v3.1 Handshake, length = 125
main, READ: SSL v3.1 Handshake, length = 94
Plaintext after DECRYPTION: len = 94
*** ServerHello, v3.1
RandomCookie: GMT: 1131991620 bytes = { 205, 194, 212, 113, 37, 213, 41, 13, 60, 142, 135, 68, 17, 78, 227, 251, 176, 211, 133, 203, 153, 173, 153, 195, 93, 7, 87, 123 }
Session ID: {108, 85, 45, 208, 104, 124, 209, 24, 247, 113, 156, 134, 28, 154, 75, 198, 64, 181, 167, 9, 149, 223, 162, 21, 225, 32, 168, 31, 190, 48, 241, 195}
Cipher Suite: { 0, 5 }
Compression Method: 0
%% Created: [Session-2, SSL_RSA_WITH_RC4_128_SHA]
** SSL_RSA_WITH_RC4_128_SHA
[read] MD5 and SHA1 hashes: len = 74
main, READ: SSL v3.1 Handshake, length = 3154
Plaintext after DECRYPTION: len = 3154
*** Certificate chain
stop on trusted cert: [
Version: V1
Subject: CN=GTE CyberTrust Global Root, OU="GTE CyberTrust Solutions, Inc.", O=GTE Corporation, C=US
Algorithm: [MD5withRSA]
Signature:
[read] MD5 and SHA1 hashes: len = 3134
main, READ: SSL v3.1 Handshake, length = 479
Plaintext after DECRYPTION: len = 479
*** CertificateRequest
Cert Types: RSA, DSS,
Cert Authorities:
[read] MD5 and SHA1 hashes: len = 455
*** ServerHelloDone
[read] MD5 and SHA1 hashes: len = 4
0000: 0E 00 00 00 ....
*** Certificate chain
*** ClientKeyExchange, RSA PreMasterSecret, v3.1
Random Secret: { 3, 1, 19, 223, 230, 65, 59, 210, 10, 69, 239, 178, 185, 5, 52, 57, 44, 160, 163, 239, 85, 64, 173, 16, 132, 234, 33, 228, 0, 8, 134, 52, 20, 190, 196, 15, 205, 35, 169, 39, 14, 160, 143, 74, 210, 74, 43, 181 }
[write] MD5 and SHA1 hashes: len = 141
Plaintext before ENCRYPTION: len = 161
main, WRITE: SSL v3.1 Handshake, length = 161
SESSION KEYGEN:
PreMaster Secret:
.CONNECTION KEYGEN:
Client Nonce:
Server Nonce:
Master Secret:
Client MAC write Secret:
Server MAC write Secret:
Client write key:
Server write key:
0000: FE 94 DF 4C 1A 9F FA CE 0C E9 A6 DB 31 53 E5 FD ...L........1S..
... no IV for cipher
Plaintext before ENCRYPTION: len = 21
0000: 01 0D 16 E6 49 18 36 AF E1 52 9C 2F 72 EE CA DF ....I.6..R./r...
0010: 41 71 68 30 06 Aqh0.
main, WRITE: SSL v3.1 Change Cipher Spec, length = 21
*** Finished, v3.1
verify_data: { 243, 49, 247, 150, 113, 86, 182, 125, 244, 163, 245, 243 }
[write] MD5 and SHA1 hashes: len = 16
0000: 14 00 00 0C F3 31 F7 96 71 56 B6 7D F4 A3 F5 F3 .....1..qV......
Plaintext before ENCRYPTION: len = 36
0000: 14 00 00 0C F3 31 F7 96 71 56 B6 7D F4 A3 F5 F3 .....1..qV......
0010: 1A 7C 8F D9 51 CB 6F 47 2A 7C 90 81 20 EE 97 64 ....Q.oG*... ..d
0020: FF 47 35 CA .G5.
main, WRITE: SSL v3.1 Handshake, length = 36
main, SEND SSL v3.1 ALERT: warning, description = close_notify
Plaintext before ENCRYPTION: len = 22
0000: 01 00 F0 F4 AC 3C B2 DE 95 98 0E B4 ED B1 24 3B .....<........$;
0010: 54 6C 8B DC F3 1F Tl....
main, WRITE: SSL v3.1 Alert, length = 22
java.net.SocketException: Connection aborted by peer: socket write error
     void java.net.SocketOutputStream.socketWrite(java.io.FileDescriptor, byte[], int, int)
          native code
     void java.net.SocketOutputStream.write(byte[], int, int)
          SocketOutputStream.java:96
     void com.sun.net.ssl.internal.ssl.OutputRecord.a(java.io.OutputStream)
     void com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(com.sun.net.ssl.internal.ssl.OutputRecord)
     void com.sun.net.ssl.internal.ssl.HandshakeOutStream.flush()
     void com.sun.net.ssl.internal.ssl.Handshaker.sendChangeCipherSpec(com.sun.net.ssl.internal.ssl.HandshakeMessage$Finished)
     void com.sun.net.ssl.internal.ssl.ClientHandshaker.c()
     void com.sun.net.ssl.internal.ssl.ClientHandshaker.a(com.sun.net.ssl.internal.ssl.SunJSSE_o)
     void com.sun.net.ssl.internal.ssl.ClientHandshaker.processMessage(byte, int)
     void com.sun.net.ssl.internal.ssl.Handshaker.process_record(com.sun.net.ssl.internal.ssl.InputRecord)
     void com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(com.sun.net.ssl.internal.ssl.InputRecord, boolean)
     void com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(com.sun.net.ssl.internal.ssl.InputRecord)
     int com.sun.net.ssl.internal.ssl.AppInputStream.read(byte[], int, int)
     int java.io.InputStream.read(byte[])
          InputStream.java:91
     int java.io.InputStreamReader.fill(char[], int, int)
          InputStreamReader.java:173
     int java.io.InputStreamReader.read(char[], int, int)
          InputStreamReader.java:249
     void java.io.BufferedReader.fill()
          BufferedReader.java:139
     java.lang.String java.io.BufferedReader.readLine(boolean)
          BufferedReader.java:299
     java.lang.String java.io.BufferedReader.readLine()
          BufferedReader.java:362
     void Teste3.main(java.lang.String[])
          Teste3.java:109
Exception in thread main
Debugger disconnected from local process.
Process exited with exit code 1.
One more thing if if make the same thing via browser (https://mymachine.mydomain.pt/pvtn?someparameter=somevalue) and works fine too (obviously i pre installed the client certificate in the browser and choose the certificate when the pop up show up)
It seems like the handshaking fails when i send data to /pvtn...
Regards,
Paulo.

I amhaving the another problem very similar, I am struggling with client authentication with IIS 5.0, and receiving the 'Remote Host closed the connection' error.
Is there any help me in this. I truly apprecaite it
Thanks

Similar Messages

  • JMS Adapter: Sending data with WebSphere MQ Client to XI

    Hi,
    I want to send data from the WebSphere MQ Client to the XI. Is this possible and what do I have to do except configuring the JMS queues in Visual admin?
    Thanks in advance
    Dominic

    hi
    xi jms adapter will read/write data frm queue.
    but u want to access the jms queues in XI WAS frm ur MQ client
    ..will hv to access it directly frm ur client
    chk this
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/604e2b64-e689-2910-64b3-ffd650f83756
    rgds
    arun

  • HTTPS Without client authentication shows error of Certificate

    Hi Experts,
    I am trying to develop a SOAP to RFC scenario where in SOAP sender HTTP security level - HTTPS Without Client Authentication is selected.
    I have downloaded WSDL from Sender agreement and trying to test web service from SOAPUI.  Now as per my understanding simply placing request to HTTPS:<host>:<port>:XISOAPAdapter/....   with correct user should work and this scenario shouldn't need any certificates.
    However in SOAPUI and even in RWB SOAP Sender, I am receiving error that - Client Certificate required.
    Any comments on why would it be happening ?    In fact whatever option in HTTP Security level I select, error remains same. In NWA is there any other configuration to be done to make this work ?
    Is below understanding right ?
    -- >> HTTPS Without client authentication will not need certificate exchange and simply user authentication will do
    Thanks..
    regards,
    Omkar.

    Hello Omkar,
    What you are trying to do is Consume a SOAP->RFC scenario (synchronous) from SOAP UI and you want that to be secure. With this requirement, just having the certificates alone is not sufficient (sorry for late response..i just came across this post when i was searching something else )
    1)How did you generate the certificate and the private key? Because Key Generation plays a Big Part in it. The Key should have been signed by a CA. Though its not signed by a CA, a trick which would work is, at the time of Key generation, provide the Organization Name as SAP Trust Community and Country as DE.
    2) At the time of Key Generation definitely it shall ask for a password. You remember that.
    3) Export the Private Key as PCKS12 format and the certificate as Base64 format and have it in your local system, (shall be used later in SOAP UI and NWA)
    Here follows the major part
    4) Open NWA and go to Configuration Management->Authentication
    5) Go to Properties Taband click Modify
    6)  Under Logon Application select the check box "Enable Showing Certificate Logon URL Link on Logon Page" and save it.
    7) Now go to the Components Tab.
    8) Search for client_cert Policy Configuration name and Edit it it. Make sure the following Login Modules are maintained in the same Order
    ==> Name: com.sap.engine.services.security.server.jaas.ClientCertLoginModule
           Flag : Sufficient
    ==> Name: BasicPasswordLoginModule
           Flag: Optional
    9) Now Select the name com.sap.engine.services.security.server.jaas.ClientCertLoginModule and you can see lots of entries under the Login Module Options. Remove them all and add anew entry (case sensitive). Save it.
    ==>Name: Rule1.getUserFrom
           value : wholeCert
    10) Now search for the Policy Configuration name sap.com/com.sap.aii.adapter.soap.app*XISOAPAdapter
    and edit it.
    11) Under the Authentication stack select the template client_cert against the used template label. and save it
    12)If you are using AXIS Adapter, do the steps 11 for the Policy Configuration name sap.com/com.sap.aii.axis.app*XIAxisAdapter.
    13) Now in NWA navigate to Operation management->Identity Management
    14) Search for the user PIISUSER (or any user id which you thing has good amount of authorizations to access the service)
    15)Click Modify and go to the TAB Certificates and upload the certificate (not the private key) which you downloaded in step 3.
    16) With this setup what you have done is you have created proper certificate, enabled certificate based logon for SOAP and AXIS adapter and associated the certificate with a user id.
    17) usually in Dual stack PI, we will have the same certificate added to the server pse in strustsso2 tcode. But since its single stack, just make sure in the cert and keys you add this certificate to teh Trusted CAs and also to the Server Keystore.
    18) Now in SOAP UI Right Click on the Project Name->Select Show Project View->Under the WS Security Configurations->Go to Keystore and certificates and add the Private Key
    19) In SOAP UI under the operation name, in the Request, in stead of providing user credentials, choose the private key name against the SSL Keystore entry.
    20) Before you execute the scenario  make sure you have chosen the HTTPS url and https port is proper. Usually its 443, but some customers configure their own port.
    Scenario should work now. Else if you track it using XPI Inspector, you can find out easily at which step it has gone wrong.
    Good Luck!!
    Best Regards,
    Sundar

  • Problems sending emails with iPhone 3G and outlook exchange

    I have a problem sending email with exchange. Receiving and answering mail works fine and calender updates work fine. However when I initiate an email from the phone it syncs and ends up in the sent folder in the computer but never reaches the recipient. I have tried this many times with different recipients and phones. It only happens from my iphone and ipad. Any suggestions?
    Any help much appreciated

    The iPhone you returned is still syncing against your server and locking out your account. Someone possibly has access to your mail data. I'd recommend having your Exchange Administrator install the Microsoft Exchange Server ActiveSync Web Administration Tool (http://www.microsoft.com/downloads/details.aspx?FamilyID=E6851D23-D145-4DBF-A2CC -E0B4C6301453&displaylang=en) and attempt to wipe/delete/block that other iPhone.
    Message was edited by: ethanm

  • HTTPs without client authentication, error while posting through Altova

    Hi Experts
    I am doing a SOAP- XI-Proxy synchronous scenario where i have to use HTTPs without client authentication for the first time in my system.
    I have made the scenario and WSDL out of it.
    When i am trying to test it through Altova, i am getting the following error:
    <?xml version="1.0"?>
    <!-- see the documentation -->
    <SOAP:Envelope xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">
        <SOAP:Body>
            <SOAP:Fault>
                <faultcode>SOAP:Server</faultcode>
                <faultstring>Server Error</faultstring>
                <detail>
                    <s:SystemError xmlns:s="http://sap.com/xi/WebService/xi2.0">
                        <context>XIAdapter</context>
                        <code>ADAPTER.JAVA_EXCEPTION</code>
                        <text><![CDATA[
    java.security.AccessControlException: https scheme required
        at com.sap.aii.af.mp.soap.ejb.XISOAPAdapterBean.process(XISOAPAdapterBean.java:918)
        at com.sap.aii.af.mp.module.ModuleLocalLocalObjectImpl0_3.process(ModuleLocalLocalObjectImpl0_3.java:103)
        at com.sap.aii.af.mp.ejb.ModuleProcessorBean.process(ModuleProcessorBean.java:296)
        at com.sap.aii.af.mp.processor.ModuleProcessorLocalLocalObjectImpl0_0.process(ModuleProcessorLocalLocalObjectImpl0_0.java:103)
        at com.sap.aii.af.mp.soap.web.MessageServlet.callModuleProcessor(MessageServlet.java:187)
        at com.sap.aii.af.mp.soap.web.MessageServlet.doPost(MessageServlet.java:496)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
        at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:401)
        at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:266)
        at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:386)
        at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:364)
        at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:1060)
        at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:265)
        at com.sap.engine.services.httpserver.server.Client.handle(Client.java:95)
        at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:175)
        at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
        at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
        at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
        at java.security.AccessController.doPrivileged(Native Method)
        at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:104)
        at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:176)
              ]]></text>
                    </s:SystemError>
                </detail>
            </SOAP:Fault>
        </SOAP:Body>
    </SOAP:Envelope>
    i saw a few discussion on web but nowhere the solution was provided.
    the url is
    http://abc.sap.point:1234/XISOAPAdapter/MessageServlet?channel=:system:communicationchannel&amp;version=3.0&amp;Sender.Service=x&amp;Interface=x%5Ex
    i changed it to https also but in that case it was not even posting the request.
    i have set the sender adapter like this
    is there any setting that i am missing.
    What is the setting the i need to do in SM59.
    Please help me getting through this.
    Your help is highly appreciated. Thanks in advance.
    Neha

    HI Neha,
    1. Enable the https service in the ICM: you can follow the way to do it like is pointed out in the page 4 of this document (PI 7.1 and PI 7.0 has the same smicm abap transaction) http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/60ff2883-70c5-2c10-f090-a744def2ba66?overridelayout=t…
    2. Generate the certificate. Use the STRUST transaction. Chech this document SSL Configuration in SAP ABAP AS and JAVA AS – Step-by-step procedure
    Hope this helps.
    Regards.

  • Sending mails with attachments using oracle 8i

    Hi,
    Could anybody please send a sample code for sending mails
    with attachments using oracle 8i.
    Thanks in advance

    For oracle8i there is an example package from OTN:
    http://www.oracle.com/technology/sample_code/tech/pl_sql/htdocs/Utl_Smtp_Sample.html
    You have to re-write the package a bit to work it with BLOBs instead of RAW attachments, but that should be no problem
    Hop this helps,
    Michiel

  • HTTPS without client authentication

    Hi Friends,
    In SOAP adapter, we have three options for HTTP
    HTTP without SSL
    HTTP with SSL (= HTTPS) without client authentication
    HTTP with SSL (= HTTPS) with client authentication
    Please let me know if I use  "HTTP with SSL (= HTTPS) without client authentication" ,  is it Transport Layer Sceurity of Message level Security?
    Please answer only if you are confident. No guess please!!!
    Thanks,
    Sandeep Maurya

    Hi,
    Please let me know if I use  "HTTP with SSL (= HTTPS) without client authentication" ,  is it Transport Layer Sceurity or Message level Security?
    HTTPS is used to encrypt the traffic between the client and the Web server. SSL encrypt the segments of network connections at the Transport Layer end-to-end.
    Don't get confused with the Client Authentication (with / without), as SSL is already being used in both the forms and the network is secured.
    Regards,
    Neetesh

  • I cannot send emails with pics using the stock email app on my new Droid Turbo, it holds them in the Outbox and won't send even if I move to Inbox and resend

    I cannot send emails with pics using the stock email app on my new Droid Turbo, it holds them in the Outbox and won't send even if I move to Inbox and resend

    First check to make sure you have data turned on and not just Wi-Fi. From reading your question you seem to be saying e mail is working just not attached photos. What size are the photos as some HD photos can't be sent. Your camera may be set at a very high picture size and you can go to settings and lower the size and that may solve your mailing problem.

  • Sending data with streams

    What is the best way to send files using java? I was trying datagrams, but it takes forever to write a file from byte[]'s. Any ideas?

    So we're talking streaming video (ergo: sending data with streams) I'm a bit slow today, apparently.
    From what I think I know about datagrams... it's the way to go for "broadcasting" any type of data... and whilste it can be a bit lossy (complete, in-order delivery is NOT garanteed), it usually works 100% A-OK on LAN's (on high-quality underlying network hardware, of course).
    The only thing I've ever done with datagrams is the typical noob chat-app (with a simple swing interface), which I posted on this forum ?years? ago... maybe you can still find it.
    Cheers. Keith/
    Edited by: corlettk on 30/12/2008 12:49 ~~ WAAAAAY too slow today. Apparently. Ignore this post (except the link).

  • Problem sending attachements with gmail account on mail

    Hello:
    I have a lot of problems sending attachments with my gmail account using mail.
    1. Attachments are not big.
    2. I don't have the same problem with other non gmail accounts.
    3. When ever I have this problem I go to gamil.com and I am able to send the attachment with no problem.
    Any suggestions?
    Thanks

    No idea ?
    Nemrod

  • Problem sending mail with attachments???

    Hi Everybody,
    I have got a problem sending mail with attachments...
    I am able to send a plain mail ... but when i am trying to send mail along with an attachment ... its not being sent....
    its not showing any error it is simply hanging...
    what should i do?
    If u know any solns please do suggest me....
    Thanks in advance

    activation.jar is already there...
    initially i wrote a swing program as a front end and it was working abs fine... in my sense it was properly sending mails along with the attachments...
    when i changed the front-end to JSP handled by Servlets i am getting a problem...
    and even the swing program stopped working ...
    now swing program is getting compiled but it is hanging at run time showing an exception "Exception occured during event dispatching"
    i dont understand what probably may be the problem...
    if u can trace out, please give me any suggestions
    Thanks in advance and regards

  • Problem download data with trailing blanks using gui_download

    Hi All,
          I am using SAP 4.6C. I have requirement to download data with trailing
    blanks.But i am not succeeded fully to acheive my requirement.I want to
    download data to be in the below format.
    Eg: 'T000000070600000004000000003593593                                               '
    I want to download data with different blanks of each record.
    For example in 1 line 18, 2nd line 25, 3rd line 22.
    I already used Hexa notation value '09'. But it is showing only 7 at once. I have
    added 3 times this field but it is showing 21. How i can i add extra space?
    I tried to move ' ' spaces also. It does't wotk. I have tried concatenate with ' ' and
    separared by ' ' also but no use.
    I have passed all possible parameters to GUI_DOWNLOAD FM.
    say  write_field_separator         = ' '
    write_lf    = 'X'
    trunc_trailing_blanks    = ' '
    trunc_trailing_blanks_eol     = ' '
    Could please tell me some one had faced same problem earlier. It is very urgent.
    Is there is any class attribute in SAP 4.6C?
    ( like cl_abap_char_utilities in 4.7 )
    Thanks in Advance.
    Basha

    Try :
    CONCATENATE  XXXX space RESPECTING BLANKS.
    Of course you must retain these parameters :
    trunc_trailing_blanks = space
    trunc_trailing_blanks_eol = space
    Hope this helps

  • Problems sending mail with txt attachtment using SO_DOCUMENT_SEND_API1 MF

    Hi gurus,
    I allready tried to search in the forum some threads related with my problem, but i couldnt found any with the same problem that im having.
    My problem it's when attachting an txt file, using MF SO_DOCUMENT_SEND_API1 MF, the mail attachtment it's coming with the txt file but instead of coming with the all lines in the contents_bins table the file it's coming with a few lines. I think the problem it's that the txt file should come with 80 characters per line, like it's on the contents_bin table, buu instead that the MF it's filling me each line of the file with 1024 characters.
    Does anyone has ideas what im doing wrong?
    Ps - Below goes my code.
    Thanks in Advance,
    Best Regards,
    João Martins.
      CLEAR contents_bin.
      REFRESH contents_bin.
      PERFORM get_attachment TABLES tab_movimentos contents_bin
                             USING linha_inicial
                             linha_final.
      CLEAR: document_data, tab_lines.
      MOVE 'Aviso Ficheiro Retorno' TO document_data-obj_descr.
      MOVE 'Aviso Ficheiro de Retorno TU' TO document_data-obj_name.
      DESCRIBE TABLE contents_txt LINES tab_lines.
      READ TABLE contents_txt INDEX tab_lines.
      document_data-doc_size = ( tab_lines - 1 ) * 255
                               + STRLEN( contents_txt ).
      CLEAR packing_list.
      REFRESH packing_list.
      packing_list-transf_bin = space.
      packing_list-head_start = 1.
      packing_list-head_num = 0.
      packing_list-body_start = 1.
      DESCRIBE TABLE contents_txt LINES packing_list-body_num.
      packing_list-doc_type = 'RAW'.
      APPEND packing_list.
      packing_list-transf_bin = 'X'.
      packing_list-head_start = 1.
      packing_list-head_num   = 1.
      ADD 1 TO tab_lines.
      packing_list-body_start = tab_lines.
      CLEAR: lv_filename, tab_lines.
      CONCATENATE 'Fich Retorno -' nome_ficheiro INTO lv_filename.
      DESCRIBE TABLE contents_bin LINES tab_lines.
      packing_list-doc_type   =  'TXT'.
      packing_list-obj_descr  =  'Ficheiro Retorno'.
      packing_list-obj_name   =  lv_filename.
      packing_list-doc_size   =  tab_lines * 255.
      APPEND packing_list.
      CALL FUNCTION 'SO_DOCUMENT_SEND_API1'
           EXPORTING
                document_data              = document_data
                put_in_outbox              = 'X'
                sender_address             = 'SIFJOB'
                sender_address_type        = 'B'
           IMPORTING
                sent_to_all                = sent_to_all
           TABLES
                packing_list               = packing_list
                contents_bin               = contents_bin
                contents_txt               = contents_txt
                receivers                  = tab_receiver
           EXCEPTIONS
                too_many_receivers         = 1
                document_not_sent          = 2
                document_type_not_exist    = 3
                operation_no_authorization = 4
                parameter_error            = 5
                x_error                    = 6
                enqueue_error              = 7
                OTHERS                     = 8.
      SUBMIT rsconn01 WITH mode = 'INT'
                  WITH output = SPACE
                  AND RETURN.
    FORM get_attachment TABLES   p_tab_movimentos STRUCTURE
                                 zlinha_movimentos_fich_retorno
                                 p_contents_bin STRUCTURE contents_bin
                        USING    p_linha_inicial STRUCTURE
                                 zlinha_inicial_ps2
                                 p_linha_final STRUCTURE
                                 zlinha_final_ps2.
      DATA: lv_valor(14).
      DATA : line(80) TYPE x.
      CONCATENATE p_linha_inicial-referencia p_linha_inicial-tipo_registo
      p_linha_inicial-tipo_operacao p_linha_inicial-situacao_conta
      p_linha_inicial-situacao_registo p_linha_inicial-iban+4(21)
      p_linha_inicial-moeda p_linha_inicial-data_pag
      p_linha_inicial-ref_ordenante p_linha_inicial-filler
      INTO p_contents_bin-line.
      CLEAR line.
      conv_bin p_contents_bin-line line.
      MOVE line TO p_contents_bin-line.
      APPEND p_contents_bin.
      CLEAR p_contents_bin.
      LOOP AT p_tab_movimentos.
        CLEAR: lv_valor.
        WRITE p_tab_movimentos-montante TO lv_valor.
        PERFORM normalize_value USING lv_valor.
        CONCATENATE p_tab_movimentos-referencia
          p_tab_movimentos-tipo_registo p_tab_movimentos-tipo_operacao
          p_tab_movimentos-sit_conta_retor p_tab_movimentos-situacao_registo
          p_tab_movimentos-nib lv_valor
          p_tab_movimentos-ref_ordenante p_tab_movimentos-filler
          INTO p_contents_bin-line.
        CLEAR line.
        conv_bin p_contents_bin-line line.
        MOVE line TO p_contents_bin-line.
        APPEND p_contents_bin.
        CLEAR p_contents_bin.
      ENDLOOP.
      CLEAR: lv_valor.
      WRITE p_linha_final-mont_total TO lv_valor.
      PERFORM normalize_value USING lv_valor.
      CONCATENATE p_linha_final-referencia p_linha_final-tipo_registo
        p_linha_final-tipo_operacao p_linha_final-filler_1
        p_linha_final-situacao_registo p_linha_final-filler_2
        p_linha_final-total_reg lv_valor
        p_linha_final-filler INTO p_contents_bin-line.
      CLEAR line.
      conv_bin p_contents_bin-line line.
      MOVE line TO p_contents_bin-line.
      APPEND p_contents_bin.
      CLEAR p_contents_bin.
    ENDFORM.                    " get_attachment

    Hi,
    I've solved this problem. The problem was because i was using the
    * Anexo - Descrição
      packing_list-transf_bin = 'X'.
      packing_list-head_start = 1. "Here it must be 0 because i wasn't using any table header
      packing_list-head_num   = 0.
      ADD 1 TO tab_lines.
      packing_list-body_start = 1.
      CLEAR: lv_filename, tab_lines.
      CONCATENATE nome_ficheiro 'TB' INTO lv_filename.
    *  CONCATENATE 'Fich Retorno -' nome_ficheiro INTO lv_filename.
      DESCRIBE TABLE contents_bin LINES tab_lines.
      packing_list-doc_type   =  'TXT'.
      packing_list-obj_descr  =  lv_filename."'Ficheiro Retorno'.
      packing_list-obj_name   =  lv_filename.
      packing_list-body_num = tab_lines.
      packing_list-doc_size   =  tab_lines * 255.
      APPEND packing_list.
    Best Regards
    Thanks,
    João Martins

  • Retrieve and send data to website using http protocol

    Hi, I wonder if anyone knows how to use java language to retrieve and send data to internet website using the http protocol.

    Take a look at this thread:
    http://forum.java.sun.com/thread.jsp?forum=31&thread=310300

  • SOAP Adapter - HTTPS w/ client authentication -SSL termination @ dispatcher

    Hi,
    We have a SOAP client sending SOAP message over SSL to PI. We are using client cert for authentication, but terminating SSL at web dispatcher. In this scenario, i) do we need to configure security for XISOAPADAPTER in Visual admin on PI and ii) do we need to set HTTPS with client authentication security option in SOAp Sender communication channel?
    My understanding is that since we are terminatinating SSL at web dispatcher (Server authentication happens between third-party gateway and our gateway and when web dispatcher terminates SSL, client cert for auth is passed via httpheader to PI where it is mapped to UME user with sufficient authorizations) we don't need to set the XISOAPADAPTER security (if it is end-to-end ssl we would i guess set up in V. Admin>Security provider service>clientcertloginmodule for XISOAPADAPTER) and we don't need to set the sender channel as https with client authentication ( it should just be http in SOAP sender channel).
    Is my understanding correct? I will really appreciate any clues?
    Thanks,
    Saurabh

    Hi saurabh
    follow these links to SAP note
    these will be helpful for you
    Note 856597 - FAQ: XI 3.0 / PI 7.0 / PI 7.1 SOAP Adapter
    https://websmp102.sap-ag.de/~form/handler?_APP=01100107900000000342&_EVENT=REDIR&_NNUM=856597&_NLANG=E
    Note 856599 - FAQ: XI 3.0 / PI 7.0 / PI 7.1 Mail Adapter
    https://websmp102.sap-ag.de/~form/handler?_APP=01100107900000000342&_EVENT=REDIR&_NNUM=856599&_NLANG=E
    Note 870845 - XI 3.0 SOAP adapter SSL client certificate problem
    https://websmp130.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/sapnotes/index2.htm?numm=916664&nlang=EN&smpsrv=https%3a%2f%2fwebsmp102%2esap-ag%2ede
    https://websmp130.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/sapnotes/index2.htm?numm=870845&nlang=EN&smpsrv=https%3a%2f%2fwebsmp102%2esap-ag%2ede
    regards
    Sandeep
    If helpful kindly reward points

Maybe you are looking for

  • What is the best way to retrive data from a Global Variable?

    Here is what I want to do, I have several PC's that run different types of tests. I want to use a global variable, running on a single PC, that acts like a sever that can be accessed by the other PC's in my lab. This Global variable will store the ho

  • App-V 5 Publishing Server + Load Balancing (NetScaler) issue

    All,  I have attempted to load balance my App-V 5.0 deployment, which includes two nodes (appv-1 and appv-2) on a Citrix NetScaler VPX appliance.  The management server is working fine, when browsing to the load balanced VIP DNS alias - pass-through

  • Can't write to external disk after cloning startup disk to it

    After cloning my PowerBook Pro's startup disk to an external Thunderbolt drive, and temporarily using that drive to boot-up, the Thunderbolt drive is locked into Read Only mode.  How do I enable it to write again? The INFO pane says the following: Sy

  • Get mouse thumb buttons to work with pcmanfm?

    I've always wanted pcmanfm to read my thumb buttons (button 8 and 9) correctly This is how I set it for applications such as firefox to read my button 8 and 9 correctly: In ~/.xbindkeysrc ## Mouse Thumb Button mapping "xvkbd -xsendevent -text "\[XF86

  • Facetime: user not available right away after dial

    When I am trying to do a Facetime Call (Audio and Facetime video), it gives right away a message of "User not available for Facetime". This number used to work no problem before. I tried to do a test with another Iphone to find the reason why this ha