Want a better Minecraft server? Read about SpigotMC here!
Separate names with a comma.
Discussion in 'Server & Community Management' started by jojodmo, Sep 23, 2014.
It doesn't have ----BEGIN PUBLIC KEY----- in it Thanks for your help
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.
Can you PM me your method of accessing the API?
Ok, thanks for you help anyways!
I'll just put it here, it may help other people:
$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);
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
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
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?
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
echo sendVotifierPacket($_POST["key"], $_POST["ip"], $_POST["port"], $_POST["name"]);
Weird... Could it be something in the sendVotifierPacket() method? I'm honestly clueless at this point
Try it now
Now the format is:
:O It works!
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)
I had written a server list website awhile back. I could not figure out if anyone would buy or use it.
Thanks to @samczsun, mine-list.net now supports Votifier!
I just fixed one small bug with votifier key verification, everything with votifier should work perfectly now
To get some more attention to the list
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...