1

I am developing a bot for Skype in Java. Right now, I only want the bot to authenticate (get bearer token) and to echo received messages. I did last test on 31st July 2017 and it worked fine. But, since August, the strangest thing is happening:

The bot can authenticate correctly, and I got the bearen token and its timeout. After that, the SslSocket starts listening. When I chat the bot, it gets a connection (initiates handshake and all that) but receives nothing. No headers, no payload, nothing.

I tried reading documentation and see if the latest update to Microsoft Bot Framework had anything to do with it, but I couldn't find anything. Anyone can help me about what's going on?

        InputStream inputStream = sslSocket.getInputStream();
        OutputStream outputStream = sslSocket.getOutputStream();

        BufferedReader bufferedReader = new BufferedReader(new InputStreamReader(inputStream));
        PrintWriter printWriter = new PrintWriter(new OutputStreamWriter(outputStream));
        String line = null;
        String jsonLine = null;

        String challenge = null;                

        while(((line = bufferedReader.readLine()) != null)){
            System.out.println("iline = "+line);

            if (!line.isEmpty()){
                if(line.substring(0,1).equals("{")){
                    jsonLine = line;
                }
            }
        }

This is the part of the code which reads the incoming message. JsonLine and line are always null.

D4RKCIDE
  • 3,439
  • 1
  • 18
  • 34
frege
  • 21
  • 2
  • There is a chance that your secret key expired. And if you were making the calls directly with a generated access token then you need to regenerate the access token. – Rinor Aug 28 '17 at 22:18
  • I already changed the secret information about the bot, but nothing changes. About the bearer token, the bot ask for it each time it starts running. Anyway, my problem is not sending messages but receiving them. SslSocket get a connection when I chat the bot but receives nothing. EDIT: I receive messages via webhook on my pc. – frege Aug 29 '17 at 07:08

1 Answers1

1

Certificate was expired. Once renewed, everything started working again.

frege
  • 21
  • 2