Skip to content

Instantly share code, notes, and snippets.

@yoonsy
Last active January 16, 2018 00:53
Show Gist options
  • Save yoonsy/8539991018406d18c60c807248ff5f8a to your computer and use it in GitHub Desktop.
Save yoonsy/8539991018406d18c60c807248ff5f8a to your computer and use it in GitHub Desktop.
2016 추석 기차 예매했던 스크립트
var yoonsyFunc = function(date){
s = console.log;
E = function(a) {
a = "undefined" == typeof a ? 1 : a;
var c = "/bt/bt_info.cache?" + date.getTime(),
d = { logintimeout: "", key: "" };
return $.ajax({
url: c,
async: !1,
dataType: "json",
error: function(a, b, c) {
s("_getServerState"),
s(":e.statusText=" + a.statusText),
s(":e.responseText=" + a.responseText),
s(":e.status=" + a.status), s(":status=" + b),
s(":thrownError=" + c),
d = { logintimeout: "e", key: "" }
},
success: function(c, e) {
console.log('success!!', c,e);
d = c
}
}),
d;
}
u = function(a, b, c, d) {
d = d || "post";
var e = document.createElement("form");
e.setAttribute("method", d),
e.setAttribute("action", a),
e.setAttribute("target", c);
for (var f in b) {
var g = document.createElement("input");
g.setAttribute("type", "hidden"),
g.setAttribute("name", f),
g.setAttribute("value", b[f]),
e.appendChild(g)
}
return document.body.appendChild(e), e.submit(), !1
}
u("/korail/ebizbt/w_login.do", { key: E().key }, "_parent");
};
// 예매 시작하고 나서 대기 인원 상관없이 아무때나 이걸로 접속 됨
// 그 날 아침 6시에 예매 시작한다고 가정
var startDateTime = new Date();
startDateTime.setHours(6);
startDateTime.setMinutes(0);
startDateTime.setSeconds(0);
yoonsyFunc(startDateTime);
@yoonsy
Copy link
Author

yoonsy commented Aug 28, 2017

북마크 주소란에

javascript:(function(){document.body.appendChild(document.createElement('script')).src='http://yourjavascript.com/25181824217/korail.js';})();

요거 넣으면 됨

@yoonsy
Copy link
Author

yoonsy commented Aug 28, 2017

막힘 ㅜㅋ

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment