From 372b526ad0d7b68e65451d12bcc5dd67b0f85de1 Mon Sep 17 00:00:00 2001 From: Garfield69 Date: Fri, 10 Feb 2023 06:21:15 +1300 Subject: [PATCH] pterclub: use cookie. resolves #13995 --- src/Jackett.Common/Definitions/pterclub.yml | 35 +++++---------------- 1 file changed, 7 insertions(+), 28 deletions(-) diff --git a/src/Jackett.Common/Definitions/pterclub.yml b/src/Jackett.Common/Definitions/pterclub.yml index b0c0df9dd..50c61b618 100644 --- a/src/Jackett.Common/Definitions/pterclub.yml +++ b/src/Jackett.Common/Definitions/pterclub.yml @@ -33,19 +33,13 @@ caps: book-search: [q] settings: - - name: username + - name: cookie type: text - label: Username - - name: password - type: password - label: Password - - name: 2facode - type: text - label: 2FA code - - name: info_2fa + label: Cookie + - name: info type: info - label: "About 2FA code" - default: "Only fill in the 2FA code box if you have enabled 2FA on the PTerClub Web Site. Otherwise just leave it empty." + label: How to get the Cookie + default: "
  1. Login to this tracker with your browser
  2. Open the DevTools panel by pressing F12
  3. Select the Network tab
  4. Click on the Doc button (Chrome Browser) or HTML button (FireFox)
  5. Refresh the page by pressing F5
  6. Click on the first row entry
  7. Select the Headers tab on the Right panel
  8. Find 'cookie:' in the Request Headers section
  9. Select and Copy the whole cookie string (everything after 'cookie: ') and Paste here.
" - name: freeleech type: checkbox label: Search freeleech only @@ -72,26 +66,11 @@ settings: default: For best results, change the Torrents per page: setting to 100 on your account profile. login: - path: login.php - method: form - form: form[action="takelogin.php"] - captcha: - type: image - selector: img[alt="CAPTCHA"] - input: imagestring + method: cookie inputs: - username: "{{ .Config.username }}" - password: "{{ .Config.password }}" - 2fa_secret: "{{ .Config.2facode }}" - logout: "" - securelogin: "" - ssl: yes - trackerssl: yes - error: - - selector: td.embedded:has(h2:contains("失败")) + cookie: "{{ .Config.cookie }}" test: path: index.php - selector: a[data-url="logout.php"] search: paths: