Getting org.jsmpp.extra.NegativeResponseException: Negative response 0000000e found

1,467 views
Skip to first unread message

Nagesh M

unread,
Apr 20, 2012, 7:04:17 AM4/20/12
to jsmpp
Hi Team,

I have executed the following code,

import java.io.IOException;

import org.apache.log4j.BasicConfigurator;
import org.jsmpp.bean.BindType;
import org.jsmpp.bean.NumberingPlanIndicator;
import org.jsmpp.bean.TypeOfNumber;
import org.jsmpp.session.BindParameter;
import org.jsmpp.session.SMPPSession;


public class OpenAndBindExample {

public static void main(String[] args) {
BasicConfigurator.configure();
String host = "10.1.20.43";
int port = 518;
SMPPSession session = new SMPPSession();
try {
System.out.println("Connect and bind to " + host + " port
" + port);
session.connectAndBind(host, port, new
BindParameter(BindType.BIND_TRX, "ITOC", "Itoc3", null,
TypeOfNumber.UNKNOWN, NumberingPlanIndicator.UNKNOWN, null));
} catch (IOException e) {
// Failed connect and bind to SMSC
System.err.println("Failed connect and bind to host");
e.printStackTrace();
}
try { Thread.sleep(10000); } catch (InterruptedException e) {}
session.unbindAndClose();
}

}

Can you please help on this.

Output:

Connect and bind to 10.1.20.43 port 518
0 [main] DEBUG org.jsmpp.session.SMPPSession - Connect and bind to
10.1.20.43 port 518
1048 [main] INFO org.jsmpp.session.SMPPSession - Connected
1056 [Thread-0] INFO org.jsmpp.session.SMPPSession - Starting
PDUReaderWorker with processor degree:3 ...
5055 [pool-1-thread-1] DEBUG org.jsmpp.session.AbstractSessionContext
- Activity notified
5055 [pool-1-thread-1] DEBUG org.jsmpp.session.state.SMPPSessionOpen
- Bind Response header (21, 80000009, 0000000e, 1)
5057 [main] DEBUG org.jsmpp.session.AbstractSession - bind response
received
5058 [main] ERROR org.jsmpp.session.SMPPSession - Receive negative
bind response
org.jsmpp.extra.NegativeResponseException: Negative response 0000000e
found
at
org.jsmpp.session.AbstractSession.validateResponse(AbstractSession.java:
215)
at
org.jsmpp.session.AbstractSession.executeSendCommand(AbstractSession.java:
271)
at org.jsmpp.session.SMPPSession.sendBind(SMPPSession.java:294)
at org.jsmpp.session.SMPPSession.connectAndBind(SMPPSession.java:232)
at org.jsmpp.session.SMPPSession.connectAndBind(SMPPSession.java:200)
at OpenAndBindExample.main(OpenAndBindExample.java:21)
5061 [Thread-0] INFO org.jsmpp.session.SMPPSession - PDUReaderWorker
stop
Failed connect and bind to host
java.io.IOException: Receive negative bind response: Negative response
0000000e found
at org.jsmpp.session.SMPPSession.connectAndBind(SMPPSession.java:246)
at org.jsmpp.session.SMPPSession.connectAndBind(SMPPSession.java:200)
at OpenAndBindExample.main(OpenAndBindExample.java:21)

Stefán Þorvarðarson

unread,
Apr 20, 2012, 8:10:58 AM4/20/12
to js...@googlegroups.com
Hi

Well, the error code from your SMSC is 0000000e and here is the definition of that error according to the SMPP specifications:

0x0000000E ESME_RINVPASWD Invalid password

Best regards,
Stefan

________________________________________
From: js...@googlegroups.com [js...@googlegroups.com] On Behalf Of Nagesh M [ncm.n...@gmail.com]
Sent: Friday, April 20, 2012 11:04 AM
To: jsmpp
Subject: Getting org.jsmpp.extra.NegativeResponseException: Negative response 0000000e found

Hi Team,

import java.io.IOException;


public class OpenAndBindExample {

}

Output:

--
You received this message because you are subscribed to the Google Groups "jsmpp" group.
To post to this group, send email to js...@googlegroups.com.
To unsubscribe from this group, send email to jsmpp+un...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/jsmpp?hl=en.

Reply all
Reply to author
Forward
0 new messages