#19 JWBF & HTTPS PROTOCOL

devel
closed
Loki
None
5
2013-04-05
2010-10-08
No

Hi, I have not log in to wiki page through protocol https.

MediaWikiBot b = new MediaWikiBot("https://codepedia.indra.es/");
b.httpLogin("***","***");

I have the next error:

Exception in thread "main" ( No Module for net.sourceforge.jwbf.mediawiki.bots.MediaWikiBot-Version Unknown )
net.sourceforge.jwbf.core.actions.util.ActionException: java.lang.RuntimeException: Server returned HTTP response code: 503 for URL: http://www.w3.org/TR/html4/strict.dtd

JWBF and https protocol is possible? Please explain me

Thanks

Diego Sánchez

Discussion

  • Jacques de Molay

    • assigned_to: nobody --> eldurloki
    • priority: 5 --> 9
     
  • Jacques de Molay

    The correct sentence is b.login("***","***"); not b.httpLogin("***","***");

     
  • Jacques de Molay

    Sorry, the correct sentence is b.login("***","***"); not b.httpLogin("***","***");

    Thanks

     
  • Loki

    Loki - 2010-10-08
    • priority: 9 --> 5
     
  • Jacques de Molay

    Hello Loki, this code don not work.

       HttpClient httpClient = getSSLFakeHttpClient\(\);
    

    URL u = new URL("https://ourwiki.url.es/");
    HttpActionClient aClient = new HttpActionClient(httpClient, u);

       MediaWikiBot bot = new MediaWikiBot\(u\);
       bot.setConnection\(aClient\);
       bot.login\("\*\*\*\*\*", "\*\*\*\*\*"\);
       /\*Exception is thrown\*/
       if \(\!bot.isLoggedIn\(\)\)\{
           System.out.println\("ERROR, NO LOGIN\!\!"\);
       \}
    

    I have the same error:

    Exception in thread "main" ( No Module for net.sourceforge.jwbf.mediawiki.bots.MediaWikiBot-Version Unknown )
    net.sourceforge.jwbf.core.actions.util.ActionException: java.lang.RuntimeException: Server returned HTTP response code: 503 for URL: http://www.w3.org/TR/html4/strict.dtd

    Thanks

     
  • Jacques de Molay

    • priority: 5 --> 9
     
  • Jacques de Molay

    Hi Loki,

    I have to access a wiki page which is under a server of the company I work for. This way, in order to access this wiki, I need to login into this server
    first and then the wiki automatically makes the login through the Mediawiki plugin Automatic REMOTE USER.

    This extension allows integration with the web server's built-in authentication system via the REMOTE_USER environment variable,
    which is set through HTTP-Auth, LDAP, CAS, PAM, and other authentication systems.

    The extension automatically logs-i users using the value of the REMOTE_USER environment variable as the MediaWiki username.
    If an account of that name does not already exist, one is created.

    The code showed at comment number 4 do not work. Can you help me?:

    HttpClient httpClient = getSSLFakeHttpClient();
    URL u = new URL("https://ourwiki.url.es/");
    HttpActionClient aClient = new HttpActionClient(httpClient, u);

    MediaWikiBot bot = new MediaWikiBot(u);
    bot.setConnection(aClient);
    bot.login("*****", "*****");
    /*Exception is thrown*/
    if (!bot.isLoggedIn()){
    System.out.println("ERROR, NO LOGIN!!");
    }

    and the error is :

    Exception in thread "main" ( No Module for
    net.sourceforge.jwbf.mediawiki.bots.MediaWikiBot-Version Unknown )
    net.sourceforge.jwbf.core.actions.util.ActionException:
    java.lang.RuntimeException: Server returned HTTP response code: 503 for
    URL: http://www.w3.org/TR/html4/strict.dtd

    Thanks

     
  • Loki

    Loki - 2010-10-13
    • priority: 9 --> 5
     
  • Loki

    Loki - 2013-04-05
    • status: open --> closed
    • milestone: --> devel
     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks