New Server List

Discussion in 'Server & Community Management' started by jojodmo, Sep 23, 2014.

  1. It doesn't have ----BEGIN PUBLIC KEY----- in it :p Thanks for your help :)
     
  2. I used this code back in 1.3 so it may be outdated. I would suggest using some kind of public api and not a private one. Sorry about that.
     
  3. samczsun

    Supporter

    @jojodmo

    Can you PM me your method of accessing the API?
     
  4. Ok, thanks for you help anyways! :)
     
  5. I'll just put it here, it may help other people:

    Code (PHP):
    $port = 8192;
    $ip = "play.mine4life.net";
    $key = "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAmoawwSFuNjPmqDo4OphYCQCG80+t+jmH7LPMAn+2Rb93lVKD6YQ5QivdFIc8XpvjbwPyYFYmXtBnkFgZsmvBUejKgV207L//6yuWqiB85L4Qz8dYpGTgyaeR9n4Da23hfCkwqlg/mSdEXyQLSV/S0fqrvIIlC6VGTUfPS9J4xqx9auTA9nSTZb1ihHFdalI6jj9czwozTQ+MF74lSOad6nwCRkSKxy7lMTZ9LfSzQsW1kjbrY8dGmPidH1jCYV9kZlsqKowTxuvUSzDX5dDYwRnOvXdD8oyhEaXQvYIriu+Uv7ILCOaPKmI8WnJF2xw8ZXS53+8gq8qwPCGpbdglwwIDAQAB";
                   
    $url = "http://zk.ms/votifier.php";
    $vars = "key=$key&ip=$ip&port=$port&name=$name";

    $ch = curl_init($url);
    curl_setopt($ch, CURLOPT_POST, 1);
    curl_setopt($ch, CURLOPT_POSTFIELDS, $vars);
    curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
    curl_setopt($ch, CURLOPT_HEADER, 0);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
                 
    $response = curl_exec($ch);
    echo $response;
     
     
  6. samczsun

    Supporter

    @jojodmo

    And the response is 1?

    Can you try with a Chrome extension like Postman and see if that works? If it does, curl is doing something wrong
     
  7. The response is '1', and a vote is sent to the server, but once it arrives the RSA dexryption fails with the error I post above
     
  8. samczsun

    Supporter

    @jojodmo

    Interesting. I tested it with my server that I just popped votifier on, and it worked fine.

    Did you check with Postman? Maybe you missed a few characters on your pubkey?
     
  9. I checked with minestatus, and it seemed to work... Maybe there's a mispelling of the POST variable for the public key on your side? It could also be an error with how I'm sending the variables or a misspelling of the POST variables on my side... Thanks :)
     
  10. samczsun

    Supporter

    @jojodmo

    Code (Text):

    echo sendVotifierPacket($_POST["key"], $_POST["ip"], $_POST["port"], $_POST["name"]);
     
     
  11. Weird... Could it be something in the sendVotifierPacket() method? I'm honestly clueless at this point
     
  12. samczsun

    Supporter

    @jojodmo

    Try it now :D

    EDIT:
    Now the format is:

    list=yourListName&key=yourPubKey&ip=serverIp&port=serverPort&name=username
     
  13. :O It works! :D

    Thank you so much! I'll add it to the rest of the site now. Are there any ads that you would like me to put on the server list for you? (preferably a 468x60 non-intrusive banner)
     
    • Like Like x 1
  14. I had written a server list website awhile back. I could not figure out if anyone would buy or use it.
     
  15. Thanks to @samczsun, mine-list.net now supports Votifier!
     
  16. I just fixed one small bug with votifier key verification, everything with votifier should work perfectly now :)
     
  17. For what?
     
  18. To get some more attention to the list
     
    • Like Like x 1
    • Funny Funny x 1
  19. Does anyone have some suggestions on how to get the list a little more popular? I'm pretty sure if servers could get their players voting on the website, that would work...