Jump to content

Đoàn Minh Tâm

Members
  • Số lượng nội dung

    53
  • Đã tham gia

  • Lần ghé thăm cuối

  • Days Won

    2

Cộng đồng

13 Good

1 Người theo dõi

About Đoàn Minh Tâm

  • Sinh nhật 15/04/1989

Khách vừa ghé thăm

1.974 xem hồ sơ
  1. Shopee thay đổi API 1 số thành phần lên V4, cẩn thận khi check nha
  2. ok, được chứ bạn. Thật ra là mình chỉ cần debug, tìm đúng và fill thông tin đúng như đoạn js nó mã hóa. code tham khảo đã check tất cả link đều ok <!DOCTYPE html> <html lang="en" xmlns="http://www.w3.org/1999/xhtml"> <head> <meta charset="utf-8" /> <title></title> <script src="https://code.jquery.com/jquery-3.6.0.js"></script> <script> function n(e) { var t = { hash: function (e, n) { (n = void 0 === n || n) && (e = r.encode(e)); for (var a = [1116352408, 1899447441, 3049323471, 3921009573, 961987163, 1508970993, 2453635748, 2870763221, 3624381080, 310598401, 607225278, 1426881987, 1925078388, 2162078206, 2614888103, 3248222580, 3835390401, 4022224774, 264347078, 604807628, 770255983, 1249150122, 1555081692, 1996064986, 2554220882, 2821834349, 2952996808, 3210313671, 3336571891, 3584528711, 113926993, 338241895, 666307205, 773529912, 1294757372, 1396182291, 1695183700, 1986661051, 2177026350, 2456956037, 2730485921, 2820302411, 3259730800, 3345764771, 3516065817, 3600352804, 4094571909, 275423344, 430227734, 506948616, 659060556, 883997877, 958139571, 1322822218, 1537002063, 1747873779, 1955562222, 2024104815, 2227730452, 2361852424, 2428436474, 2756734187, 3204031479, 3329325298], o = [1779033703, 3144134277, 1013904242, 2773480762, 1359893119, 2600822924, 528734635, 1541459225], l = (e += String.fromCharCode(128)).length / 4 + 2, i = Math.ceil(l / 16), c = new Array(i), u = 0; u < i; u++) { c[u] = new Array(16); for (var s = 0; s < 16; s++) c[u][s] = e.charCodeAt(64 * u + 4 * s) << 24 | e.charCodeAt(64 * u + 4 * s + 1) << 16 | e.charCodeAt(64 * u + 4 * s + 2) << 8 | e.charCodeAt(64 * u + 4 * s + 3) } c[i - 1][14] = 8 * (e.length - 1) / Math.pow(2, 32), c[i - 1][14] = Math.floor(c[i - 1][14]), c[i - 1][15] = 8 * (e.length - 1) & 4294967295; var m, p, d, f, h, y, g, v, b = new Array(64); for (u = 0; u < i; u++) { for (var E = 0; E < 16; E++) b[E] = c[u][E]; for (E = 16; E < 64; E++) b[E] = t.sigma1(b[E - 2]) + b[E - 7] + t.sigma0(b[E - 15]) + b[E - 16] & 4294967295; m = o[0], p = o[1], d = o[2], f = o[3], h = o[4], y = o[5], g = o[6], v = o[7]; for (E = 0; E < 64; E++) { var N = v + t.Sigma1(h) + t.Ch(h, y, g) + a[E] + b[E] , S = t.Sigma0(m) + t.Maj(m, p, d); v = g, g = y, y = h, h = f + N & 4294967295, f = d, d = p, p = m, m = N + S & 4294967295 } o[0] = o[0] + m & 4294967295, o[1] = o[1] + p & 4294967295, o[2] = o[2] + d & 4294967295, o[3] = o[3] + f & 4294967295, o[4] = o[4] + h & 4294967295, o[5] = o[5] + y & 4294967295, o[6] = o[6] + g & 4294967295, o[7] = o[7] + v & 4294967295 } return t.toHexStr(o[0]) + t.toHexStr(o[1]) + t.toHexStr(o[2]) + t.toHexStr(o[3]) + t.toHexStr(o[4]) + t.toHexStr(o[5]) + t.toHexStr(o[6]) + t.toHexStr(o[7]) }, ROTR: function (e, t) { return t >>> e | t << 32 - e }, Sigma0: function (e) { return t.ROTR(2, e) ^ t.ROTR(13, e) ^ t.ROTR(22, e) }, Sigma1: function (e) { return t.ROTR(6, e) ^ t.ROTR(11, e) ^ t.ROTR(25, e) }, sigma0: function (e) { return t.ROTR(7, e) ^ t.ROTR(18, e) ^ e >>> 3 }, sigma1: function (e) { return t.ROTR(17, e) ^ t.ROTR(19, e) ^ e >>> 10 }, Ch: function (e, t, r) { return e & t ^ ~e & r }, Maj: function (e, t, r) { return e & t ^ e & r ^ t & r }, toHexStr: function (e) { for (var t = "", r = 7; r >= 0; r--) t += (e >>> 4 * r & 15).toString(16); return t } } , r = { encode: function (e) { var t = e.replace(/[\u0080-\u07ff]/g, (function (e) { var t = e.charCodeAt(0); return String.fromCharCode(192 | t >> 6, 128 | 63 & t) } )); return t = t.replace(/[\u0800-\uffff]/g, (function (e) { var t = e.charCodeAt(0); return String.fromCharCode(224 | t >> 12, 128 | t >> 6 & 63, 128 | 63 & t) } )) }, decode: function (e) { var t = e.replace(/[\u00e0-\u00ef][\u0080-\u00bf][\u0080-\u00bf]/g, (function (e) { var t = (15 & e.charCodeAt(0)) << 12 | (63 & e.charCodeAt(1)) << 6 | 63 & e.charCodeAt(2); return String.fromCharCode(t) } )); return t = t.replace(/[\u00c0-\u00df][\u0080-\u00bf]/g, (function (e) { var t = (31 & e.charCodeAt(0)) << 6 | 63 & e.charCodeAt(1); return String.fromCharCode(t) } )) } }; return t.hash(e) } $(document).ready(function () { var str_url = window.location.href; if (str_url.indexOf('?')) { console.log(str_url.split('?')[1]); var truyenbien = str_url.split('?')[1]; var ktqua = n(truyenbien); $('#bien_s').html(ktqua); } }); function showmahoa() { return n('339095508askt6b9l8id=621459&sku=00746913'); } //console.log(n('339095508askt6b9l8id=621459&sku=00746913')); </script> </head> <body> <div id="bien_s"></div> </body> </html>
  3. ok, thanks bạn , mình đã tìm ra và đã xử lý được thông tin đó rồi
  4. mình cũng tìm nát cái js của nó, mà nó mã hóa khó giải kinh khủng.
  5. Chào mọi người. Mọi người có ai đã lấy được API sản phẩm của FptShop chưa. link demo: link web: https://fptshop.com.vn/dien-thoai/samsung-galaxy-a03s <br/> link api : <br/> https://fptshop.com.vn/apiFPTShop/Product/GetProductDetail?name=samsung-galaxy-a03s&url=https:%2F%2Ffptshop.com.vn%2Fdien-thoai%2Fsamsung-galaxy-a03s&s=f941d72a938ddf84fe2e8092fe3f0e2c2fb2371d9957b8557c38f75161e43e02 chổ s=f941d72a938ddf84fe2e8092fe3f0e2c2fb2371d9957b8557c38f75161e43e02 Mình không biết nó là cái base mã hóa gì. Mọi người ai biết chỉ giúp hoặc cho keyword mình tìm nhé Cám ơn mọi người.
  6. Lazada sử dụng cũng khá dễ, ngắn gọn vài dòng code là ra kết quả. Demo: Down DLL : LazopSdk , chi tiết google public string GetProducts(string url, string appkey, string appSecret, string access_tokens, string status_product, int offset, int limit, int options) { try { ILazopClient client = new LazopClient(url, appkey, appSecret); LazopRequest request = new LazopRequest(); request.SetApiName("/products/get"); request.SetHttpMethod("GET"); request.AddApiParameter("filter", status_product); request.AddApiParameter("offset", offset.ToString()); request.AddApiParameter("limit", limit.ToString()); request.AddApiParameter("options", options.ToString()); LazopResponse response = client.Execute(request, access_tokens); return response.Body; } catch (Exception ex) { return ex.Message; } } shopee cũng có API riêng, mà khi đăng ký hơi phức tạp xíu, khi đăng ký dc rồi. Sử dụng cho các tính năng rất ok, mà điều kiện cũng khá chua để dc Live App shopee .
  7. Lazada có API Lazada riêng, đăng ký ứng dụng Lazada là xài dc đủ tính năng, có cái token Lazada có 1 tuần, phải dùng task scheduler gần hết hạn rồi resefh thôi
  8. code đầy đủ dành cho bạn nào muốn lấy thông tin. ở đây mình dùng WebClient, còn bạn nào dùng HttpRequest thì thay đổi chút. public string GetItemShopee(string urlAddress) { string KQ_Item =""; using (WebClient webClient = new WebClient()) { string Param = urlAddress.Split('?')[1]; //"itemid=5672688695&shopid=53339108"; string Param_Md5 = CreateMD5(Param).ToLower(); string text_Hash = "55b03" + Param_Md5 + "55b03"; string if_none_match_ = CreateMD5(text_Hash).ToLower(); WebHeaderCollection headers = new WebHeaderCollection(); headers[HttpRequestHeader.UserAgent] = RandomUserAgent.RandomUa.RandomUserAgent; headers["if-none-match"] = if_none_match_; webClient.Headers = headers; webClient.Encoding = Encoding.UTF8; // webClient.DownloadProgressChanged += new DownloadProgressChangedEventHandler((sender, e) => ProgressChanged_ItemShopee(sender, e, rowHandle, sw)); //webClient.DownloadStringCompleted += new DownloadStringCompletedEventHandler((sender, e) => DownloadStringCompleted_ItemShopee(sender, e, rowHandle, sw)); Uri URL = new Uri(urlAddress); try { // webClient.DownloadStringAsync(URL); KQ_Item = webClient.DownloadString(URL); } catch (Exception ex) { lbl_chitiet.Caption = ex.Message; } } return KQ_Item; } public static string CreateMD5(string input) { // Use input string to calculate MD5 hash using (System.Security.Cryptography.MD5 md5 = System.Security.Cryptography.MD5.Create()) { byte[] inputBytes = System.Text.Encoding.ASCII.GetBytes(input); byte[] hashBytes = md5.ComputeHash(inputBytes); // Convert the byte array to hexadecimal string StringBuilder sb = new StringBuilder(); for (int i = 0; i < hashBytes.Length; i++) { sb.Append(hashBytes[i].ToString("X2")); } return sb.ToString(); } } ----------------------------------- Ghép bài -----------------------------------
  9. Chào mọi người. Mọi người ai biết Request pagesource html trang Lazada hàng loạt mà không bị check point. Vui lòng hướng dẫn giúp mình. Mình dùng Webclient để request sync page. Code demo: string url = "https://www.lazada.vn/products/dien-thoai-samsung-galaxy-s20-plus-128gb8gb-hang-chinh-hang-moi-100-nguyen-seal-bao-hanh-12-thang-i498830724-s974814141.html?spm=a2o4n.searchlist.list.8.706b3a0fcsJ4Oe&search=1"; Uri address = new Uri(url); WebClient webClient = new WebClient(); webClient.Headers[HttpRequestHeader.ContentType] = "application/x-www-form-urlencoded"; //< get Website > //*here: download as string webClient.DownloadStringCompleted += WebClient_DownloadStringCompleted; webClient.DownloadStringAsync(address); private void WebClient_DownloadStringCompleted(object sender, DownloadStringCompletedEventArgs e) { //-------------------< WebClient_DownloadStringCompleted() >------------------- //< check > if (e.Error != null) { var output = e.Error.Message; } //</ check > else if (e.Result != null) { richTextBox1.Invoke(new MethodInvoker(delegate () { richTextBox1.Text = e.Result; })); //var document = new HtmlDocument(); //document.LoadHtml(e.Result); //var node = document.DocumentNode.SelectSingleNode("//span[@id=\"result_box\"]"); //var output = node != null ? node.InnerText : e.Error.Message; } //-------------------</ WebClient_DownloadStringCompleted() >------------------- }
  10. quá hay luôn Ad , để không bị treo Pc thì mình dùng cấu hình Pc như thế nào để có thể 1PC điều khiển khoảng > 20 máy vậy Ad. Nếu mình có 5 Pc với mỗi PC là 20 máy, thì làm sao để liên kết các PC để điều khiển chung dc. Ad có thông tin vui lòng chỉ giúp mình
  11. code chạy bth, do lỗi từ shopee , Admin close lại giúp mình.
×
×
  • Create New...