---
id: insanetracker
name: Insane Tracker
description: "Insane Tracker is a HUNGARIAN Private Torrent Tracker for 0DAY / GENERAL"
language: hu-HU
type: private
encoding: UTF-8
links:
  - https://newinsane.info/

caps:
  categorymappings:
    - {id: 8, cat: TV/SD, desc: "Sorozat/Hun"}
    - {id: 40, cat: TV/HD, desc: "Sorozat/Hun/HD"}
    - {id: 47, cat: TV/UHD, desc: "Sorozat/Hun/UHD"}
    - {id: 7, cat: TV/SD, desc: "Sorozat/Eng"}
    - {id: 39, cat: TV/HD, desc: "Sorozat/Eng/HD"}
    - {id: 46, cat: TV/UHD, desc: "Sorozat/Eng/UHD"}
    - {id: 41, cat: Movies/SD, desc: "Film/Hun/SD"}
    - {id: 27, cat: Movies/HD, desc: "Film/Hun/HD"}
    - {id: 44, cat: Movies/UHD, desc: "Film/Hun/UHD"}
    - {id: 15, cat: Movies/DVD, desc: "Film/Hun/DVD-R"}
    - {id: 42, cat: Movies/SD, desc: "Film/Eng/SD"}
    - {id: 25, cat: Movies/HD, desc: "Film/Eng/HD"}
    - {id: 45, cat: Movies/UHD, desc: "Film/Eng/UHD"}
    - {id: 14, cat: Movies/DVD, desc: "Film/Eng/DVD-R"}
    - {id: 2, cat: Books, desc: "eBook/Hun"}
    - {id: 1, cat: Books, desc: "eBook/Eng"}
    - {id: 38, cat: Audio/Audiobook, desc: "Hangoskönyv"}
    - {id: 19, cat: Audio/MP3, desc: "Zene/Hun"}
    - {id: 37, cat: Audio/Lossless, desc: "Lossless/Hun"}
    - {id: 18, cat: Audio/MP3, desc: "Zene/Eng"}
    - {id: 26, cat: Audio/Lossless, desc: "Lossless/Eng"}
    - {id: 4, cat: PC/ISO, desc: "Program/ISO"}
    - {id: 3, cat: PC/0day, desc: "Program/Egyéb"}
    - {id: 11, cat: PC/Games, desc: "Játék/Rip"}
    - {id: 9, cat: PC/Games, desc: "Játék/ISO"}
    - {id: 43, cat: Console, desc: "Játék/Konzol"}
    - {id: 13, cat: PC/Mobile-Other, desc: "Mobil"}
    - {id: 21, cat: XXX, desc: "XXX"}
    - {id: 28, cat: XXX/ImageSet, desc: "XXX Képek"}
    - {id: 29, cat: Other, desc: "Képek"}


  modes:
    search: [q]
    tv-search: [q, season, ep, imdbid]
    movie-search: [q, imdbid]
    music-search: [q]
    book-search: [q]

settings:
  - name: username
    type: text
    label: Username
  - name: password
    type: password
    label: Password
  - name: freeleech
    type: checkbox
    label: Search freeleech only
    default: false
  - name: sort
    type: select
    label: Sort requested from site
    default: 4
    options:
      4: created
      7: seeders
      5: size
      1: title
  - name: type
    type: select
    label: Order requested from site
    default: desc
    options:
      desc: desc
      asc: asc

login:
  path: login.php
  method: post
  inputs:
    username: "{{ .Config.username }}"
    password: "{{ .Config.password }}"
    notsecure: ""
  error:
    - selector: div.login_error_content_text
  test:
    path: browse.php

search:
  paths:
    # https://newinsane.info/browse.php?search=&nohnr=1&doubleup=&incldead=1&ggen=0&sty=0&all=0
    - path: browse.php
  inputs:
    $raw: "{{ range .Categories }}c{{.}}=1&{{end}}"
    search: "{{ if .Query.IMDBID }}{{ .Query.IMDBID }}{{ else }}{{ .Keywords }}{{ end }}"
    # 0 active, 1 both, 2 dead
    incldead: 1
    nohnr: "{{ if .Config.freeleech }}1{{ else }}{{ end }}"
    sort: "{{ .Config.sort }}"
    type: "{{ .Config.type }}"

  rows:
    selector: table.torrenttable > tbody > tr:has(td.torrentmain)

  fields:
    title:
      selector: td.torrentmain > a.torrentname
      attribute: title
    category:
      selector: a[href^="browse.php?cat="]
      attribute: href
      filters:
        - name: querystring
          args: cat
    details:
      selector: td.torrentmain > a.torrentname
      attribute: href
    download:
      selector: a[href*="/download.php/"]
      attribute: href
    imdbid:
      selector: a[title="IMDb link"]
      attribute: href
    poster:
      selector: img[alt="offer"], a.cover
      attribute: src
    files:
      selector: div.files > a.button.small
    size:
      selector: td.center.size
    seeders:
      selector: td.center.data > a:first-child
    leechers:
      selector: td.center.data > a:nth-child(2)
    grabs:
      selector: td.center.data
      remove: div.uploader, div.moderation, a.leftborder
    date:
      selector: td.center.date
      filters:
        - name: append
          args: " +01:00" # CET
        - name: dateparse
          args: "2006-01-0215:04 -07:00"
    downloadvolumefactor:
      case:
        a[href^="?nohnr=1"]: 0
        "*": 1
    uploadvolumefactor:
      case:
        a[href^="?doubleup=four"]: 4
        a[href^="?doubleup=three"]: 3
        a[href^="?doubleup=two"]: 2
        "*": 1
    description:
      selector: div.contenttext
      remove: div.contenttitle
    minimumratio:
      text: 1.0
    minimumseedtime:
      # 1 day (as seconds = 24 x 60 x 60)
      text: 86400
# custom v2.0b
