Giter Club home page Giter Club logo

javaskype's Introduction

JavaSkype

As of 2019/04/09, MSNP24 is gone for good. This library stopped working and won't be updated anymore. Thanks to the msndevs team, and to dx and dos-freak in particular for all their work on reverse-engineering the Skype client and making it possible to create libraries like this. Moving forward, you can now try to use libraries that support the new Skype Web API, for example skype4pidgin, or create an official Skype bot.

Recent changes

  • Now supports Microsoft accounts (#24)

Introduction

JavaSkype is a lightweight and comprehensive API for Skype, using the MSNP24 protocol, and Java 8.

This API lets you:

  • Send and receive private Skype messages
  • Send and receive group chat Skype messages
  • Send, receive, accept, and deny friend requests
  • Get your contact list, know your contacts presence, and change yours
  • Add/remove users to a group
  • Block and unblock contacts
  • Get information about your contacts, such as their name, and their avatar

Install

JavaSkype requires Java >= 8 to run. You can get this library using Maven by adding this to your pom.xml:

 <dependencies>
    <dependency>       
           <groupId>fr.delthas</groupId>
           <artifactId>javaskype</artifactId>
           <version>1.0.23</version>
    </dependency>
</dependencies>

Quick example

This library is Object-oriented: the main Skype object will give you User and Group objects, on which you will call methods in order to do stuff. Let's have a look at how to interact with the library.

Skype skype = new Skype("myusername", "mypassword");
try {
  // If you want to report a bug, enable logging
  // Skype.setDebug(path);
  skype.connect(); // Will block until we're connected
} catch (IOException e) {
  System.err.println("An error occured while connecting...");
  e.printStackTrace();
}

// Set the error callback (will be called if any exception is thrown)
// When it is called, you'll be automatically disconnected
skype.setErrorListener(Exception::printStackTrace);

// We're connected and ready to go

// Say hello to all your contacts
for (User user : skype.getContacts()) {
  user.sendMessage("Hi, " + user.getDisplayName() + ", what's up?");
}

// Better: let's say hello whenever a user connects
skype.addUserPresenceListener((user, oldPresence, presence) -> {
  if (oldPresence == Presence.OFFLINE) {
    user.sendMessage("Hi, " + user.getFirstname());
  }
});

// Create a simple time bot
skype.addUserMessageListener((user, message) -> {
  if (message.toLowerCase().contains("time")) {
    user.sendMessage("The current time is: " + LocalDateTime.now().format(DateTimeFormatter.ISO_LOCAL_DATE_TIME));
  }
});

// Invite everyone to the groups you own/are admin on
for (Group group : skype.getGroups()) {
  if (group.isSelfAdmin()) {
    for (User user : skype.getContacts()) {
      group.addUser(user, Role.USER);
    }
  }
}

// Kick a user whenever he rants about Java
skype.addGroupMessageListener((group, user, message) -> {
  if (message.toLowerCase().contains("java") && message.toLowerCase().contains("bad")) {
    group.removeUser(user);
    group.changeTopic("No Java bashing allowed here!");
  }
});

// Let's disconnect
skype.disconnect();

Documentation

The main entry points are :

  • the Skype object
  • the listeners you can put on the Skype object
  • the User and Group objects you get from Skype or from the listeners

The javadoc for the API is located at: http://www.javadoc.io/doc/fr.delthas/javaskype/

Note that this API doesn't support multithreaded calls: if you want to go for some multithreading, you will have to handle the synchronization yourself. You can however run multiple Skype accounts simultaneously, on the same or different threads.

Building

Simply run mvn install.

Misceallenous

Tech

JavaSkype uses a very small set of libraries in order to run:

  • json - Parse JSON responses from the Skype API
  • JSoup - A lightweight and powerful library to parse HTML documents
  • JUnit - The famous testing library

Several libraries have been used during the making of this library:

  • skylogin - I originally used this library via JNI but I've rewritten it in Java in UicConnector.java
  • pyskype - I've used this library to understand how to make a MSNP24 client
  • msndevs-wiki - This wiki has helped me understand the MSNP24 protocol

License

MIT

javaskype's People

Contributors

delthas avatar ducc avatar emersion avatar formatq avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

javaskype's Issues

java.security.InvalidKeyException: Illegal key size

Exception in thread "Skype-Receiver-Thread" java.lang.RuntimeException: java.security.InvalidKeyException: Illegal key size
    at fr.delthas.skype.NotifConnector.processPacket(NotifConnector.java:278)
    at fr.delthas.skype.NotifConnector.lambda$2(NotifConnector.java:405)
    at java.lang.Thread.run(Thread.java:745)
Caused by: java.security.InvalidKeyException: Illegal key size
    at javax.crypto.Cipher.checkCryptoPerm(Cipher.java:1039)
    at javax.crypto.Cipher.implInit(Cipher.java:805)
    at javax.crypto.Cipher.chooseProvider(Cipher.java:864)
    at javax.crypto.Cipher.init(Cipher.java:1396)
    at javax.crypto.Cipher.init(Cipher.java:1327)
    at fr.delthas.skype.UicConnector.getUIC(UicConnector.java:221)
    at fr.delthas.skype.NotifConnector.processPacket(NotifConnector.java:276)
    ... 2 more

After several calls error skype.connect throws an error : 803 3 CON 553

Expected behaviour

After 10-15 user, group, or any call, separate call, the skype.connect should work.

Actual behaviour

After several calls the skype.connect method thows an exception
javaskype.ParseException: Error message received:
803 3 CON 553

Steps to reproduce the issue

After about 10-15 separate method calls, the skype.connect throws an error

Logs

at XXX.connect(Skype.java:201)
at XXX..connect(Skype.java:147)
at XXX.Test.getUsers(SkypeClientTest.java:160)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:78)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:57)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
at org.mockito.internal.runners.JUnit45AndHigherRunnerImpl.run(JUnit45AndHigherRunnerImpl.java:37)
at org.mockito.runners.MockitoJUnitRunner.run(MockitoJUnitRunner.java:62)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:86)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:678)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192)

Caused by: XXX.javaskype.ParseException: Error message received:
803 3 CON 553
UtcTime: 1538906063
Set-Registration: XXX
Registration-Token-Expiry: XXX
Context: XXX

fr.delthas.skype.ParseException: Error message received: 911 2 CON 23

Starting Whistler...
Starting Skype client...
java.io.IOException: fr.delthas.skype.ParseException: Error message received:
911 2 CON 23

Authentication failed
        at fr.delthas.skype.Skype.connect(Skype.java:123)
        at fr.delthas.skype.Skype.connect(Skype.java:87)
        at com.mrpowergamerbr.sparklywhistlerbot.Whistler.main(Whistler.java:102)
Caused by: fr.delthas.skype.ParseException: Error message received:
911 2 CON 23

Authentication failed
        at fr.delthas.skype.NotifConnector.readPacket(NotifConnector.java:467)
        at fr.delthas.skype.NotifConnector.lambda$2(NotifConnector.java:495)
        at java.lang.Thread.run(Thread.java:745)

Same code on both machines, on my computer (Windows 10) it works with no issues, however it fails to connect on my dedicated machine (CentOS 6).

JavaSkype w/ Spigot

  • OS, Version, Architecture (e.g. Windows 8.1 x64):
    Windows 10 x64

  • JRE Vendor, Version (e.g. Oracle JDK 8u151):
    Oracle JDK 8u151

Expected behaviour

JavaSkype should initialise.

Actual behaviour

JavaSkype does not load

Steps to reproduce the issue

I was trying to connect via the JavaSkype client from a MineCraft Spigot plugin. However, the thing that happens is the library just dies on me because of the error below.

Logs

java.lang.NoClassDefFoundError: org/json/JSONException
        at fr.delthas.skype.Skype.reset(Skype.java:300) ~[?:?]
        at fr.delthas.skype.Skype.connect(Skype.java:146) ~[?:?]
        at fr.delthas.skype.Skype.connect(Skype.java:124) ~[?:?]
        at xyz.multinetwork.MCCore.onEnable(MCCore.java:34) ~[?:?]
        at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:264) ~[spigot-1.13.2.jar:git-Spigot-a1ba5fe-3359cb1]
        at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:339) [spigot-1.13.2.jar:git-Spigot-a1ba5fe-3359cb1]
        at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:403) [spigot-1.13.2.jar:git-Spigot-a1ba5fe-3359cb1]
        at org.bukkit.craftbukkit.v1_13_R2.CraftServer.enablePlugin(CraftServer.java:431) [spigot-1.13.2.jar:git-Spigot-a1ba5fe-3359cb1]
        at org.bukkit.craftbukkit.v1_13_R2.CraftServer.enablePlugins(CraftServer.java:345) [spigot-1.13.2.jar:git-Spigot-a1ba5fe-3359cb1]
        at net.minecraft.server.v1_13_R2.MinecraftServer.l(MinecraftServer.java:584) [spigot-1.13.2.jar:git-Spigot-a1ba5fe-3359cb1]
        at net.minecraft.server.v1_13_R2.MinecraftServer.a(MinecraftServer.java:546) [spigot-1.13.2.jar:git-Spigot-a1ba5fe-3359cb1]
        at net.minecraft.server.v1_13_R2.MinecraftServer.a(MinecraftServer.java:424) [spigot-1.13.2.jar:git-Spigot-a1ba5fe-3359cb1]
        at net.minecraft.server.v1_13_R2.DedicatedServer.init(DedicatedServer.java:294) [spigot-1.13.2.jar:git-Spigot-a1ba5fe-3359cb1]
        at net.minecraft.server.v1_13_R2.MinecraftServer.run(MinecraftServer.java:702) [spigot-1.13.2.jar:git-Spigot-a1ba5fe-3359cb1]
        at java.lang.Thread.run(Unknown Source) [?:1.8.0_181]
Caused by: java.lang.ClassNotFoundException: org.json.JSONException
        at java.net.URLClassLoader.findClass(Unknown Source) ~[?:1.8.0_181]
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:154) ~[spigot-1.13.2.jar:git-Spigot-a1ba5fe-3359cb1]
        at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:100) ~[spigot-1.13.2.jar:git-Spigot-a1ba5fe-3359cb1]
        at java.lang.ClassLoader.loadClass(Unknown Source) ~[?:1.8.0_181]
        at java.lang.ClassLoader.loadClass(Unknown Source) ~[?:1.8.0_181]
        ... 15 more

Error while getting session token: <!DOCTYPE html> ...

An error occured while connecting...
fr.delthas.skype.ParseException: Error while getting session token: <!DOCTYPE html><!-- ServerInfo: BAYIDSLGN3E062 2016.11.15.02.06.59 Live1 Unknown LocVer:0 -->
<!-- PreprocessInfo: BTSA007:RR1BLDF116,  - Version: 16,0,26754,0 -->
<!-- RequestLCID: 1033, Market:EN-US, PrefCountry: US, LangLCID: 1033, LangISO: EN -->
<html dir="ltr" lang="EN-US"><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"/><meta http-equiv="X-UA-Compatible" content="IE=Edge"/><base href="https://login.live.com/pp1600/"/><script type="text/javascript">var PROOF = {};PROOF.Type = {SQSA: 6, CSS: 5, DeviceId: 4, Email: 1, AltEmail: 2, SMS: 3, HIP: 8, Birthday: 9, TOTPAuthenticator: 10, RecoveryCode: 11, StrongTicket: 13, TOTPAuthenticatorV2: 14, Voice: -3};</script><noscript><meta http-equiv="Refresh" content="0; URL=https://login.live.com/jsDisabled.srf?mkt=EN-US&lc=1033"/>Microsoft account requires JavaScript to sign in. This web browser either does not support JavaScript, or scripts are being blocked.<br /><br />To find out whether your browser supports JavaScript, or to allow scripts, see the browser's online help.</noscript><title>Sign in to your Microsoft account</title><meta name="PageID" content="i5030"/><meta name="SiteID" content="293290"/><meta name="ReqLC" content="1033"/><meta name="LocLC" content="1033"/><meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no"/><link rel="shortcut icon" href="https://auth.gfx.ms/16.000.26754.00.1/images/favicon.ico" />
        <link rel="stylesheet" title="Default" type="text/css" href="https://auth.gfx.ms/16.000.26754.00.1/Default1033.css"/><style type="text/css">@font-face
    {
        font-family: 'Segoe UI Webfont';
        src: url("//i.s-microsoft.com/fonts/segoe-ui/west-european/light/latest.eot");
        src: local("Segoe UI Light"), url("//i.s-microsoft.com/fonts/segoe-ui/west-european/light/latest.eot?#iefix") format("embedded-opentype"), url("//i.s-microsoft.com/fonts/segoe-ui/west-european/light/latest.woff") format("woff"), url("//i.s-microsoft.com/fonts/segoe-ui/west-european/light/latest.ttf") format("truetype"), url("//i.s-microsoft.com/fonts/segoe-ui/west-european/light/latest.svg#web") format("svg");
        font-weight: 200;
        font-style: normal;
    }
    @font-face
    {
        font-family: 'Segoe UI Webfont';
        src: url("//i.s-microsoft.com/fonts/segoe-ui/west-european/normal/latest.eot");
        src: local("Segoe UI"), url("//i.s-microsoft.com/fonts/segoe-ui/west-european/normal/latest.eot?#iefix") format("embedded-opentype"), url("//i.s-microsoft.com/fonts/segoe-ui/west-european/normal/latest.woff") format("woff"), url("//i.s-microsoft.com/fonts/segoe-ui/west-european/normal/latest.ttf") format("truetype"), url("//i.s-microsoft.com/fonts/segoe-ui/west-european/normal/latest.svg#web") format("svg");
        font-weight: 400;
        font-style: normal;
    }
    @font-face
    {
        font-family: 'Segoe UI Webfont';
        src: url("//i.s-microsoft.com/fonts/segoe-ui/west-european/semibold/latest.eot");
        src: local("Segoe UI Semibold"), url("//i.s-microsoft.com/fonts/segoe-ui/west-european/semibold/latest.eot?#iefix") format("embedded-opentype"), url("//i.s-microsoft.com/fonts/segoe-ui/west-european/semibold/latest.woff") format("woff"), url("//i.s-microsoft.com/fonts/segoe-ui/west-european/semibold/latest.ttf") format("truetype"), url("//i.s-microsoft.com/fonts/segoe-ui/west-european/semibold/latest.svg#web") format("svg");
        font-weight: 600;
        font-style: normal;
    }
    body.cb input[type="color"],
    body.cb input[type="date"],
    body.cb input[type="datetime"],
    body.cb input[type="datetime-local"],
    body.cb input[type="email"],
    body.cb input[type="month"],
    body.cb input[type="number"],
    body.cb input[type="password"],
    body.cb input[type="search"],
    body.cb input[type="tel"],
    body.cb input[type="text"],
    body.cb input[type="time"],
    body.cb input[type="url"],
    body.cb input[type="week"],
    body.cb select,
    body.cb .input-group-addon
    {
        border-width: 0 0 1px 0;
        outline: 0;
    }
    body.cb input.hip
    {
        border-width: 0 0 1px 0 !important;
    }
    html[dir="ltr"] body.cb div.placeholder,
    body.cb div.placeholder.ltr_override
    {
        margin-left: 7px;
    }
    html[dir="rtl"] body.cb div.placeholder
    {
        margin-right: 7px;
    }
    body.cb #maincontent
    {
        padding-left: 24px;
        padding-right: 24px;
    }
    body.cb select::-ms-value
    {
        background-color: transparent;
    }
    body.cb a
    {
        font-weight: 600;
    }
    body.cb option
    {
        color: #000;
    }
    body.cb .btn
    {
        height: 36px;
        border-radius: 25px;
        border-color: transparent;
    }
    body.cb .btn.btn-primary.btn-image
    {
        background-image: url(https://auth.gfx.ms/16.000.26754.00.1/images/SkypeArrows/Skype-arrow-all.png);
        background-position:  0px 0px;
        background-repeat: no-repeat;
        background-color: transparent !important;
        width: 64px;
        min-width: 64px;
        max-width: 64px;
        height: 64px;
        padding: 0;
        border: 0;
        border-radius: 0;
        color: transparent !important;
    }
    body.cb .btn.btn-image:hover
    {
        background-position: 0 -64px;
    }
    body.cb .btn.btn-primary.btn-image:active
    {
        background-color: transparent !important;
        background-position: 0 -128px;
    }
    body.cb .btn.btn-image.disabled
    {
        background-image: url(https://auth.gfx.ms/16.000.26754.00.1/images/SkypeArrows/Skype-arrow-disabled.png);
    }
    body.cb .btn.btn-primary.btn-image-svg
    {
        background-image: url(https://auth.gfx.ms/16.000.26754.00.1/images/SkypeArrows/Skype-arrow-all.svg);
    }
    body.cb .btn.btn-primary.btn-image-svg.disabled
    {
        background-image: url(https://auth.gfx.ms/16.000.26754.00.1/images/SkypeArrows/Skype-arrow-disabled.svg);
    }
    html[dir="rtl"] body.cb .btn.btn-image
    {
        background-image: url(https://auth.gfx.ms/16.000.26754.00.1/images/SkypeArrows/Skype-arrow-all-rtl.png);
    }
    html[dir="rtl"] body.cb .btn.btn-primary.btn-image-svg
    {
        background-image: url(https://auth.gfx.ms/16.000.26754.00.1/images/SkypeArrows/Skype-arrow-all-rtl.svg);
    }
    html[dir="rtl"] body.cb .btn.btn-image.disabled
    {
        background-image: url(https://auth.gfx.ms/16.000.26754.00.1/images/SkypeArrows/Skype-arrow-disabled-rtl.png);
    }
    html[dir="rtl"] body.cb .btn.btn-primary.btn-image-svg.disabled
    {
        background-image: url(https://auth.gfx.ms/16.000.26754.00.1/images/SkypeArrows/Skype-arrow-disabled-rtl.svg);
    }
    body.cb .modalDialogContainer
    {
        max-width: 332px;
        width: 76%;
        width: calc(90% - 52px);
    }
body.cb .btn.btn-primary
    {
        border-color: transparent;
        background-color: #0b7db4 !important;
    }
    body.cb .btn.btn-primary:active
    {
        color: #0b7db4;
    }
body.cb .btn.btn-primary
    {
        color: #FFFFFF;
    }
body.cb .btn.btn-primary:hover, body.cb .btn.btn-primary:focus
    {
        border-color: #00AFF0;
    }
    body.cb .btn.btn-primary:active
    {
        border-color: #00AFF0;
        background-color: #00AFF0 !important;
    }
body.cb .btn
    {
        border-color: transparent;
        background-color: #0b7db4 !important;
    }
    body.cb .btn:active
    {
        color: #0b7db4;
    }
body.cb .btn
    {
        color: #FFFFFF;
    }
body.cb .btn:hover, body.cb .btn:focus
    {
        border-color: #00AFF0;
    }
    body.cb .btn:active
    {
        border-color: #00AFF0;
        background-color: #00AFF0 !important;
    }
body.cb,
        body.cb .text-secondary,
        body.cb select,
        body.cb label.input-group-addon
        {
            color: #2b2b30;
        }
        body.cb input::-ms-clear,
        body.cb input::-ms-clear:hover,
        body.cb select::-ms-expand,
        body.cb select::-ms-value
        {
            color: #2b2b30;
        }
        body.cb input[type='checkbox']::-ms-check,
        body.cb input[type='checkbox']:checked::-ms-check,
        body.cb input[type='checkbox']:hover::-ms-check,
        body.cb input[type='checkbox']:active::-ms-check
        {
            border-color: #2b2b30;
            color: #2b2b30;
            background-color: #fff;
            }
    body.cb .text-logotype,
    body.cb div.placeholder
    {
        color: rgba(43, 43, 48, 0.6);
    }
    body.cb input[type='color']:-ms-input-placeholder,
        body.cb input[type='date']:-ms-input-placeholder,
        body.cb input[type='datetime']:-ms-input-placeholder,
        body.cb input[type='datetime-local']:-ms-input-placeholder,
        body.cb input[type='email']:-ms-input-placeholder,
        body.cb input[type='month']:-ms-input-placeholder,
        body.cb input[type='number']:-ms-input-placeholder,
        body.cb input[type='password']:-ms-input-placeholder,
        body.cb input[type='search']:-ms-input-placeholder,
        body.cb input[type='tel']:-ms-input-placeholder,
        body.cb input[type='text']:-ms-input-placeholder,
        body.cb input[type='time']:-ms-input-placeholder,
        body.cb input[type='url']:-ms-input-placeholder,
        body.cb input[type='week']:-ms-input-placeholder,
        body.cb textarea:-ms-input-placeholder,
        body.cb input[type='password']::-ms-clear,
        body.cb input[type='password']::-ms-reveal
        {
            color: rgba(43, 43, 48, 0.6);
        }
        body.cb input[type='color']::-webkit-input-placeholder,
        body.cb input[type='date']::-webkit-input-placeholder,
        body.cb input[type='datetime']::-webkit-input-placeholder,
        body.cb input[type='datetime-local']::-webkit-input-placeholder,
        body.cb input[type='email']::-webkit-input-placeholder,
        body.cb input[type='month']::-webkit-input-placeholder,
        body.cb input[type='number']::-webkit-input-placeholder,
        body.cb input[type='password']::-webkit-input-placeholder,
        body.cb input[type='search']::-webkit-input-placeholder,
        body.cb input[type='tel']::-webkit-input-placeholder,
        body.cb input[type='text']::-webkit-input-placeholder,
        body.cb input[type='time']::-webkit-input-placeholder,
        body.cb input[type='url']::-webkit-input-placeholder,
        body.cb input[type='week']::-webkit-input-placeholder,
        body.cb textarea::-webkit-input-placeholder
        {
            color: rgba(43, 43, 48, 0.6);
        }
        body.cb input[type='color']:-moz-placeholder,
        body.cb input[type='date']:-moz-placeholder,
        body.cb input[type='datetime']:-moz-placeholder,
        body.cb input[type='datetime-local']:-moz-placeholder,
        body.cb input[type='email']:-moz-placeholder,
        body.cb input[type='month']:-moz-placeholder,
        body.cb input[type='number']:-moz-placeholder,
        body.cb input[type='password']:-moz-placeholder,
        body.cb input[type='search']:-moz-placeholder,
        body.cb input[type='tel']:-moz-placeholder,
        body.cb input[type='text']:-moz-placeholder,
        body.cb input[type='time']:-moz-placeholder,
        body.cb input[type='url']:-moz-placeholder,
        body.cb input[type='week']:-moz-placeholder,
        body.cb textarea:-moz-placeholder
        {
            color: rgba(43, 43, 48, 0.6);
        }
        body.cb input[type='color']::-moz-placeholder,
        body.cb input[type='date']::-moz-placeholder,
        body.cb input[type='datetime']::-moz-placeholder,
        body.cb input[type='datetime-local']::-moz-placeholder,
        body.cb input[type='email']::-moz-placeholder,
        body.cb input[type='month']::-moz-placeholder,
        body.cb input[type='number']::-moz-placeholder,
        body.cb input[type='password']::-moz-placeholder,
        body.cb input[type='search']::-moz-placeholder,
        body.cb input[type='tel']::-moz-placeholder,
        body.cb input[type='text']::-moz-placeholder,
        body.cb input[type='time']::-moz-placeholder,
        body.cb input[type='url']::-moz-placeholder,
        body.cb input[type='week']::-moz-placeholder,
        body.cb textarea::-moz-placeholder
        {
            color: rgba(43, 43, 48, 0.6);
        }
        body.cb input::-ms-reveal,
        body.cb input::-ms-clear
        {
            color: rgba(43, 43, 48, 0.6);
        }
    body.cb a,
    body.cb a:visited,
    body.cb a:hover
    {
        color: #0b7db4;
    }
body.cb .alert-error
        {
            color: #667486;
        }
        body.cb label.input-group-addon.has-error
        {
            border-color: #667486;
        }
        body.cb input:not([type='submit']):not([type='button']).has-error,
        body.cb input:focus:not([type='submit']):not([type='button']).has-error,
        body.cb input:focus:hover:not([type='submit']):not([type='button']).has-error
        {
            border-color: #667486;
        }
    </style><style type="text/css">body{display:none;}</style><script type="text/javascript">if (top != self){try{top.location.replace(self.location.href);}catch (e){}}else{document.write(unescape('%3C%73') + 'tyle type="text/css">body{display:block !important;}</style>');}</script><noscript><style type="text/css">body{display:block !important;}</style></noscript><script type="text/javascript">var g_iSRSFailed=0,g_sSRSSuccess="";function SRSRetry(a,f,b){var e=1,d=unescape('%3Cscript type="text/javascript" src="'),c=unescape('"%3E%3C/script%3E');if(g_sSRSSuccess.indexOf(a)!=-1)return;if(typeof window[a]=="undefined"){g_iSRSFailed=1;b<=e&&document.write(d+f+c)}else g_sSRSSuccess+=a+"|"+b+","}
  var g_dtFirstByte=new Date();var g_objPageMode = null;</script><link rel="image_src" href="https://auth.gfx.ms/16.000.26754.00.1/images/Windows_Live_v_thumb.jpg" />
<script type="text/javascript">var ServerData = {Bi:false,Bk:0,Bm:'PPFT',aB:"&copy;2016 Microsoft",aC:'',aD:'',urlCdn:'https://auth.gfx.ms/16.000.26754.00.1/',aE:2,Bs:'https://login.live.com/GetCredentialType.srf?wa=wsignin1.0&rpsnv=13&ct=1479992512&rver=6.6.6577.0&wp=MBI_SSL&wreply=https%3A%2F%2Flw.skype.com%2Flogin%2Foauth%2Fproxy%3Fsite_name%3Dlw.skype.com&id=293290&uaid=cf7ab26afb416d089612ea012e1ec0ea&cobrandid=90010&client_flight=hsu%2Chlm%2Chld%2CReservedFlight33%2CReservedFlight67&psi=skype&vv=1600&mkt=EN-US&lc=1033',aL:true,aO:0,aP:1033,aS:'',urlLogin:'https://login.live.com/login.srf?wa=wsignin1.0&rpsnv=13&ct=1479992512&rver=6.6.6577.0&wp=MBI_SSL&wreply=https%3A%2F%2Flw.skype.com%2Flogin%2Foauth%2Fproxy%3Fsite_name%3Dlw.skype.com&id=293290&uaid=cf7ab26afb416d089612ea012e1ec0ea&username=mrpowergamerbr&cobrandid=90010&client_flight=hsu%2Chlm%2Chld%2CReservedFlight33%2CReservedFlight67&psi=skype&contextid=39AF8D6147B513C0&bk=1479992513&mkt=EN-US&lc=1033',aU:'microsoft.com,https://corp.sts.microsoft.com/adfs/ls/?cbcxt=&vv=&username=&mkt=&lc=,urn:federation:MSFT|idcrltestns.com,http://p2.live.com/auth/federation/wsfederator.aspx?Action=login&Domain=idcrltestns.com&cbcxt=&vv=&username=&mkt=&lc=,Test IDCRL Federation Partner',aV:"Sign in to .",aW:"A single-use code lets you sign in without entering your password. This helps protect your account when you\'re using someone else\'s PC. <a href=\"http://explore.live.com/windows-live-sign-in-single-use-code-faq\" id=\"idPaneHelpOTCInfoLink9\" target=\"_blank\">Learn more</a>",aX:"Your session has timed out. To request a single use code, please <a href=\"javascript:NewOTCRequest()\">refresh the page</a>.",aZ:'cf7ab26afb416d089612ea012e1ec0ea',urlFed:'',ab:'',ad:'https://login.live.com/gls.srf?urlID=MSNPrivacyStatement&mkt=EN-US&vv=1600',af:true,sPOST_NewUser:'',ai:true,iProductIcon:2,urlPost:'https://login.live.com/ppsecure/post.srf?wa=wsignin1.0&rpsnv=13&ct=1479992512&rver=6.6.6577.0&wp=MBI_SSL&wreply=https%3A%2F%2Flw.skype.com%2Flogin%2Foauth%2Fproxy%3Fsite_name%3Dlw.skype.com&lc=1033&id=293290&mkt=en&username=mrpowergamerbr&cobrandid=90010&client_flight=hsu%2Chlm%2Chld%2CReservedFlight33%2CReservedFlight67&psi=skype&contextid=39AF8D6147B513C0&bk=1479992513&uaid=cf7ab26afb416d089612ea012e1ec0ea&pid=0',at:'',av:"#~#partnerdomain#~# does\'t use this service. Please sign in with a Microsoft account or create a new account. <a href=\"#~#WLPaneHelpInviteBlockedURL_LS#~#\" id=\"idPaneHelpInviteBlockedLink9\">Learn More</a>",ax:"Use the primary phone number you\'ve associated with your Microsoft account. <a href=\"http://explore.live.com/windows-live-sign-in-single-use-code-faq\" id=\"idPaneHelpOTCInfoLink9\" target=\"_blank\">Learn more</a>",A:true,fWebNgcFS:false,B:true,C:true,D:'https://signup.live.com/signup.aspx?wa=wsignin1.0&rpsnv=13&ct=1479992512&rver=6.6.6577.0&wp=MBI_SSL&wreply=https%3A%2F%2Flw.skype.com%2Flogin%2Foauth%2Fproxy%3Fsite_name%3Dlw.skype.com&id=293290&username=mrpowergamerbr&cobrandid=90010&client_flight=hsu%2Chlm%2Chld%2CReservedFlight33%2CReservedFlight67&psi=skype&contextid=39AF8D6147B513C0&bk=1479992513&uiflavor=web&uaid=cf7ab26afb416d089612ea012e1ec0ea&mkt=EN-US&lc=1033',sFedQS:'wa=wsignin1.0&wtrealm=uri:WindowsLiveID&wctx=wa%3Dwsignin1.0%26rpsnv%3D13%26ct%3D1479992512%26rver%3D6.6.6577.0%26wp%3DMBI_SSL%26wreply%3Dhttps%253A%252F%252Flw.skype.com%252Flogin%252Foauth%252Fproxy%253Fsite_name%253Dlw.skype.com%26lc%3D1033%26id%3D293290%26mkt%3Den%26uaid%3Dcf7ab26afb416d089612ea012e1ec0ea%26username%3Dmrpowergamerbr%26cobrandid%3D90010%26client_flight%3Dhsu%252Chlm%252Chld%252CReservedFlight33%252CReservedFlight67%26psi%3Dskype%26contextid%3D39AF8D6147B513C0%26bk%3D1479992513',G:'mrpowergamerbr',A0:false,A1:false,L:'wa=wsignin1.0&rpsnv=13&ct=1479992512&rver=6.6.6577.0&wp=MBI_SSL&wreply=https%3A%2F%2Flw.skype.com%2Flogin%2Foauth%2Fproxy%3Fsite_name%3Dlw.skype.com&lc=1033&id=293290&mkt=en&uaid=cf7ab26afb416d089612ea012e1ec0ea&username=mrpowergamerbr&cobrandid=90010&client_flight=hsu%2Chlm%2Chld%2CReservedFlight33%2CReservedFlight67&psi=skype&contextid=39AF8D6147B513C0&bk=1479992513',N:'https://login.live.com/cookiesDisabled.srf?mkt=EN-US&lc=1033',A4:true,O:false,A7:'',str:[],S:5,A9:'',T:60,U:'',Y:{},Z:{'Logo':'','LogoAltText':'','LogoText':'','ShowWLHeader':true},urlSwitch:'https://login.live.com/logout.srf?wa=wsignin1.0&rpsnv=13&ct=1479992512&rver=6.6.6577.0&wp=MBI_SSL&wreply=https%3A%2F%2Flw.skype.com%2Flogin%2Foauth%2Fproxy%3Fsite_name%3Dlw.skype.com&lc=1033&id=293290&mkt=en&uaid=cf7ab26afb416d089612ea012e1ec0ea&cobrandid=90010&client_flight=hsu%2Chlm%2Chld%2CReservedFlight33%2CReservedFlight67&psi=skype&contextid=39AF8D6147B513C0&ru=https://lw.skype.com/login/oauth/proxy%3fsite_name%3dlw.skype.com&bk=1479992513&lm=I&username=mrpowergamerbr',AB:'AF~Afghanistan~93!!!AL~Albania~355!!!DZ~Algeria~213!!!AD~Andorra~376!!!AO~Angola~244!!!AQ~Antarctica~672!!!AG~Antigua and Barbuda~1!!!AR~Argentina~54!!!AM~Armenia~374!!!AW~Aruba~297!!!AC~Ascension Island~247!!!AU~Australia~61!!!AT~Austria~43!!!AZ~Azerbaijan~994!!!BS~Bahamas~1!!!BH~Bahrain~973!!!BD~Bangladesh~880!!!BB~Barbados~1!!!BY~Belarus~375!!!BE~Belgium~32!!!BZ~Belize~501!!!BJ~Benin~229!!!BM~Bermuda~1!!!BT~Bhutan~975!!!BO~Bolivia~591!!!BA~Bosnia and Herzegovina~387!!!BW~Botswana~267!!!BV~Bouvet Island~47!!!BR~Brazil~55!!!IO~British Indian Ocean Territory~44!!!BN~Brunei~673!!!BG~Bulgaria~359!!!BF~Burkina Faso~226!!!BI~Burundi~257!!!CV~Cabo Verde~238!!!KH~Cambodia~855!!!CM~Cameroon~237!!!CA~Canada~1!!!KY~Cayman Islands~1!!!CF~Central African Republic~236!!!TD~Chad~235!!!CL~Chile~56!!!CN~China~86!!!CX~Christmas Island~61!!!CC~Cocos (Keeling) Islands~61!!!CO~Colombia~57!!!KM~Comoros~269!!!CG~Congo~242!!!CD~Congo (DRC)~243!!!CK~Cook Islands~682!!!CR~Costa Rica~506!!!HR~Croatia~385!!!CU~Cuba~53!!!CY~Cyprus~357!!!CZ~Czech Republic~420!!!DK~Denmark~45!!!DJ~Djibouti~253!!!DM~Dominica~1!!!DO~Dominican Republic~1!!!EC~Ecuador~593!!!EG~Egypt~20!!!SV~El Salvador~503!!!GQ~Equatorial Guinea~240!!!ER~Eritrea~291!!!EE~Estonia~372!!!ET~Ethiopia~251!!!FK~Falkland Islands~500!!!FO~Faroe Islands~298!!!FJ~Fiji Islands~679!!!FI~Finland~358!!!FR~France~33!!!GF~French Guiana~594!!!PF~French Polynesia~689!!!GA~Gabon~241!!!GM~Gambia, The~220!!!GE~Georgia~995!!!DE~Germany~49!!!GH~Ghana~233!!!GI~Gibraltar~350!!!GR~Greece~30!!!GL~Greenland~299!!!GD~Grenada~1!!!GP~Guadeloupe~590!!!GU~Guam~1!!!GT~Guatemala~502!!!GG~Guernsey~44!!!GN~Guinea~224!!!GW~Guinea-Bissau~245!!!GY~Guyana~592!!!HT~Haiti~509!!!VA~Holy See (Vatican City)~379!!!HN~Honduras~504!!!HK~Hong Kong SAR~852!!!HU~Hungary~36!!!IS~Iceland~354!!!IN~India~91!!!ID~Indonesia~62!!!IR~Iran~98!!!IQ~Iraq~964!!!IE~Ireland~353!!!IM~Isle of Man~44!!!IL~Israel~972!!!IT~Italy~39!!!JM~Jamaica~1!!!SJ~Jan Mayen~47!!!JP~Japan~81!!!JE~Jersey~44!!!JO~Jordan~962!!!KZ~Kazakhstan~7!!!KE~Kenya~254!!!KI~Kiribati~686!!!KR~Korea~82!!!KW~Kuwait~965!!!KG~Kyrgyzstan~996!!!LA~Laos~856!!!LV~Latvia~371!!!LB~Lebanon~961!!!LS~Lesotho~266!!!LR~Liberia~231!!!LY~Libya~218!!!LI~Liechtenstein~423!!!LT~Lithuania~370!!!LU~Luxembourg~352!!!MO~Macao SAR~853!!!MK~Macedonia, Former Yugoslav Republic of~389!!!MG~Madagascar~261!!!MW~Malawi~265!!!MY~Malaysia~60!!!MV~Maldives~960!!!ML~Mali~223!!!MT~Malta~356!!!MH~Marshall Islands~692!!!MQ~Martinique~596!!!MR~Mauritania~222!!!MU~Mauritius~230!!!YT~Mayotte~262!!!MX~Mexico~52!!!FM~Micronesia~691!!!MD~Moldova~373!!!MC~Monaco~377!!!MN~Mongolia~976!!!ME~Montenegro~382!!!MS~Montserrat~1!!!MA~Morocco~212!!!MZ~Mozambique~258!!!MM~Myanmar~95!!!NA~Namibia~264!!!NR~Nauru~674!!!NP~Nepal~977!!!NL~Netherlands~31!!!AN~Netherlands Antilles (Former)~599!!!NC~New Caledonia~687!!!NZ~New Zealand~64!!!NI~Nicaragua~505!!!NE~Niger~227!!!NG~Nigeria~234!!!NU~Niue~683!!!KP~North Korea~850!!!MP~Northern Mariana Islands~1!!!NO~Norway~47!!!OM~Oman~968!!!PK~Pakistan~92!!!PW~Palau~680!!!PS970~Palestinian Authority~970!!!PS~Palestinian Authority~972!!!PA~Panama~507!!!PG~Papua New Guinea~675!!!PY~Paraguay~595!!!PE~Peru~51!!!PH~Philippines~63!!!PL~Poland~48!!!PT~Portugal~351!!!QA~Qatar~974!!!CI~Republic of Côte d\'Ivoire~225!!!RE~Reunion~262!!!RO~Romania~40!!!RU~Russia~7!!!RW~Rwanda~250!!!SH~Saint Helena, Ascension and Tristan da Cunha~290!!!WS~Samoa~685!!!SM~San Marino~378!!!ST~São Tomé and Príncipe~239!!!SA~Saudi Arabia~966!!!SN~Senegal~221!!!RS~Serbia~381!!!SC~Seychelles~248!!!SL~Sierra Leone~232!!!SG~Singapore~65!!!SK~Slovakia~421!!!SI~Slovenia~386!!!SB~Solomon Islands~677!!!SO~Somalia~252!!!ZA~South Africa~27!!!ES~Spain~34!!!LK~Sri Lanka~94!!!KN~St. Kitts and Nevis~1!!!LC~St. Lucia~1!!!PM~St. Pierre and Miquelon~508!!!VC~St. Vincent and the Grenadines~1!!!SD~Sudan~249!!!SR~Suriname~597!!!SZ~Swaziland~268!!!SE~Sweden~46!!!CH~Switzerland~41!!!SY~Syria~963!!!TW~Taiwan~886!!!TJ~Tajikistan~992!!!TZ~Tanzania~255!!!TH~Thailand~66!!!TL~Timor-Leste~670!!!TG~Togo~228!!!TK~Tokelau~690!!!TO~Tonga~676!!!TT~Trinidad and Tobago~1!!!TA~Tristan da Cunha~290!!!TN~Tunisia~216!!!TR~Turkey~90!!!TM~Turkmenistan~993!!!TC~Turks and Caicos Islands~1!!!TV~Tuvalu~688!!!UG~Uganda~256!!!UA~Ukraine~380!!!AE~United Arab Emirates~971!!!UK~United Kingdom~44!!!US~United States~1!!!UM~United States Minor Outlying Islands~1!!!UY~Uruguay~598!!!UZ~Uzbekistan~998!!!VU~Vanuatu~678!!!VE~Venezuela~58!!!VN~Vietnam~84!!!VG~Virgin Islands, British~1!!!VI~Virgin Islands, U.S.~1!!!WF~Wallis and Futuna~681!!!YE~Yemen~967!!!ZM~Zambia~260!!!ZW~Zimbabwe~263',urlFedConvertRename:'https://account.live.com/security/LoginStage.aspx?lmif=1000&ru=https://login.live.com/login.srf%3Fwa%3Dwsignin1.0%26rpsnv%3D13%26ct%3D1479992512%26rver%3D6.6.6577.0%26wp%3DMBI_SSL%26wreply%3Dhttps%253A%252F%252Flw.skype.com%252Flogin%252Foauth%252Fproxy%253Fsite_name%253Dlw.skype.com%26id%3D293290%26uaid%3Dcf7ab26afb416d089612ea012e1ec0ea%26cobrandid%3D90010%26client_flight%3Dhsu%252Chlm%252Chld%252CReservedFlight33%252CReservedFlight67%26psi%3Dskype%26vv%3D1600%26mkt%3DEN-US%26lc%3D1033&wa=wsignin1.0&rpsnv=13&ct=1479992512&rver=6.6.6577.0&wp=MBI_SSL&wreply=https%3A%2F%2Flw.skype.com%2Flogin%2Foauth%2Fproxy%3Fsite_name%3Dlw.skype.com&uaid=cf7ab26afb416d089612ea012e1ec0ea&cobrandid=90010&client_flight=hsu%2Chlm%2Chld%2CReservedFlight33%2CReservedFlight67&psi=skype&vv=1600&mkt=EN-US&lc=1033&cbid=0&id=293290',AD:false,AE:0,b:'',AJ:false,e:'https://account.live.com/ResetPassword.aspx?wreply=https://login.live.com/login.srf%3fwa%3dwsignin1.0%26rpsnv%3d13%26ct%3d1479992512%26rver%3d6.6.6577.0%26wp%3dMBI_SSL%26wreply%3dhttps%253A%252F%252Flw.skype.com%252Flogin%252Foauth%252Fproxy%253Fsite_name%253Dlw.skype.com%26lc%3d1033%26id%3d293290%26mkt%3den%26uaid%3dcf7ab26afb416d089612ea012e1ec0ea%26username%3dmrpowergamerbr%26cobrandid%3d90010%26client_flight%3dhsu%252Chlm%252Chld%252CReservedFlight33%252CReservedFlight67%26psi%3dskype%26contextid%3d39AF8D6147B513C0%26bk%3d1479992513&id=293290&uiflavor=web&cobrandid=90010&uaid=cf7ab26afb416d089612ea012e1ec0ea&mkt=EN-US&lc=1033&bk=1479992513',AK:1,AL:'',g:1,h:true,AN:'',i:'',AO:'',k:3,o:true,AU:{},sCBUpTxt1:'',q:false,AW:'',sCBUpTxt2:'',s:1,t:'Passpor',AZ:false,v:false,w:true,oPost:{},z:'mrpowergamerbr',Aa:'',BA:'',BB:false,Ac:'https://login.live.com/GetSessionState.srf?wa=wsignin1.0&rpsnv=13&ct=1479992512&rver=6.6.6577.0&wp=MBI_SSL&wreply=https%3A%2F%2Flw.skype.com%2Flogin%2Foauth%2Fproxy%3Fsite_name%3Dlw.skype.com&id=293290&uaid=cf7ab26afb416d089612ea012e1ec0ea&cobrandid=90010&client_flight=hsu%2Chlm%2Chld%2CReservedFlight33%2CReservedFlight67&psi=skype&vv=1600&mkt=EN-US&lc=1033',Ae:false,BE:true,Ag:0,BF:false,BG:true,Ah:true,BK:10000,sErrTxt:'',Am:'',BM:'',Ao:'',BO:"Sign in",html:[],sFTTag:'<input type="hidden" name="PPFT" id="i0327" value="DYguCOgQSY!jZvwG!X2Y1!2bXaHUkhaRuVm3vt777ImEOHl6o0VCd7g2ULuDDslNawpW!JgitM43LqX9e31uohqmXEZrwK9cWRQlOwU65MgLy9VleZUTPuyl9nQpo!0LOBnb6A52UvJvRo3!*chGPveNjWzDe*inWrmxW8Z2YYZjCho8KT4YmLt!PyGll6pxsGEvU1DdGLGXDJkHH8eWLDd9Z!mxYf0!Kf6r9YCuftLJrR3nCLek7yGvpLxfRrTFY7ZIWfBLj!SS6fbiUKTXt!w$"/>',Ar:false,BR:'',At:0,Au:{},Aw:'',Ax:'https://go.microsoft.com/fwlink/?LinkID=254486',a0:'https://account.live.com/query.aspx?uaid=cf7ab26afb416d089612ea012e1ec0ea&mkt=EN-US&lc=1033&id=293290',fHasBackgroundColor:false,urlStaySignIn:'https://login.live.com/login.srf?wa=wsignin1.0&rpsnv=13&ct=1479992512&rver=6.6.6577.0&wp=MBI_SSL&wreply=https%3A%2F%2Flw.skype.com%2Flogin%2Foauth%2Fproxy%3Fsite_name%3Dlw.skype.com&id=293290&uaid=cf7ab26afb416d089612ea012e1ec0ea&cobrandid=90010&client_flight=hsu%2Chlm%2Chld%2CReservedFlight33%2CReservedFlight67&psi=skype&contextid=39AF8D6147B513C0&mkt=EN-US&lc=1033&bk=1479992513',a2:'',a3:'',a4:'',Bb:false,a5:'',Bc:false,a6:'',Bd:false,a7:'',a8:'https://login.live.com/gls.srf?urlID=WinLiveTermsOfUse&mkt=EN-US&vv=1600',Be:false,Bf:true,Bg:true};</script><script type="text/javascript" src="https://auth.gfx.ms/16.000.26754.00.1/DefaultLoginPaginatedStrings.EN.js"></script>
    <script type="text/javascript" src="https://auth.gfx.ms/16.000.26754.00.1/DefaultLogin_PCore.js"></script>
    <script type="text/javascript">SRSRetry("__DefaultLoginPaginatedStrings", "https://auth.gfx.ms/16.000.26754.00.1/DefaultLoginPaginatedStrings.EN.js", 1);SRSRetry("__DefaultLogin_PCore", "https://auth.gfx.ms/16.000.26754.00.1/DefaultLogin_PCore.js", 1);</script><script type="text/javascript">SRSRetry("__DefaultLoginPaginatedStrings", "https://auth.gfx.ms/16.000.26754.00.1/DefaultLoginPaginatedStrings.EN.js", 2);SRSRetry("__DefaultLogin_PCore", "https://auth.gfx.ms/16.000.26754.00.1/DefaultLogin_PCore.js", 2);</script></head>
<body class="cb" data-bind="defineGlobals: ServerData, bodyCssClass">
</body></html>
	at fr.delthas.skype.WebConnector.generateTokens(WebConnector.java:194)
	at fr.delthas.skype.WebConnector.start(WebConnector.java:39)
	at fr.delthas.skype.Skype.connect(Skype.java:113)
	at fr.delthas.skype.Skype.connect(Skype.java:87)
	at com.mrpowergamerbr.teste.Teste.main(Teste.java:19)

Error message received: 911 2 CON 23 (#3)

  • OS, Version, Architecture (e.g. Windows 8.1 x64):
  • JRE Vendor, Version (e.g. Oracle JDK 8u151):

Expected behaviour

Connecting to skype

Actual behaviour

it connect to skype and retrieve contacts, but it throw exception

if (this.exceptionDuringConnection != null) {
throw new IOException("Error thrown during connection. Check your credentials?", this.exceptionDuringConnection);
} else {
this.refreshThread.start();
}

Steps to reproduce the issue

skype.connect();

Logs

Add debug logs (or link to them) if reporting a bug. For that call Skype.setDebug(path) at any time before calling skype.connect().

https://gist.github.com/S1moB/5e0141f57ccad9665d86a5eb20ffbc3b

"Skype-Receiver-Thread" java.lang.IllegalArgumentException - on Skype#connect

Exception in thread "Skype-Receiver-Thread" java.lang.IllegalArgumentException
    at fr.delthas.skype.NotifConnector.parseEntity(NotifConnector.java:597)
    at fr.delthas.skype.NotifConnector.updateThread(NotifConnector.java:559)
    at fr.delthas.skype.NotifConnector.processPacket(NotifConnector.java:152)
    at fr.delthas.skype.NotifConnector.lambda$connect$2(NotifConnector.java:405)
    at fr.delthas.skype.NotifConnector$$Lambda$2/141289226.run(Unknown Source)
    at java.lang.Thread.run(Thread.java:745)
Skype skype = new Skype(USERNAME, PASSWORD);
try {
    skype.connect();
} catch (IOException | InterruptedException e) {
    e.printStackTrace();
}

skype.setErrorListener(Exception::printStackTrace);

skype.addGroupMessageListener(((group, user, message) -> {
    if (message.equalsIgnoreCase("hi")) {
        group.sendMessage("hi, " + user.getUsername());
    } else if (message.equalsIgnoreCase("stop")) {
        running = false;
    }
}));

I used IntelliJ's debugger to find where the issue was happening:
screenshot

Method connect() always throw exeption

Skype skype = new Skype("oldSkype.login","pass");
skype.connect();

Every time after calling .connect() i have exeption:
Error thrown during connection. Check your credentials?

Also propblem with
fr.delthas.skype.ParseException: org.json.JSONException: JSONObject["name"] not found.

Error while parsing entity 28

Hello,

I installed JavaSkype 1.0.22 using Maven on Eclipse.
Running a basic example(one its worked in a previous version and same skype user) i am getting this out:

Exception in thread "Skype-Receiver-Thread" java.lang.IllegalArgumentException at fr.delthas.skype.NotifConnector.parseEntity(NotifConnector.java:792) at fr.delthas.skype.NotifConnector.updateThread(NotifConnector.java:738) at fr.delthas.skype.NotifConnector.processPacket(NotifConnector.java:254) at fr.delthas.skype.NotifConnector.lambda$new$0(NotifConnector.java:73) at java.lang.Thread.run(Unknown Source)

Enabling debug i see in the log file this at the last two lines:
nov 22, 2017 10:49:52 PM fr.delthas.skype.NotifConnector parseEntity ADVERTENCIA: Error while parsing entity 28:0d5d6cff-595d-49d7-9cf8-973173f5233b: unknown network:28

Thank you in advance

Too many failed authentication attempts with given username or IP.

Can not connect to skype by username & password.

Skype skype = new Skype("live:atulsinfo", "password");
Please tell me the reason behind this. I have tried from different valid account. But could not be connected.

Logs

java.io.IOException: Error while connecting to Skype: Too many failed authentication attempts with given username or IP.
at fr.delthas.skype.WebConnector.generateTokens(WebConnector.java:171)
at fr.delthas.skype.WebConnector.start(WebConnector.java:42)
at fr.delthas.skype.Skype.connect(Skype.java:121)
at fr.delthas.skype.Skype.connect(Skype.java:96)
at com.bot.skypeBot.service.TestService.testConnection(TestService.java:19)
at com.bot.skypeBot.controller.api.TestController.registerAccount(TestController.java:19)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:209)
at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:136)
at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:102)
at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:877)
at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:783)
at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87)
at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:991)
at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:925)
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:974)
at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:866)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:635)
at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:851)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:742)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:99)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.springframework.web.filter.HttpPutFormContentFilter.doFilterInternal(HttpPutFormContentFilter.java:109)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:93)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:200)
at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:198)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:493)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:342)
at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:800)
at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:800)
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1471)
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
at java.lang.Thread.run(Thread.java:748)

Add a way to get the recent/last messages from a conversation (with user or group)

MrPowerGamerBR : There isn't any way to get the messages sent to a contact/group? Skype4J allows to get all the messages in a conversation with a contact/group, however JavaSkype doesn't have a method to do it.
delthas : You mean the recent/last messages in a conversation? Like a User#getRecentMessages or a Group#getRecentMessages that returns a list of the last messages sent on a conversation? I can add that.
MrPowerGamerBR : Yes, it would be awesome if you added that. :) (In Skype4J it is like this: .loadMessages(int amount) loads the messages and getAllMessages returns the messages loaded in chronological order (from older to newest))

Exception in thread "Skype-Receiver-Thread" java.lang.IllegalArgumentException: Must supply a valid URL

        at org.jsoup.helper.Validate.notEmpty(Validate.java:102)
        at org.jsoup.helper.HttpConnection.url(HttpConnection.java:72)
        at org.jsoup.helper.HttpConnection.connect(HttpConnection.java:36)
        at org.jsoup.Jsoup.connect(Jsoup.java:73)
        at fr.delthas.skype.WebConnector.sendRequest(WebConnector.java:190)
        at fr.delthas.skype.WebConnector.getAvatar(WebConnector.java:71)
        at fr.delthas.skype.Skype.getAvatar(Skype.java:319)
        at fr.delthas.skype.User.getAvatar(User.java:167)
        at com.mrpowergamerbr.sparklywhistlerbot.SkypeWhistler.lambda$0(SkypeWhistler.java:31)
        at fr.delthas.skype.Skype.groupMessageReceived(Skype.java:434)
        at fr.delthas.skype.NotifConnector.processPacket(NotifConnector.java:241)
        at fr.delthas.skype.NotifConnector.lambda$connect$4(NotifConnector.java:516)
        at java.lang.Thread.run(Thread.java:745)

At line 31

System.out.println(user.getAvatar());

[ArchLinux] No live:account login, not showing last messages

This is very very bad written in Java.
Maven is not necessary:

  • Jsoup is not necessary (you can use regular expressions)
  • Json is not necessary (you can use regular expressions or gson to improve performance and RAM usage)

First:
You are using the Java Native xml Document with Jsoup parsed Document.
What is it?

import org.w3c.dom.Document;
import org.w3c.dom.Node;
import org.w3c.dom.NodeList;
import org.xml.sax.InputSource;
import org.xml.sax.SAXException;

If you are using Jsoup this is not necessary (or if you are using regular expressions).

I have no time to modify the code and push in separate branch to github. Because full rewrite is needed.

Bad performance. What is it?

NodeList conversationNodes = doc.getElementsByTagName("conversation");
List<String> threadIds = new ArrayList<>();
outer:
for (int i = 0; i < conversationNodes.getLength(); i++) {
   Node conversation = conversationNodes.item(i);
   String id = null;
   boolean isThread = false;
   NodeList conversationChildren = conversation.getChildNodes();
...
...

You are using "branching statements". outer:. Please don't do this, is very bad practice.

You should use only the Jsoup library or only regular expressions. (You are using Jsoup parser with org.w3c.dom.Document)
Example:

Elements conversations = body.select("conversation");
 for (Element conversation : conversations) {
// this is not necessarry at the moment because the messageid contains the id
//  String id = conversation.getElementsByTag("id").first().text();
    Elements messages = conversation.getElementsByTag("message");
    for (Element message : messages) {
    String originalarrivaltime = message.getElementsByTag("originalarrivaltime").first().text();
    String composeTime = message.getElementsByTag("composetime").first().text();
    String from = message.getElementsByTag("from").first().text();
    String messageType = message.getElementsByTag("messagetype").first().text();
    String content = message.getElementsByTag("content").first().text();
    String conversationID = message.getElementsByTag("conversationid").first().text();
    User u = (User) parseEntity(from);
    try {
       skype.userMessageReceived(conversationID, u, dateFormatA.format(dateFormatDe.parse(originalarrivaltime)), dateFormatA.format(dateFormatDe.parse(composeTime)), messageType, content);
       } catch (java.text.ParseException ex) {
          ex.printStackTrace();
                  }
          }
}

The above code works to show the last offline/online messages of contacts.
Retouching that kind of code leaves me with rage. I do not know you and I do not know who taught you to program but you can tell him that he is a bad teacher.

You have a simple problem and you are creating "sophisticated" and wrong solutions. In other words, you are catching the server response but you don't show it to the user.
Instead of showing it you are creating incomplete filters that are using more resources.
Remember: Jsoup not needed. (And if you have more time, Json is not needed)

Maven? Never use it. If you want to have automated things use Gradle (best performance)
https://gradle.org/maven-vs-gradle/

The README file show an example to use this library. Before invoking the connect() method, the listeners must be registered.

PostData: I never use Gradle, Maven, etc.

Server returned HTTP response code: 400 for URL: http://api.skype.com/users/batch/profiles

java.io.IOException: Server returned HTTP response code: 400 for URL: http://api.skype.com/users/batch/profiles
    at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1840)
    at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1441)
    at fr.delthas.skype.WebConnector.sendRequestJson(WebConnector.java:260)
    at fr.delthas.skype.WebConnector.updateContacts(WebConnector.java:115)
    at fr.delthas.skype.WebConnector.start(WebConnector.java:44)
    at fr.delthas.skype.Skype.connect(Skype.java:92)
    at fr.delthas.skype.Skype.connect(Skype.java:68)
    at com.mrpowergamerbr.wow.Testing.main(Testing.java:12)

All contacts are loaded, but all of them are shown as "OFFLINE" and doesn't have any mood.

fr.delthas.skype.ParseException: org.json.JSONException: Unterminated string at 1041975 [character 1041976 line 1]

An error occured while connecting...
fr.delthas.skype.ParseException: org.json.JSONException: Unterminated string at 1041975 [character 1041976 line 1]
	at fr.delthas.skype.WebConnector.updateContacts(WebConnector.java:97)
	at fr.delthas.skype.WebConnector.start(WebConnector.java:43)
	at fr.delthas.skype.Skype.connect(Skype.java:113)
	at fr.delthas.skype.Skype.connect(Skype.java:87)
	at com.mrpowergamerbr.sparklywhistlerbot.utils.DebugSkype.main(DebugSkype.java:25)
Caused by: org.json.JSONException: Unterminated string at 1041975 [character 1041976 line 1]
	at org.json.JSONTokener.syntaxError(JSONTokener.java:433)
	at org.json.JSONTokener.nextString(JSONTokener.java:261)
	at org.json.JSONTokener.nextValue(JSONTokener.java:361)
	at org.json.JSONObject.<init>(JSONObject.java:215)
	at org.json.JSONTokener.nextValue(JSONTokener.java:364)
	at org.json.JSONArray.<init>(JSONArray.java:116)
	at org.json.JSONTokener.nextValue(JSONTokener.java:367)
	at org.json.JSONObject.<init>(JSONObject.java:215)
	at org.json.JSONObject.<init>(JSONObject.java:319)
	at fr.delthas.skype.WebConnector.updateContacts(WebConnector.java:90)
	... 4 more

Full skype.log
https://gist.github.com/MrPowerGamerBR/ea81dc8c0a108f3076eaf7fc2bdabe75

This only happens with my main account

unable to connect a microsoft account

Hello, following the update I am trying to connect a microsoft account.
Here is the error found in the log file

nov. 13, 2017 9:09:12 PM fr.delthas.skype.Skype connect
PRÉCIS: Connecting to Skype
nov. 13, 2017 9:09:12 PM fr.delthas.skype.Skype reset
LE PLUS PRÉCIS: Resetting the Skype object
nov. 13, 2017 9:09:12 PM fr.delthas.skype.NotifConnector generateEPID
LE PLUS PRÉCIS: Generated EPID: 0ad5830b-a83e-307e-683c-6fa00e105c44
nov. 13, 2017 9:09:12 PM fr.delthas.skype.LiveConnector refreshTokens
PLUS PRÉCIS: Refreshing tokens
nov. 13, 2017 9:09:16 PM fr.delthas.skype.LiveConnector refreshTokens
PLUS PRÉCIS: Refreshed live tokens successfully
nov. 13, 2017 9:09:16 PM fr.delthas.skype.WebConnector refreshTokens
PLUS PRÉCIS: Refreshing tokens
nov. 13, 2017 9:09:16 PM fr.delthas.skype.WebConnector generateToken
LE PLUS PRÉCIS: Getting Microsoft token
nov. 13, 2017 9:09:16 PM fr.delthas.skype.WebConnector sendRequest
LE PLUS PRÉCIS: Sending POST request at https://api.skype.com/rps/skypetoken
nov. 13, 2017 9:09:16 PM fr.delthas.skype.WebConnector sendRequest
PRÉCIS: No token sent for the request at: https://api.skype.com/rps/skypetoken
nov. 13, 2017 9:09:17 PM fr.delthas.skype.WebConnector sendRequest
LE PLUS PRÉCIS: Sending GET request at https://api.skype.com/users/self/profile
nov. 13, 2017 9:09:17 PM fr.delthas.skype.WebConnector sendRequest
LE PLUS PRÉCIS: Sending GET request at https://contacts.skype.com/contacts/v1/users/live:fabien900z/contacts?$filter=authorized eq true and blocked eq false and suggested eq false

Thank you in advance for your help ;)
Fabien

Add contact requests fetching

Skype#getContactRequests() can list contact requests but these are never actually created because WebConnector doesn't fetch contact requests at startup/every n seconds.

Error: Feature Set not enabled or wait forever at: connectLatch.await()

Hi @delthas

I can't send the skype message. I describe the error below:
Could you help me.
Thank you.

  • OS, Version, Architecture (e.g. Windows 8.1 x64): windows 10
  • JRE Vendor, Version (e.g. Oracle JDK 8u151): jdk 1.8.0_131

Expected behaviour

Send message to an user

Actual behaviour

get error:
fr.delthas.skype.ParseException: Error message received:
202 2 MSGR 26

Feature Set not enabled.
at fr.delthas.skype.NotifConnector.readPacket(NotifConnector.java:552)
at fr.delthas.skype.NotifConnector.lambda$new$0(NotifConnector.java:69)
at java.lang.Thread.run(Thread.java:748)
Exception in thread "Skype-Receiver-Thread" java.lang.AssertionError: Error message received:
202 2 MSGR 26

Feature Set not enabled.
at org.junit.Assert.fail(Assert.java:88)
at fr.delthas.skype.TestConnect.lambda$testConnect$0(TestConnect.java:48)
at fr.delthas.skype.Skype.error(Skype.java:281)
at fr.delthas.skype.NotifConnector.lambda$new$0(NotifConnector.java:81)
at java.lang.Thread.run(Thread.java:748)

Steps to reproduce the issue

  • Get source

  • Apply bug fix: d03n3rfr1tz3@9e862e6

  • Comment out line:
    // connectLatch.await(); // block until connected
    at fr/delthas/skype/NotifConnector.java:587
    (because if i do not comment out, the application will hang out at this line forever)

  • Fill username and pass, run TestConnect.java like this:

public void testConnect() {
Skype skype = new Skype("[email protected]", "mypassword");

try {
    skype.connect();

    for (User user : skype.getContacts()) {
        System.out.println("user: " + user);
        if (user.getUsername().equalsIgnoreCase("my-friend-user")){
            user.sendMessage("Hi, " + user.getDisplayName() + ", what's up?");
        }
    }

} catch (Exception e) {
    e.printStackTrace();
    Assert.fail(e.getMessage());
}

}

Logs

Add debug logs (or link to them) if reporting a bug. For that call Skype.setDebug(path) at any time before calling skype.connect().

group.getUsers function always return 0

Hi,

I think code will explain everything.

Skype skype = new Skype("bot", "xxx");
skype.connect();
System.out.println("Bot is connected");
List groups = skype.getGroups();
// I have 2 groups
System.out.println(groups.size());
for (Group group : groups) {
List<Pair<User, Role>> usersWithRoles = group.getUsersWithRoles();
System.out.println(usersWithRoles.size());
List users = group.getUsers();
System.out.println(users.size());
}
System.out.println("Bot is disconnected");

output is:
Bot is connected
2
0
0
0
0
Bot is disconnected

Moods are broken.

When you try to get a user's mood, it returns null instead of the users mood.

Add image (file) sending support

I'm not sure if Web Skype allows image (or any file) sending, so...

But if it does support, it would be nice if the API supported sending images.

(And getting images from received messages)

groups.values() are always empty

Expected behaviour

There are several groups, but it always returns an empty list.

Actual behaviour

Groups should be returned

Steps to reproduce the issue

Call getGroups() method.

fr.delthas.skype.ParseException: Error message received: 911 2 CON 23 (#2)

Error 911 2 CON 23 is repeated. Not always. Sometimes. OS Debian 8.
Windows 7 OS - all good!

`Mar 22, 2017 12:28:52 PM fr.delthas.skype.NotifConnector readPacket
SEVERE:
fr.delthas.skype.ParseException: Error message received:
911 2 CON 23

Authentication failed
at fr.delthas.skype.NotifConnector.readPacket(NotifConnector.java:484)
at fr.delthas.skype.NotifConnector.lambda$connect$4(NotifConnector.java:512)
at java.lang.Thread.run(Thread.java:745)

Mar 22, 2017 12:28:52 PM fr.delthas.skype.NotifConnector lambda$connect$4
SEVERE: Error while reading packet
fr.delthas.skype.ParseException: Error message received:
911 2 CON 23

Authentication failed
at fr.delthas.skype.NotifConnector.readPacket(NotifConnector.java:484)
at fr.delthas.skype.NotifConnector.lambda$connect$4(NotifConnector.java:512)
at java.lang.Thread.run(Thread.java:745)

Mar 22, 2017 12:28:52 PM fr.delthas.skype.Skype error
SEVERE: Error thrown
fr.delthas.skype.ParseException: Error message received:
911 2 CON 23

Authentication failed
at fr.delthas.skype.NotifConnector.readPacket(NotifConnector.java:484)
at fr.delthas.skype.NotifConnector.lambda$connect$4(NotifConnector.java:512)
at java.lang.Thread.run(Thread.java:745)

Mar 22, 2017 12:28:52 PM fr.delthas.skype.Skype error
SEVERE: No error listener set!!!`

Error when using skype.connect();

An error occured while connecting...
fr.delthas.skype.ParseException: org.json.JSONException: A JSONArray text must start with '[' at 1 [character 2 line 1]
    at fr.delthas.skype.WebConnector.updateContacts(WebConnector.java:119)
    at fr.delthas.skype.WebConnector.start(WebConnector.java:38)
    at fr.delthas.skype.Skype.connect(Skype.java:90)
    at fr.delthas.skype.Skype.connect(Skype.java:66)
    at com.mrpowergamerbr.skykaty.SkyKatyApp.main(SkyKatyApp.java:19)
Caused by: org.json.JSONException: A JSONArray text must start with '[' at 1 [character 2 line 1]
    at org.json.JSONTokener.syntaxError(JSONTokener.java:433)
    at org.json.JSONArray.<init>(JSONArray.java:106)
    at org.json.JSONArray.<init>(JSONArray.java:145)
    at fr.delthas.skype.WebConnector.updateContacts(WebConnector.java:113)
    ... 4 more

java.net.SocketException: Software caused connection abort: socket write error

An error occured while connecting...
java.io.IOException: java.net.SocketException: Software caused connection abort: socket write error
    at fr.delthas.skype.Skype.connect(Skype.java:102)
    at fr.delthas.skype.Skype.connect(Skype.java:68)
    at com.mrpowergamerbr.test.Whatever.main(Whatever.java:12)
Caused by: java.net.SocketException: Software caused connection abort: socket write error
    at java.net.SocketOutputStream.socketWrite0(Native Method)
    at java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:109)
    at java.net.SocketOutputStream.write(SocketOutputStream.java:153)
    at sun.security.ssl.OutputRecord.writeBuffer(OutputRecord.java:431)
    at sun.security.ssl.OutputRecord.write(OutputRecord.java:417)
    at sun.security.ssl.SSLSocketImpl.writeRecordInternal(SSLSocketImpl.java:876)
    at sun.security.ssl.SSLSocketImpl.writeRecord(SSLSocketImpl.java:847)
    at sun.security.ssl.AppOutputStream.write(AppOutputStream.java:123)
    at sun.nio.cs.StreamEncoder.writeBytes(StreamEncoder.java:221)
    at sun.nio.cs.StreamEncoder.implWrite(StreamEncoder.java:282)
    at sun.nio.cs.StreamEncoder.write(StreamEncoder.java:125)
    at java.io.OutputStreamWriter.write(OutputStreamWriter.java:207)
    at java.io.BufferedWriter.flushBuffer(BufferedWriter.java:129)
    at java.io.BufferedWriter.flush(BufferedWriter.java:253)
    at fr.delthas.skype.NotifConnector.sendPacket(NotifConnector.java:515)

Same issue as #11, the only difference is that the moods are loaded but all contacts are shown as "OFFLINE"

Strange RAM usage

  • OS, Version, Architecture (e.g. Windows 8.1 x64): Linux mint 18.3 x64 / Ubuntu 16.04 x64
  • JRE Vendor, Version (e.g. Oracle JDK 8u151): openjdk 1.8.0_181

Expected behaviour

Running app should use less than 32mb RAM.

Actual behaviour

Running app eats about 400mb RAM.

Steps to reproduce the issue

Create new project with one Main.java class with following code:

package fr.delthas.skype;

public class Main {

	public static void main(String[] args) throws Exception {
		Skype skype = new Skype("username", "password");
		skype.connect();
		System.out.println("Done");
	}

}

Run project and see memory usage using system monitor.
For example, I cannot even run this app on my VDS because of Exception in thread "main" java.lang.OutOfMemoryError: Java heap space

Skype connect calls dependent on libraries installed on machine

  • OS, Version, Architecture : Ubuntu 18.04.1 LTS (Bionic Beaver)
  • JRE Vendor, Version : openjdk version "1.8.0_191"

Expected behaviour

Connecting the Skype object should work without a hitch.

Actual behaviour

Connecting works unpredictably. However, I've narrowed it down to some skype-related libraries installed on my local workstation. I've also read elsewhere that Skype delegates sending requests to some libraries installed on the OS you're running, but it's impossible to figure out which (source: https://www.programmableweb.com/news/skype-plans-to-shutdown-desktop-api-year-end/2013/07/15)

Steps to reproduce the issue

I can't reliably reproduce it across machines, however I was able to connect successfully on an Amazon Linux instance, after attempting to install the Skype package on there.
wget https://go.skype.com/skypeforlinux-64.rpm
sudo yum install skypeforlinux-64.rpm

Installation partially fails because of a missing package named "libsecret", but the necessary libraries to send are correctly installed (presumably) and subsequent attempts to connect are successful.

The biggest problem is that it used to work on my dev machine, I made a proof-of-concept using the library and everything worked correctly, then my Ubuntu had some auto-updates install and since then it's not working. Trying to find which libraries are used to connect is like searching for the proverbial needle. In a haystack. After it's been eaten by cows.

Also, it's working by default on another server we have, which is Ubuntu 16.04.3 LTS. For this particular server, I never installed any package to get it to work, so the necessary libraries are probably already bundled with 16.04.

Also not working on various MacBooks that my colleagues have, even though they have Skype running on their computers.

I've read other issues and they seem to be similar, but I feel none of them mentioned this detail, so perhaps it will help.

Version used: latest (1.0.23)
Code used: trivial, similar to the example.
Skype username: new account made a few weeks ago, ***@outlook.com (so I guess a Microsoft account)

Logs

Add debug logs (or link to them) if reporting a bug. For that call Skype.setDebug(path) at any time before calling skype.connect().
skype_log.log

Skype doesn't fetch pending contact requests

Hello,

Every instance of it that I've tried hasn't worked.

As well as a for each loop using skype.getcontactrequest() arraylist (which returned as empty even though it isn't).

Perhaps my approach has been wrong, would appreciate help on how to use this class.

Thanks

Get self Avatar

Code:
User skypeUser = skype.getSelf();
String url = skypeUser.getAvatarUrl();
System.out.println("Url = " + url);

Out:
Url = null

Adding the API into a java project

I am having trouble adding this API into my java project, do you have a detailed tutorial on how to add this API into a new java project? I am using eclipse by the way.

Only one day account available - unable to connect

Hi
I have an issue with using JavaSkype. When I create new account Skypebot works good. But after one - two days I am unable to use skype.connect() method. The code is stuck on this method and the only way to avoid it is to create a new account and use connect for a new account. I only used connect method and I didn't use disconnect method. It is possible if I will not use disconnect method my bot account will be blocked?

Regards,
Wojciech

Not able to connect to skype on a linux server

[English]
I can connect to skype with windows but with linux it stay at connecting. There is no error in the logs and this is what it's written on the Skype.setDebug : https://pastebin.com/gYpCRHxe (It's the same code on linux and windows)

[Français]
Je peux me connecter sur skype avec windows mais avec linux ça reste a en connection. Il n'y a pas d'erreur en log et voici ce qui est écrit dans le Skype.setDebug : https://pastebin.com/gYpCRHxe (C'est le même code sur linux et windows)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.