id
int64
0
458k
file_name
stringlengths
4
119
file_path
stringlengths
14
227
content
stringlengths
24
9.96M
size
int64
24
9.96M
language
stringclasses
1 value
extension
stringclasses
14 values
total_lines
int64
1
219k
avg_line_length
float64
2.52
4.63M
max_line_length
int64
5
9.91M
alphanum_fraction
float64
0
1
repo_name
stringlengths
7
101
repo_stars
int64
100
139k
repo_forks
int64
0
26.4k
repo_open_issues
int64
0
2.27k
repo_license
stringclasses
12 values
repo_extraction_date
stringclasses
433 values
16,200
search.py
cve-search_cve-search/bin/search.py
#!/usr/bin/env python3 # # search is the search component of cve-search querying the MongoDB database. # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2012 Wim Remes # Copyright (c) 2012-2018 Alexandre Dulaunoy - a@foo.be # Copyright (c) 2015-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com import argparse import csv import json import os import re import sys from datetime import datetime, timedelta from urllib.parse import urlparse from bson import json_util from dicttoxml import dicttoxml runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) from lib.DatabaseLayer import cvesForCPE, getCVEs, getFreeText, getCVEIDs, searchCVE from lib.CVEs import CveHandler from lib.cpe_conversion import split_cpe_name # init control variables csvOutput = 0 htmlOutput = 0 jsonOutput = 0 xmlOutput = 0 last_ndays_published = 0 last_ndays_modified = 0 nlimit = 0 # init various variables :-) vSearch = "" vOutput = "" vFreeSearch = "" summary_text = "" # parse command-line arguments argParser = argparse.ArgumentParser( description="Search for vulnerabilities in the National Vulnerability DB. Data from http://nvd.nist.org." ) argParser.add_argument( "-p", type=str, nargs="+", help="P = search one or more products, e.g. o:microsoft:windows_7 or o:cisco:ios:12.1 or o:microsoft:windows_7 " "o:cisco:ios:12.1. Add --only-if-vulnerable if only vulnerabilities that directly affect the product are " "wanted.", ) argParser.add_argument( "--only-if-vulnerable", dest="vulnProdSearch", default=False, action="store_true", help='With this option, "-p" will only return vulnerabilities directly assigned to the product. I.e. it will not ' 'consider "windows_7" if it is only mentioned as affected OS in an adobe:reader vulnerability. ', ) argParser.add_argument( "--strict_vendor_product", dest="strict_vendor_product", default=False, action="store_true", help='With this option, a strict vendor product search is executed. The values in "-p" should be formatted as ' "vendor:product, e.g. microsoft:windows_7", ) argParser.add_argument( "--lax", default=False, action="store_true", help="Strict search for software version is disabled. Likely gives false positives for earlier versions that " "were not yet vulnerable. Note that version comparison for non-numeric values is done with simplifications.", ) argParser.add_argument( "-f", type=str, help="F = free text search in vulnerability summary" ) argParser.add_argument("-c", action="append", help="search one or more CVE-ID") argParser.add_argument( "-o", type=str, help="O = output format [csv|html|json|xml|cveid]" ) argParser.add_argument("-l", action="store_true", help="sort in descending mode") argParser.add_argument( "-n", action="store_true", help="lookup complete cpe (Common Platform Enumeration) name for vulnerable configuration", ) argParser.add_argument( "-r", action="store_true", help="lookup ranking of vulnerable configuration" ) argParser.add_argument( "-a", default=False, action="store_true", help="Lookup CAPEC for related CWE weaknesses", ) argParser.add_argument("-v", type=str, help="vendor name to lookup in reference URLs") argParser.add_argument("-s", type=str, help="search in summary text") argParser.add_argument("-t", type=int, help="search in last n day (published)") argParser.add_argument("-T", type=int, help="search in last n day (modified)") argParser.add_argument( "-i", default=False, type=int, help="Limit output to n elements (default: unlimited)", ) argParser.add_argument( "-q", type=str, nargs="?", const="removed", help="Removed. Was used to search pip requirements file for CVEs.", ) args = argParser.parse_args() vSearch = args.p relaxSearch = args.lax strict_vendor_product = args.strict_vendor_product vulnerableProductSearch = args.vulnProdSearch cveSearch = [x.upper() for x in args.c] if args.c else None vOutput = args.o vFreeSearch = args.f sLatest = args.l namelookup = args.n rankinglookup = args.r capeclookup = args.a last_ndays_published = args.t last_ndays_modified = args.T summary_text = args.s nlimit = args.i cves = CveHandler( rankinglookup=rankinglookup, namelookup=namelookup, capeclookup=capeclookup ) def print_job(item): if csvOutput: printCVE_csv(item) elif htmlOutput: printCVE_html(item) # bson straight from the MongoDB db - converted to JSON default # representation elif jsonOutput: printCVE_json(item) elif xmlOutput: printCVE_xml(item) elif cveidOutput: printCVE_id(item) else: printCVE_human(item) def search_product(prod): if strict_vendor_product: search = split_cpe_name(prod) search = (search[0], search[1]) ret = cvesForCPE( search, lax=relaxSearch, vulnProdSearch=vulnerableProductSearch, strict_vendor_product=True, ) else: ret = cvesForCPE(prod, lax=relaxSearch, vulnProdSearch=vulnerableProductSearch) if "notices" in ret: for notice in ret["notices"]: print(f"{notice}") print() # Empty line to separate the notices from the results. for item in ret["results"]: if not last_ndays_published and not last_ndays_modified: print_job(item) else: if last_ndays_published: date_published_n_days_ago = datetime.now() - timedelta( days=last_ndays_published ) if item["published"] > date_published_n_days_ago: print_job(item) continue # Do not show the item twice if both -t and -T are used. if last_ndays_modified: date_modified_n_days_ago = datetime.now() - timedelta( days=last_ndays_modified ) if item["modified"] > date_modified_n_days_ago: print_job(item) def vuln_config(entry): if not namelookup: return entry else: return cves.getcpe(cpeid=entry) def is_number(s): try: ret = float(s) return ret except ValueError: return False if args.q: print( "Support for -q (search pip requirements file for CVEs) has been removed", file=sys.stderr, ) sys.exit(1) # define which output to generate. if vOutput == "csv": csvOutput = 1 elif vOutput == "html": htmlOutput = 1 elif vOutput == "xml": xmlOutput = 1 from xml.etree.ElementTree import Element, tostring r = Element("cve-search") elif vOutput == "json": jsonOutput = 1 elif vOutput == "cveid": cveidOutput = 1 else: cveidOutput = False # Print first line of html output if htmlOutput and args.p is not None: print("<html><body><h1>CVE search " + str(args.p) + " </h1>") elif htmlOutput and args.c is not None: print("<html><body><h1>CVE-ID " + str(args.c) + " </h1>") # search default is ascending mode sorttype = 1 if sLatest: sorttype = -1 def printCVE_json(item, indent=None): date_fields = ["cvssTime", "modified", "published"] for field in date_fields: if field in item: item[field] = str(item[field]) if not namelookup and not rankinglookup and not capeclookup: print( json.dumps(item, sort_keys=True, default=json_util.default, indent=indent) ) else: if "vulnerable_configuration" in item: vulconf = [] ranking = [] for conf in item["vulnerable_configuration"]: if namelookup: vulconf.append(cves.getcpe(cpeid=conf)) if rankinglookup: rank = cves.getranking(cpeid=conf) if rank and rank not in ranking: ranking.append(rank) if namelookup: item["vulnerable_configuration"] = vulconf if rankinglookup: item["ranking"] = ranking if "cwe" in item and capeclookup: if item["cwe"].lower() != "unknown": item["capec"] = cves.getcapec(cweid=(item["cwe"].split("-")[1])) print( json.dumps( item, sort_keys=True, default=json_util.default, indent=indent ) ) def printCVE_html(item): print( "<h2>" + item["id"] + "<br></h2>CVSS score: " + (str(item["cvss"]) if "cvss" in item else "None") + "<br>" + "<b>" + str(item["published"]) + "<b><br>" + item["summary"] + "<br>" ) print("References:<br>") for entry in item["references"]: print(entry + "<br>") ranking = [] for entry in item["vulnerable_configuration"]: if rankinglookup: rank = cves.getranking(cpeid=entry) if rank and rank not in ranking: ranking.append(rank) if rankinglookup: print("Ranking:<br>") for ra in ranking: for e in ra: for i in e: print(i + ": " + str(e[i]) + "<br>") print("<hr><hr>") def printCVE_csv(item): # We assume that the vendor name is usually in the hostame of the # URL to avoid any match on the resource part refs = [] for entry in item["references"]: if args.v is not None: url = urlparse(entry) hostname = url.netloc if re.search(args.v, hostname): refs.append(entry) if not refs: refs = "[no vendor link found]" if namelookup: nl = " ".join(item["vulnerable_configuration"]) ranking = [] ranking_ = [] for entry in item["vulnerable_configuration"]: if rankinglookup: rank = cves.getranking(cpeid=entry) if rank and rank not in ranking: ranking.append(rank) if rankinglookup: for r in ranking: for e in r: for i in e: ranking_.append(i + ":" + str(e[i])) if not ranking_: ranking_ = "[No Ranking Found]" else: ranking_ = " ".join(ranking_) csvoutput = csv.writer( sys.stdout, delimiter="|", quotechar="|", quoting=csv.QUOTE_MINIMAL ) if not rankinglookup: if not namelookup: csvoutput.writerow( [ item["id"], str(item["published"]), item["cvss"] if ("cvss" in item) else "None", item["summary"], refs, ] ) else: csvoutput.writerow( [ item["id"], str(item["published"]), item["cvss"] if ("cvss" in item) else "None", item["summary"], refs, nl, ] ) else: if not namelookup: csvoutput.writerow( [ item["id"], str(item["published"]), item["cvss"] if ("cvss" in item) else "None", item["summary"], refs, ranking_, ] ) else: csvoutput.writerow( [ item["id"], str(item["published"]), item["cvss"] if ("cvss" in item) else "None", item["summary"], refs, nl, ranking_, ] ) def printCVE_xml(item): xml = dicttoxml(item) print(xml.decode("utf-8")) def printCVE_id(item): print(item["id"]) def printCVE_human(item): print("CVE\t: {}".format(item["id"])) print("DATE\t: {}".format(str(item["published"]))) print("CVSS\t: {}".format((str(item["cvss"]) if "cvss" in item else "None"))) print(item["summary"]) print("\nReferences:") print("-----------") for entry in item["references"]: print(entry) print("\nVulnerable Configs:") print("-------------------") ranking = [] if "vulnerable_configuration" in item: for entry in item["vulnerable_configuration"]: print(vuln_config(entry)) if rankinglookup: rank = cves.getranking(cpeid=entry) if rank and rank not in ranking: ranking.append(rank) else: print([]) if rankinglookup: print("\nRanking: ") print("--------") for ra in ranking: for e in ra: for i in e: print("{}: {}".format(i, str(e[i]))) print("\n\n") # Search in summary text def search_in_summary(item): print(item["summary"]) # if args.a in str(item['summary']): # printCVE_json(item) if cveSearch: for item in getCVEs(cves=cveSearch)["results"]: print_job(item) if htmlOutput: print("</body></html>") sys.exit(0) # Basic freetext search (in vulnerability summary). # Full-text indexing is more efficient to search across all CVEs. if vFreeSearch: try: for item in getFreeText(vFreeSearch): printCVE_json(item, indent=2) except: sys.exit("Free text search not enabled on the database!") sys.exit(0) # Search Product (best to use CPE notation, e.g. cisco:ios:12.2 if vSearch: # Search multiple products in one query for cpe in vSearch: search_product(cpe) if htmlOutput: print("</body></html>") sys.exit(0) # Search text in summary if summary_text: listCve = searchCVE( find_params={"summary": re.compile(summary_text, re.IGNORECASE)}, limit=nlimit ) for item in listCve: item = cves.getCveFromMongoDbDoc(item) if "cvss" in item: if type(item["cvss"]) == str: item["cvss"] = float(item["cvss"]) date_fields = ["cvssTime", "modified", "published"] for field in date_fields: if field in item: item[field] = str(item[field]) if not last_ndays_published and not last_ndays_modified: if vOutput: printCVE_id(item) else: print(json.dumps(item, sort_keys=True, default=json_util.default)) else: if last_ndays_published: date_published_n_days_ago = datetime.now() - timedelta( days=last_ndays_published ) try: if ( datetime.strptime(item["published"], "%Y-%m-%d %H:%M:%S.%f") > date_published_n_days_ago ): if vOutput: printCVE_id(item) else: print( json.dumps( item, sort_keys=True, default=json_util.default ) ) continue # Do not show the item twice if both -t and -T are used. except: pass if last_ndays_modified: date_modified_n_days_ago = datetime.now() - timedelta( days=last_ndays_modified ) try: if ( datetime.strptime(item["published"], "%Y-%m-%d %H:%M:%S.%f") > date_modified_n_days_ago ): if vOutput: printCVE_id(item) else: print( json.dumps( item, sort_keys=True, default=json_util.default ) ) except: pass if htmlOutput: print("</body></html>") sys.exit(0) if xmlOutput: # default encoding is UTF-8. Should this be detected on the terminal? s = tostring(r).decode("utf-8") print(s) sys.exit(0) else: argParser.print_help() argParser.exit()
16,571
Python
.py
491
24.716904
118
0.569129
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,201
search_fulltext.py
cve-search_cve-search/bin/search_fulltext.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Search the CVE full text database # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2012-2018 Alexandre Dulaunoy - a@foo.be # Copyright (c) 2015-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com import argparse import json import os import sys from bson import json_util from whoosh import index, qparser from whoosh.fields import Schema, TEXT, ID from whoosh.qparser import QueryParser runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) from lib.Config import Configuration from lib.CVEs import CveHandler indexpath = Configuration.getIndexdir() # basepath = os.path.join(os.sep, *os.path.dirname(os.path.realpath(__file__)).rsplit('/')[:-1]) # print (os.path.split(os.path.join(basepath,indexpath))) schema = Schema(title=TEXT(stored=True), path=ID(stored=True), content=TEXT) ix = index.open_dir(indexpath) argParser = argparse.ArgumentParser(description="Full text search for cve-search") argParser.add_argument("-q", action="append", help="query to lookup (one or more)") argParser.add_argument( "-o", action="store_true", help="OR of the query to lookup (default is AND" ) argParser.add_argument( "-t", action="store_true", help="output title of the match CVE(s)" ) argParser.add_argument("-f", action="store_true", help="output matching CVE(s) in JSON") argParser.add_argument( "-m", type=int, default=False, help="most frequent terms in CVE description (m is top-m values)", ) argParser.add_argument( "-l", action="store_true", default=False, help="dump all terms encountered in CVE description", ) argParser.add_argument( "-g", action="store_true", default=False, help="graph of most frequent terms with each matching CVE (JSON output)", ) argParser.add_argument( "-s", action="store_true", default=False, help="enable stemming on graph JSON output (default is False)", ) argParser.add_argument( "-n", action="store_true", help="lookup complete cpe (Common Platform Enumeration) name for vulnerable configuration", ) argParser.add_argument( "-r", action="store_true", help="lookup ranking of vulnerable configuration" ) args = argParser.parse_args() if not args.q and not args.l and not args.g and not args.m: argParser.print_help() exit(1) if args.f or args.t: cves = CveHandler(rankinglookup=args.r, namelookup=args.n) if args.q: with ix.searcher() as searcher: if not args.o: query = QueryParser("content", ix.schema).parse(" ".join(args.q)) else: query = QueryParser( "content", schema=ix.schema, group=qparser.OrGroup ).parse(" ".join(args.q)) results = searcher.search(query, limit=None) for x in results: if not args.f: print(x["path"]) else: print( json.dumps( cves.getcve(x["path"]), sort_keys=True, default=json_util.default, ) ) if args.t and not args.f: print(" -- " + x["title"]) elif args.m: xr = ix.searcher().reader() for x in xr.most_frequent_terms("content", number=args.m): sys.stdout.write(str(int(x[0]))) sys.stdout.write(",") sys.stdout.write(x[1].decode("utf-8")) sys.stdout.write("\n") elif args.l and not args.g: xr = ix.searcher().reader() for x in xr.lexicon("content"): print(x) elif args.g: import json if args.s: from nltk.stem.wordnet import WordNetLemmatizer from nltk.corpus import stopwords lmtzr = WordNetLemmatizer() xr = ix.searcher().reader() s = {"name": "cve-search", "children": []} d = {} for x in xr.most_frequent_terms("content", 3000): query = QueryParser("content", ix.schema).parse(x[1]) if args.s: term = lmtzr.lemmatize(x[1].decode("utf-8"), "v") if term in stopwords.words("english"): continue else: term = x[1] term = term.decode("utf-8") if term in d: d[term]["size"] = d[term]["size"] + int(x[0]) else: d[term] = {} d[term]["size"] = int(x[0]) for k in sorted(d.keys(), key=lambda y: (d[y]["size"]), reverse=True): v = {"name": k, "size": d[k]["size"]} s["children"].append(v) print(json.dumps(s, indent=4)) else: argParser.print_help() exit(1)
4,660
Python
.py
136
28.191176
96
0.627716
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,202
search_cpe.py
cve-search_cve-search/bin/search_cpe.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Software is free software released under the "Modified BSD license" # # Copyright (c) 2014 psychedelys # Copyright (c) 2015-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com # Copyright (c) 2015-2019 Alexandre Dulaunoy - a@foo.be import argparse import json import os import re import sys import urllib.parse runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) import lib.DatabaseLayer as db runPath = os.path.dirname(os.path.realpath(__file__)) vOutput = "" argParser = argparse.ArgumentParser(description="Search for CPE with a pattern") argParser.add_argument("-s", type=str, required=True, help="search in cpe list") argParser.add_argument( "-o", type=str, default="expanded", help="O = output format [expanded, compact, json, csv] (default: expanded)", ) argParser.add_argument( "-f", action="store_true", help="Enlarge the CPE search to all CPE indexed. Need the cpeother activated.", default=False, ) args = argParser.parse_args() cpeSearch = args.s vOutput = args.o def search(cpe): res = db.getCPEMatching(re.compile(cpe, re.IGNORECASE), args.f) if vOutput == "compact": for item in res: print("{}".format(item["id"])) elif vOutput == "expanded": for item in res: print("{} {}".format(item["id"], item["title"])) elif vOutput == "csv": for item in res: if "references" in item: ref = ",".join(item["references"]) print("{},{},{}".format(item["id"], item["title"], ref)) else: print("{},{}".format(item["id"], item["title"])) elif vOutput == "json": o = [] for item in res: x = {} x["id"] = item["id"] x["title"] = item["title"] if "references" in item: x["references"] = item["references"] o.append(x) print(json.dumps(o, sort_keys=True, indent=4)) # replace special characters in cpeSearch with encoded version. cpeSearch = urllib.parse.quote(cpeSearch) search(cpeSearch)
2,177
Python
.py
64
28.5625
83
0.627143
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,203
dump_last.py
cve-search_cve-search/bin/dump_last.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Dump last CVE entries in RSS 1,RSS 2 or Atom format. # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2012-2018 Alexandre Dulaunoy - a@foo.be # Copyright (c) 2015-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com import argparse import datetime import html import os import sys import time runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) from lib.CVEs import CveHandler argParser = argparse.ArgumentParser( description="Dump last CVE entries in RSS/Atom format or in HTML tables" ) argParser.add_argument( "-f", type=str, help="Output format (rss1,rss2,atom,html)", default="rss1" ) argParser.add_argument("-l", type=int, help="Last n items (default:10)", default=10) argParser.add_argument( "-n", action="store_false", help="Disable lookup CPE name (default is True)" ) argParser.add_argument( "-r", action="store_true", help="Enable CVE ranking (default is False) and only print entries with ranking", ) argParser.add_argument( "-c", default=False, action="store_true", help="Display CAPEC values" ) args = argParser.parse_args() if args.l: last_items = args.l else: last_items = 10 ref = "http://adulau.github.com/cve-search/" cvelist = CveHandler(rankinglookup=args.r, namelookup=args.n, capeclookup=args.c) if not (args.f == "html"): from feedformatter import Feed feed = Feed() feed.feed["title"] = ( "cve-search Last " + str(last_items) + " CVE entries generated on " + str(datetime.datetime.now()) ) feed.feed["link"] = "http://adulau.github.com/cve-search/" feed.feed["author"] = ( "Generated with cve-search available at http://adulau.github.com/cve-search/" ) feed.feed["description"] = "" else: print("<html><head>") print( "<style>.cve table { border-collapse: collapse; text-align: left; width: 100%; } .cve {font: normal 12px/150% " "Geneva, Arial, Helvetica, sans-serif; background: #fff; overflow: hidden; border: 1px solid #006699; " "-webkit-border-radius: 3px; -moz-border-radius: 3px; border-radius: 3px; }.cve table td, .cve table th { " "padding: 3px 10px; }.cve table tbody td { color: #00496B; border-left: 1px solid #E1EEF4;font-size: " "12px;font-weight: normal; }.cve table tbody .alt td { background: #E1EEF4; color: #00496B; }.cve table tbody " "td:first-child { border-left: none; }.cve table tbody tr:last-child td { border-bottom: none; }.cve table " "tfoot td div { border-top: 1px solid #006699;background: #E1EEF4;} .cve table tfoot td { padding: 0; " "font-size: 12px } .cve table tfoot td div{ padding: 0px; }</style> " ) print("<title>Last " + str(args.l) + " CVE entries</title>") print("</head><body>") for x in cvelist.get(limit=last_items): if not (args.f == "html"): item = { "title": str(x["id"]) + " " + x["summary"][:90] + "...", "description": x["summary"], } if args.r and x.get("ranking"): item["description"] = item["description"] + " Ranking:" + str(x["ranking"]) item["pubDate"] = time.localtime() item["guid"] = x["id"] if x["references"]: item["link"] = str(x["references"][0]) else: item["link"] = "http://web.nvd.nist.gov/view/vuln/detail?vulnId=" + x["id"] feed.items.append(item) else: print('<div class="cve"><table><tbody>') print('<tr class="alt">') print( "<td>" + str(x["id"]) + " - " + html.escape(x["summary"][:90]) + "...</td>" ) print("</tr>") print( "<tr><td>CVSS: " + str(x["cvss"]) + " published: " + str(x["published"]) + "</td></tr>" ) print("<tr>") print("<td> Summary: " + html.escape(x["summary"]) + "</td>") print("</tr>") print("<tr><td>Vulnerable configuration:</td></tr>") print("<tr><td><ul>") for v in x["vulnerable_configuration"]: sys.stdout.write("<li>" + cvelist.getcpe(v) + "</li>") print("</ul></td></tr>") if x.get("ranking"): print("<tr><td>Ranking:" + str(x["ranking"]) + "</td></tr>") print("<tr><td>References:<td></tr>") print("<tr><td><ul>") for r in x["references"]: sys.stdout.write('<li><a href="' + str(r) + '">' + str(r) + "</a></li>") print("</ul></tr></td>") print("</tbody></table></div><br/>") if args.f == "rss1": print(feed.format_rss1_string()) elif args.f == "atom": print(feed.format_atom_string()) elif args.f == "html": print( 'Generated with <a href="https://github.com/adulau/cve-search">cve-search</a> at ' + str(datetime.datetime.today()) + "." ) print("</body></html>") else: print(feed.format_rss2_string())
5,043
Python
.py
129
33.046512
119
0.590455
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,204
Config.py
cve-search_cve-search/lib/Config.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Config reader to read the configuration file # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2013-2018 Alexandre Dulaunoy - a@foo.be # Copyright (c) 2014-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com import bz2 import configparser import gzip import json import os import re import urllib.parse import urllib.request as req import zipfile from io import BytesIO import pymongo import redis runPath = os.path.dirname(os.path.realpath(__file__)) class Configuration: ConfigParser = configparser.ConfigParser() ConfigParser.read( [ os.path.join(runPath, "../etc/configuration.ini"), os.path.join(runPath, "../etc/sources.ini"), ] ) default = { # [Redis] "redisHost": "localhost", "redisPort": 6379, "redisPass": None, "redisQ": 9, "redisVendorDB": 10, "redisNotificationsDB": 11, "redisRefDB": 12, # [Database] (MongoDB) "mongoHost": "127.0.0.1", "mongoPort": 27017, "mongoDB": "cvedb", "mongoUsername": "", "mongoPassword": "", "mongoSrv": False, "mongoAuth": "admin", "DatabasePluginName": "mongodb", # [Download] "DownloadMaxWorkers": 10, # [dbmgt] "Tmpdir": "./tmp", # [FulltextIndex] "Indexdir": "./indexdir", # [Webserver] "flaskHost": "127.0.0.1", "flaskPort": 5000, "flaskDebug": True, "flaskSSLDebug": False, "pageLength": 50, "loginRequired": False, "listLogin": True, "auth_load": "./etc/auth.txt", "oidc": False, "client_id": "xx", "client_secret": "xx", "idp_discovery_url": "xx", "ssl_verify": False, "ssl": False, "sslCertificate": "./ssl/cve-search.crt", "sslKey": "./ssl/cve-search.crt", "WebInterface": "Full", # defaults to Full; choices are 'Full' or 'Minimal' "MountPath": "/MOUNT", # must never end with a backslash... # [API] "CVEMaxLimit": 1000, "CORS": False, "CORS_Allow_Origin": "*", # [Logging] "logging": True, "logfile": "./log/cve-search.log", "updatelogfile": "./log/update_populate.log", "maxLogSize": "100MB", "backlog": 5, # [Proxy] "http_proxy": "", # [CVE] "CVEStartYear": 2002, # [Plugins] "plugin_load": "./etc/plugins.txt", "plugin_config": "./etc/plugins.ini", } sources = { "cwe": "https://cwe.mitre.org/data/xml/cwec_latest.xml.zip", "capec": "https://capec.mitre.org/data/xml/capec_latest.xml", "via4": "https://www.cve-search.org/feeds/via4.json", "epss": "https://epss.cyentia.com/epss_scores-current.csv.gz", } included = { "cpe": True, "cve": True, "cwe": True, "capec": True, "via4": True, "epss": True, } @classmethod def setCveXploreEnv(cls): """Wrapper for passing all the environment variables to CveXplore""" cls.setMongoDBEnv() cls.setProxyEnv() cls.setSourcesEnv() @classmethod def reloadConfiguration(cls): cls.ConfigParser.clear() return cls.ConfigParser.read( [ os.path.join(runPath, "../etc/configuration.ini"), os.path.join(runPath, "../etc/sources.ini"), ] ) @classmethod def readSetting(cls, section, item, default): result = default try: if type(default) == bool: result = cls.ConfigParser.getboolean(section, item) elif type(default) == int: result = cls.ConfigParser.getint(section, item) else: result = cls.ConfigParser.get(section, item) except: pass return result @classmethod def getWebInterface(cls): return cls.readSetting("Webserver", "WebInterface", cls.default["WebInterface"]) @classmethod def getMountPath(cls): return cls.readSetting("Webserver", "MountPath", cls.default["MountPath"]) # Mongo @classmethod def getMongoHost(cls): return cls.readSetting("Database", "Host", cls.default["mongoHost"]) @classmethod def getMongoPort(cls): return cls.readSetting("Database", "Port", cls.default["mongoPort"]) @classmethod def getMongoDB(cls): return cls.readSetting("Database", "DB", cls.default["mongoDB"]) @classmethod def getMongoUsername(cls): return cls.readSetting("Database", "Username", cls.default["mongoUsername"]) @classmethod def getMongoPassword(cls): return cls.readSetting("Database", "Password", cls.default["mongoPassword"]) @classmethod def getMongoConnection(cls): # jdt_NOTE: now correctly catches exceptions due to changes in pymongo 2.9 or later # jdt_NOTE: https://api.mongodb.com/python/current/migrate-to-pymongo3.html#mongoclient-connects-asynchronously connect = pymongo.MongoClient(cls.getMongoUri(), connect=False) return connect[cls.getMongoDB()] @classmethod def getMongoUri(cls): mongoSrv = cls.readSetting("Database", "DnsSrvRecord", cls.default["mongoSrv"]) mongoHost = cls.readSetting("Database", "Host", cls.default["mongoHost"]) mongoPort = cls.readSetting("Database", "Port", cls.default["mongoPort"]) mongoAuth = cls.readSetting("Database", "AuthDB", cls.default["mongoAuth"]) mongoDB = cls.getMongoDB() mongoUsername = urllib.parse.quote( cls.readSetting("Database", "Username", cls.default["mongoUsername"]) ) mongoPassword = urllib.parse.quote( cls.readSetting("Database", "Password", cls.default["mongoPassword"]) ) if mongoUsername and mongoPassword and mongoSrv is True: mongoURI = "mongodb+srv://{username}:{password}@{host}/{db}?authSource={auth}&retryWrites=true&w=majority".format( username=mongoUsername, password=mongoPassword, host=mongoHost, db=mongoDB, auth=mongoAuth, ) elif mongoUsername and mongoPassword: mongoURI = "mongodb://{username}:{password}@{host}:{port}/{db}?authSource={auth}".format( username=mongoUsername, password=mongoPassword, host=mongoHost, port=mongoPort, db=mongoDB, auth=mongoAuth, ) else: mongoURI = "mongodb://{host}:{port}/{db}".format( host=mongoHost, port=mongoPort, db=mongoDB ) return mongoURI @classmethod def setMongoDBEnv(cls): """Sets MongoDB settings as environment variables for CveXplore""" os.environ["DATASOURCE_HOST"] = cls.getMongoHost() os.environ["DATASOURCE_PORT"] = str(cls.getMongoPort()) os.environ["DATASOURCE_DBNAME"] = cls.getMongoDB() # Both username & password should be set to make any sense if cls.getMongoUsername() == "" or cls.getMongoPassword() == "": # Unset environment variables to make CveXplore default to None os.environ.pop("DATASOURCE_USER", None) os.environ.pop("DATASOURCE_PASSWORD", None) else: os.environ["DATASOURCE_USER"] = cls.getMongoUsername() os.environ["DATASOURCE_PASSWORD"] = cls.getMongoPassword() @classmethod def toPath(cls, path): return path if os.path.isabs(path) else os.path.join(runPath, "..", path) # Redis @classmethod def getRedisHost(cls): return cls.readSetting("Redis", "Host", cls.default["redisHost"]) @classmethod def getRedisPort(cls): return cls.readSetting("Redis", "Port", cls.default["redisPort"]) @classmethod def getRedisVendorConnection(cls): redisHost = cls.getRedisHost() redisPort = cls.getRedisPort() redisDB = cls.readSetting("Redis", "VendorsDB", cls.default["redisVendorDB"]) redisPass = cls.readSetting("Redis", "Password", cls.default["redisPass"]) return redis.StrictRedis( host=redisHost, port=redisPort, db=redisDB, password=redisPass, charset="utf-8", decode_responses=True, ) @classmethod def getRedisTokenConnection(cls): redisHost = cls.getRedisHost() redisPort = cls.getRedisPort() redisPass = cls.readSetting("Redis", "Password", cls.default["redisPass"]) return redis.StrictRedis( host=redisHost, port=redisPort, db=8, password=redisPass, charset="utf-8", decode_responses=True, ) @classmethod def getRedisNotificationsConnection(cls): redisHost = cls.getRedisHost() redisPort = cls.getRedisPort() redisDB = cls.readSetting( "Redis", "NotificationsDB", cls.default["redisNotificationsDB"] ) redisPass = cls.readSetting("Redis", "Password", cls.default["redisPass"]) return redis.StrictRedis( host=redisHost, port=redisPort, db=redisDB, password=redisPass, charset="utf-8", decode_responses=True, ) @classmethod def getRedisRefConnection(cls): redisHost = cls.getRedisHost() redisPort = cls.getRedisPort() redisDB = cls.readSetting("Redis", "RefDB", cls.default["redisRefDB"]) redisPass = cls.readSetting("Redis", "Password", cls.default["redisPass"]) return redis.StrictRedis( host=redisHost, port=redisPort, db=redisDB, password=redisPass, charset="utf-8", decode_responses=True, ) # Flask @classmethod def getFlaskHost(cls): return cls.readSetting("Webserver", "Host", cls.default["flaskHost"]) @classmethod def getFlaskPort(cls): return cls.readSetting("Webserver", "Port", cls.default["flaskPort"]) @classmethod def getFlaskDebug(cls): return cls.readSetting("Webserver", "Debug", cls.default["flaskDebug"]) @classmethod def getFlaskSSLDebug(cls): return cls.readSetting("Webserver", "SSLDebug", cls.default["flaskSSLDebug"]) # Webserver @classmethod def getPageLength(cls): return cls.readSetting("Webserver", "PageLength", cls.default["pageLength"]) # REST API @classmethod def getCVEMaxLimit(cls): return cls.readSetting("API", "CVEMaxLimit", cls.default["CVEMaxLimit"]) @classmethod def getCORS(cls): return cls.readSetting("API", "CORS", cls.default["CORS"]) @classmethod def getCORSAllowOrigin(cls): return cls.readSetting( "API", "CORS_Allow_Origin", cls.default["CORS_Allow_Origin"] ) # Authentication @classmethod def loginRequired(cls): return cls.readSetting( "Webserver", "LoginRequired", cls.default["loginRequired"] ) @classmethod def listLoginRequired(cls): return cls.readSetting( "Webserver", "ListLoginRequired", cls.default["listLogin"] ) @classmethod def getAuthLoadSettings(cls): return cls.toPath( cls.readSetting("Webserver", "authSettings", cls.default["auth_load"]) ) @classmethod def useOIDC(cls): return cls.readSetting("Webserver", "OIDC", cls.default["oidc"]) @classmethod def getClientID(cls): return cls.readSetting("Webserver", "CLIENT_ID", cls.default["client_id"]) @classmethod def getClientSecret(cls): return cls.readSetting( "Webserver", "CLIENT_SECRET", cls.default["client_secret"] ) @classmethod def getIDPDiscoveryUrl(cls): return cls.readSetting( "Webserver", "IDP_DISCOVERY_URL", cls.default["idp_discovery_url"] ) # SSL @classmethod def useSSLVerify(cls): return cls.readSetting("Webserver", "SSL_VERIFY", cls.default["ssl_verify"]) @classmethod def getSSLCert(cls): return cls.toPath( cls.readSetting("Webserver", "Certificate", cls.default["sslCertificate"]) ) @classmethod def getSSLKey(cls): return cls.toPath(cls.readSetting("Webserver", "Key", cls.default["sslKey"])) # Logging @classmethod def getLogfile(cls): return cls.toPath(cls.readSetting("Logging", "Logfile", cls.default["logfile"])) @classmethod def getUpdateLogFile(cls): return cls.toPath( cls.readSetting("Logging", "Updatelogfile", cls.default["updatelogfile"]) ) @classmethod def getLogging(cls): return cls.readSetting("Logging", "Logging", cls.default["logging"]) @classmethod def getMaxLogSize(cls): size = cls.readSetting("Logging", "MaxSize", cls.default["maxLogSize"]) split = re.findall("\d+|\D+", size) multipliers = {"KB": 1024, "MB": 1024 * 1024, "GB": 1024 * 1024 * 1024} if len(split) == 2: base = int(split[0]) unit = split[1].strip().upper() return base * multipliers.get(unit, 1024 * 1024) # if size is not a correctly defined set it to 100MB else: return 100 * 1024 * 1024 @classmethod def getBacklog(cls): return cls.readSetting("Logging", "Backlog", cls.default["backlog"]) # Download Max Workers @classmethod def getDownloadMaxWorkers(cls): maxWorkers = cls.readSetting( "Download", "MaxWorkers", cls.default["DownloadMaxWorkers"] ) if type(maxWorkers) == int: if maxWorkers > 0: return maxWorkers else: return 1 else: return cls.default["DownloadMaxWorkers"] # Indexing @classmethod def getIndexdir(cls): return cls.toPath( cls.readSetting("FulltextIndex", "Indexdir", cls.default["Indexdir"]) ) # Http Proxy @classmethod def getProxy(cls): return cls.readSetting("Proxy", "http", cls.default["http_proxy"]) @classmethod def setProxyEnv(cls): """Sets proxy settings as environment variables for CveXplore""" if cls.getProxy() == "": # Remove environment variables os.environ.pop("HTTP_PROXY_DICT", None) os.environ.pop("HTTP_PROXY_STRING", None) else: # Set environment variables proxyDict = { "http": f"http://{cls.getProxy()}", "https": f"http://{cls.getProxy()}", } os.environ["HTTP_PROXY_DICT"] = json.dumps(proxyDict) os.environ["HTTP_PROXY_STRING"] = f"http://{cls.getProxy()}" @classmethod def getFile(cls, getfile, unpack=True): if cls.getProxy(): proxy = req.ProxyHandler({"http": cls.getProxy(), "https": cls.getProxy()}) auth = req.HTTPBasicAuthHandler() opener = req.build_opener(proxy, auth, req.HTTPHandler) req.install_opener(opener) response = req.urlopen(getfile) data = response # TODO: if data == text/plain; charset=utf-8, read and decode if unpack: if "gzip" in response.info().get("Content-Type"): buf = BytesIO(response.read()) data = gzip.GzipFile(fileobj=buf) elif "bzip2" in response.info().get("Content-Type"): data = BytesIO(bz2.decompress(response.read())) elif "zip" in response.info().get("Content-Type"): fzip = zipfile.ZipFile(BytesIO(response.read()), "r") if len(fzip.namelist()) > 0: data = BytesIO(fzip.read(fzip.namelist()[0])) return (data, response) # Sources @classmethod def getFeedURL(cls, source): return cls.readSetting("Sources", source, cls.sources.get(source, "")) @classmethod def includesFeed(cls, feed): return cls.readSetting("EnabledFeeds", feed, cls.included.get(feed, False)) @classmethod def setSourcesEnv(cls): """Sets sources dictionary as an environment variable for CveXplore""" sources = {} for source in cls.sources: sources.update({source: cls.getFeedURL(source)}) os.environ["SOURCES"] = json.dumps(sources) # Plugins @classmethod def getPluginLoadSettings(cls): return cls.toPath( cls.readSetting("Plugins", "loadSettings", cls.default["plugin_load"]) ) @classmethod def getPluginsettings(cls): return cls.toPath( cls.readSetting("Plugins", "pluginSettings", cls.default["plugin_config"]) ) class ConfigReader: def __init__(self, file): self.ConfigParser = configparser.ConfigParser() self.ConfigParser.read(file) def read(self, section, item, default): result = default try: if type(default) == bool: result = self.ConfigParser.getboolean(section, item) elif type(default) == int: result = self.ConfigParser.getint(section, item) else: result = self.ConfigParser.get(section, item) except: pass return result
17,742
Python
.py
477
28.322851
126
0.604547
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,205
Sources_process.py
cve-search_cve-search/lib/Sources_process.py
import logging import sys import time from datetime import timedelta from tqdm import tqdm from lib.Config import Configuration from lib.DatabaseLayer import ( getCPEs, ) from lib.cpe_conversion import split_cpe_name class CPERedisBrowser(object): def __init__(self, cpes=None): try: self.__db = Configuration.getRedisVendorConnection() except Exception: sys.exit(1) if cpes is None: self.cpes = getCPEs() else: self.cpes = cpes self.set_debug_logging = False self.logger = logging.getLogger("CPERedisBrowser") def update(self): self.logger.info("Redis CPE database update started") start_time = time.time() for e in tqdm(self.cpes, desc="Inserting CPE's in redis"): value = e["cpeName"] cpe_name = split_cpe_name(value) (prefix, cpeversion, cpetype, vendor, product) = cpe_name[:5] version = ":".join(cpe_name[5:]) if self.set_debug_logging: self.logger.debug("prefix: {}".format(prefix)) self.logger.debug("cpetype: {}".format(cpetype)) self.logger.debug("vendor: {} ".format(vendor)) self.logger.debug("product: {} ".format(product)) self.logger.debug("version: {}".format(version)) self.__db.sadd("prefix:" + prefix, cpetype) self.__db.sadd(cpetype, vendor) self.__db.sadd("v:" + vendor, product) if version: self.__db.sadd("p:" + product, version) self.logger.info( "Duration: {}".format(timedelta(seconds=time.time() - start_time)) )
1,716
Python
.py
44
29.454545
78
0.590361
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,206
Singleton.py
cve-search_cve-search/lib/Singleton.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2017-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com class Singleton(type): _instances = {} def __call__(cls, *args, **kwargs): if cls not in cls._instances: cls._instances[cls] = super(Singleton, cls).__call__(*args, **kwargs) return cls._instances[cls]
456
Python
.py
12
33.75
87
0.657596
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,207
User.py
cve-search_cve-search/lib/User.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2015-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com # Imports import os from flask_login import UserMixin runPath = os.path.dirname(os.path.realpath(__file__)) from lib.Config import Configuration # Exception class UserNotFoundError(Exception): pass # Class class User(UserMixin): def __init__(self, id, auth_instance): """Simple User class""" self.id = id if Configuration.loginRequired() and not Configuration.useOIDC(): if not auth_instance.isCVESearchUser(id): raise UserNotFoundError() self.authenticator = auth_instance def authenticate(self, password): return self.authenticator.validateUser(self.id, password) @classmethod def get(cls, id, auth_instance): """Return user instance of id, return None if not exist""" try: return cls(id, auth_instance) except UserNotFoundError: return None
1,109
Python
.py
32
28.96875
87
0.686973
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,208
cpelist.py
cve-search_cve-search/lib/cpelist.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # CPEList class, used in black-and whitelists # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2014-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com import json import os import sys runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) from lib.Toolkit import toStringFormattedCPE class CPEList: def __init__(self, collection, args): import lib.DatabaseLayer as db self.db = db self.collection = collection.title() self.args = args # check if there are items in the collection def countItems(self): return self.db.getSize("mgmt_" + self.collection.lower()) # check if a cpe is in the list def check(self, cpe): return getattr(self.db, "isIn" + self.collection)(cpe) # insert to database def insert(self, cpe, cpeType, comments=None): try: if comments is not None: comments = comments else: # split comments from cpe comments = cpe.split("#") del comments[0] cpeID = cpe.split("#")[0] if cpeType.lower() == "cpe": cpeID = toStringFormattedCPE(cpeID) # check format if cpeID: # already in self.db? if not self.check(cpeID): getattr(self.db, "addTo" + self.collection)( cpeID, cpeType, comments ) return True return False except Exception as ex: print("Error inserting item in database: {}".format(ex)) sys.exit() # remove a cpe from the list def remove(self, cpe): try: cpe = cpe.strip() # translate cpe if toStringFormattedCPE(cpe): cpe = toStringFormattedCPE(cpe) # check if the cpe is in the list if self.check(cpe): getattr(self.db, "removeFrom" + self.collection)(cpe) return True else: return False except Exception as ex: print("Error removing item from database: {}".format(ex)) sys.exit() def update(self, cpeOld, cpeNew, cpeType): try: cpeOld = cpeOld.strip() cpeNew = cpeNew.strip() # translate cpes cpeOld = toStringFormattedCPE(cpeOld) cpeNew = toStringFormattedCPE(cpeNew) if cpeOld and cpeNew: # already in self.db? if self.check(cpeOld.split("#")[0]): cpeID = cpeNew.split("#")[0] cpeID.strip() # comments comments = cpeNew.split("#") del comments[0] getattr(self.db, "update" + self.collection)( cpeOld.split("#")[0], cpeID, cpeType, comments ) return True return False except Exception as ex: print(ex) print("Error updating item in database: {}".format(ex)) sys.exit() # drop the collection def dropCollection(self): try: count = self.countItems() self.db.drop("mgmt_" + self.collection.lower()) return "collection of {} items dropped".format(count) except Exception as ex: return "Error dropping the database: {}".format(ex) # import a file that represents the cpe list def importList(self, importFile): count = 0 # read each line from the import file and regex them to a cpe format try: importFile = ( importFile.read().decode("utf-8").replace("\n", "").replace(" ", "") ) except AttributeError: importFile = importFile.decode("utf-8").replace("\n", "").replace(" ", "") try: for line in json.loads(importFile): try: t = line["type"] if t not in ["cpe", "targetsoftware", "targethardware"]: continue cpe = line["id"] if "comments" in line: cpe += "#" + "#".join(line["comments"]) if self.insert(cpe, t): count += 1 except Exception as err: return "Error encountered: {}".format(err) return "{} products added to the list".format(count) except IOError: return "The list is corrupted!" # export a file that represents the cpe list def exportList(self, exportFile=None): listed = getattr(self.db, "get" + self.collection)() output = json.dumps(listed, sort_keys=True, indent=2) if exportFile is None: return output else: if not os.path.exists(exportFile) or self.args.f: export = open(exportFile, "w") export.write(output) export.close() if self.args.v: print("{} listed items exported".format(len(listed))) else: print("file already exists") # process the arguments and use it to take actions def process(self): if self.args.d: # drop the list self.dropCollection() elif self.args.i: # get import file textfile = self.args.i # check if the collection is empty count = self.countItems() if count > 0 and self.args.f is False: # not empty and not forced to drop print("list already populated") else: # drop collection and repopulate it self.dropCollection() self.importList(open(textfile)) elif self.args.e: # get export file textfile = self.args.e self.exportList(textfile) elif self.args.a or self.args.A: # get list of cpe's to add if self.args.a: cpeList = self.args.a else: cpeList = [x for x in open(self.args.A[0])] # add each item from the list count = 0 for cpeID in cpeList: if self.insert(cpeID, self.args.t): count += 1 if self.args.v: print("{} products added to the list".format(count)) elif self.args.r or self.args.R: # get list of cpe's to remove if self.args.r: cpeList = self.args.r else: cpeList = [x for x in open(self.args.R[0])] # remove each item from the list count = 0 for cpeID in cpeList: amount = self.remove(cpeID) count += amount if self.args.v: print("{} products removed from the list".format(count))
7,169
Python
.py
186
25.924731
87
0.521246
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,209
ApiRequests.py
cve-search_cve-search/lib/ApiRequests.py
import logging from abc import ABC, abstractmethod from datetime import datetime from nested_lookup import nested_lookup, nested_update from lib.LogHandler import AppLogger from web.helpers.common import timestringTOdatetime, date_time_formats logging.setLoggerClass(AppLogger) def convertDatetime(dct=None): if isinstance(dct, (list, tuple, set)): for item in dct: convertDatetime(item) elif type(dct) is dict: for key, val in dct.items(): if isinstance(val, datetime): dct[key] = val.isoformat() if isinstance(val, (dict, list)): convertDatetime(val) return dct class ApiRequest(ABC): def __init__(self): self._request_results = None @abstractmethod def process(self, **kwargs): raise NotImplementedError @property def request_results(self): return self._request_results @request_results.setter def request_results(self, the_results): self._request_results = {"total": len(the_results), "data": the_results} class JSONApiRequest(ApiRequest): def __init__(self, headers, body): """ Main class for the JSONApiRequest endpoints of the api. :param headers: Request headers :type headers: dict :param body: JSON query body :type body: dict """ super().__init__() self.logger = logging.getLogger(__name__) self.request_headers = headers self.body = body def process(self, database_connection): """ Method to process the request :param database_connection: Hookup to the database :type database_connection: DatabaseHandler :return: Results from the request :rtype: list """ self.logger.debug( "Processing request: {} Headers received: {}".format( self.body, self.request_headers ) ) validated, reason = self.validate_body() if not validated: self.logger.warning( "Validation on {} not succeeded: {}".format(self.body, reason) ) return reason, 400 else: results = database_connection.query_docs(**self.body) self.logger.debug( "Retrieving from: {} -- records: {}".format( self.body["retrieve"], len(results) ) ) self.request_results = results return convertDatetime(dct=self.request_results) def validate_body(self): """ Method for validating the request body. """ retrieve = ["capec", "cpe", "cves", "cwe", "via4"] sort_dir = ["ASC", "DESC"] required_keys = ["retrieve", "dict_filter"] optional_keys = ["sort", "limit", "skip", "query_filter", "sort_dir"] date_keys = ["published", "modified", "lastModified"] if self.body is None or len(self.body) == 0: return ( False, "Please send a proper request with a json formatted like in the documentation.", ) if not all(key.lower() in self.body for key in required_keys): return False, "Request is missing one or more required keys!" # convert date_keys from string to datetime objects if "dict_filter" in self.body: for key in date_keys: convert_values = nested_lookup(key, self.body["dict_filter"]) if len(convert_values) != 0: converted_val = self.convert_datetimestring_to_datetime( convert_values[0] ) if converted_val: nested_update( document=self.body["dict_filter"], key=key, value=converted_val, ) else: return ( False, "Could not convert provided date string to valid datetime object; currently supported " "formats are: {}".format(date_time_formats), ) if not self.body["retrieve"].lower() in retrieve: return False, "Unable to retrieve from specified data source!" if "sort_dir" in self.body.keys(): if not self.body["sort_dir"] in sort_dir: return ( False, "Specified sorting direction not possible; possible options are: {}!".format( sort_dir ), ) all_keys = retrieve + required_keys + optional_keys if not all(key in all_keys for key in self.body): return False, "Request contains unknown keys!" if "skip" in self.body: try: self.body["skip"] = int(self.body["skip"]) except ValueError: return False, "Skip parameter is not a integer!" if "limit" in self.body: try: self.body["limit"] = int(self.body["limit"]) except ValueError: return False, "Limit parameter is not a integer!" return True, "Ok" def convert_datetimestring_to_datetime(self, dict_entry): """ :param dict_entry: :type dict_entry: dict :return: :rtype: """ date_item = False if isinstance(dict_entry, str): date_item = timestringTOdatetime(dict_entry) elif isinstance(dict_entry, dict): for k, v in dict_entry.items(): convert_val = timestringTOdatetime(v) if convert_val: dict_entry[k] = convert_val else: return False date_item = dict_entry return date_item
5,985
Python
.py
150
27.546667
115
0.54817
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,210
DatabaseLayer.py
cve-search_cve-search/lib/DatabaseLayer.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Database layer translates database calls to functions # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2015-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com # imports import re import pymongo from lib.Config import Configuration as conf from lib.cpe_conversion import split_cpe_name # Variables db = conf.getMongoConnection() colCVE = db["cves"] colCPE = db["cpe"] colCWE = db["cwe"] colCPEOTHER = db["cpeother"] colWHITELIST = db["mgmt_whitelist"] colBLACKLIST = db["mgmt_blacklist"] colUSERS = db["mgmt_users"] colINFO = db["info"] colRANKING = db["ranking"] colVIA4 = db["via4"] colCAPEC = db["capec"] colPlugSettings = db["plugin_settings"] colPlugUserSettings = db["plugin_user_settings"] mongo_version = db.command("buildinfo")["versionArray"] # to check if mongodb > 4.4 # if it is, then use allow_disk_use for optimized queries # to be removed in future with the conditional statements # and use allow_disk_use by default # Functions def sanitize(x): if type(x) == pymongo.cursor.Cursor: x = list(x) if type(x) == list: for y in x: sanitize(y) if x and "_id" in x: x.pop("_id") return x # DB Functions def setColUpdate(collection, date): colINFO.update({"db": collection}, {"$set": {"lastModified": date}}, upsert=True) def cpeotherBulkInsert(cpeotherlist): colCPEOTHER.insert(cpeotherlist) def dropCollection(col): return db[col].drop() # jdt_NOTE: is exactly the same as drop(collection) # jdt_NOTE: use only one of them def getTableNames(): # return db.collection_names() # jdt_NOTE: collection_names() is depreated, list_collection_names() should be used instead return db.list_collection_names() # returns True if 'target_version' is less or equal than # 'cpe_version' # returns False otherwise def target_version_is_included(target_version, cpe_version): sp_target = target_version.split(".") sp_cpe = cpe_version.split(".") if len(sp_target) > len(sp_cpe): sp_cpe += [0] * (len(sp_target) - len(sp_cpe)) if len(sp_cpe) > len(sp_target): sp_cpe += [0] * (len(sp_cpe) - len(sp_target)) for i in range(len(sp_target)): # target version smaller than cpe version if int(sp_target[i]) < int(sp_cpe[i]): return True # target version greater than cpe version if int(sp_target[i]) > int(sp_cpe[i]): return False # target version same version as cpe version return True # API Functions def cvesForCPE( cpe, lax=False, vulnProdSearch=False, limit=0, strict_vendor_product=False ): if not cpe: return [] notices = [] cpe_regex = cpe final_cves = [] cpe_searchField = ( "vulnerable_product" if vulnProdSearch else "vulnerable_configuration" ) # relaxSearch for search.py --lax; Strict search for software version is disabled. if lax: # get target version from product description provided by the user cpe_name = split_cpe_name(cpe) if len(cpe_name) != 3: raise ValueError( f"Format 'vendor:product:version' expected in --lax mode, got '{cpe}'" ) target_version = cpe_name[-1] product = ":".join(cpe_name[:-1]) # For easier version comparison of exceptional version strings (not simple 1.2.3), simplify # version strings containing non-numeric characters like "1.1.3p2" or "1.1.3mr2" as "1.1.3.0.2"; # the extra zero (.0.) is for avoiding collisions between, e.g., "1.0p1" and "1.0.1", # where 1.0p1, converted to 1.0.0.1, will be less than 1.0.1. target_version_simplified = re.sub(r"[^\d\.]+", ".0.", target_version) # ...and then remove duplicate, leading & tailing dots target_version_simplified = re.sub(r"[\.]+", ".", target_version_simplified) target_version_simplified = target_version_simplified.strip(".") # Notify user of the simplification. if target_version_simplified != target_version: notices.append( f"Notice: Target version {target_version} simplified as {target_version_simplified} for " f"easier version comparison; doing the same for CPEs in Vulnerable Configs under the hood." ) # over-approximate versions cpe_regex = product if limit != 0: if mongo_version > [4, 4]: cves = ( colCVE.find({cpe_searchField: {"$regex": cpe_regex}}) .limit(limit) .sort( [("modified", pymongo.DESCENDING), ("cvss", pymongo.DESCENDING)] ) .allow_disk_use(True) ) else: cves = ( colCVE.find({cpe_searchField: {"$regex": cpe_regex}}) .limit(limit) .sort( [("modified", pymongo.DESCENDING), ("cvss", pymongo.DESCENDING)] ) ) else: if mongo_version > [4, 4]: cves = ( colCVE.find({cpe_searchField: {"$regex": cpe_regex}}) .sort("modified", direction=pymongo.DESCENDING) .allow_disk_use(True) ) else: cves = colCVE.find({cpe_searchField: {"$regex": cpe_regex}}).sort( "modified", direction=pymongo.DESCENDING ) i = 0 for cve in cves: vuln_confs = cve["vulnerable_configuration"] vuln_confs += cve["vulnerable_configuration_cpe_2_2"] vuln_confs += cve["vulnerable_product"] i += 1 for vc in vuln_confs: if cpe_regex not in vc: continue re_from_start = re.compile("^.*{}:".format(re.escape(cpe_regex))) cpe_version = re_from_start.sub("", vc) cpe_version = split_cpe_name(cpe_version)[0] # Simplify equally with the target_version to enable comparison cpe_version_simplified = re.sub(r"[^\d\.]+", ".0.", cpe_version) cpe_version_simplified = re.sub(r"[\.]+", ".", cpe_version_simplified) cpe_version_simplified = cpe_version_simplified.strip(".") if len(cpe_version_simplified) == 0: continue if target_version_is_included( target_version_simplified, cpe_version_simplified ): final_cves.append(cve) break elif strict_vendor_product: # strict product search vendor, product = cpe cpe_regex_string = r"^{}".format(re.escape(product)) if limit != 0: if mongo_version > [4, 4]: cves = ( colCVE.find( {"vendors": vendor, "products": {"$regex": cpe_regex_string}} ) .limit(limit) .sort("cvss", direction=pymongo.DESCENDING) .allow_disk_use(True) ) else: cves = ( colCVE.find( {"vendors": vendor, "products": {"$regex": cpe_regex_string}} ) .limit(limit) .sort("cvss", direction=pymongo.DESCENDING) ) else: cves = colCVE.find( {"vendors": vendor, "products": {"$regex": cpe_regex_string}} ) final_cves = cves else: # create strict cpe regex if cpe_regex.startswith("cpe"): # strict search with term starting with cpe; e.g: cpe:2.3:o:microsoft:windows_7:*:sp1:*:*:*:*:*:* remove_trailing_regex_stars = r"(?:\:|\:\:|\:\*)+$" cpe_regex = re.escape(re.sub(remove_trailing_regex_stars, "", cpe_regex)) cpe_regex_string = r"^{}:".format(cpe_regex) else: # more general search on same field; e.g. microsoft:windows_7 cpe_regex_string = "{}".format(re.escape(cpe_regex)) # default strict search if limit != 0: if mongo_version > [4, 4]: cves = ( colCVE.find( {"{}".format(cpe_searchField): {"$regex": cpe_regex_string}} ) .limit(limit) .sort("cvss", direction=pymongo.DESCENDING) .allow_disk_use(True) ) else: cves = ( colCVE.find( {"{}".format(cpe_searchField): {"$regex": cpe_regex_string}} ) .limit(limit) .sort("cvss", direction=pymongo.DESCENDING) ) else: cves = colCVE.find( {"{}".format(cpe_searchField): {"$regex": cpe_regex_string}} ) final_cves = cves final_cves = sanitize(final_cves) if not notices: return {"results": final_cves, "total": len(final_cves)} else: return {"notices": notices, "results": final_cves, "total": len(final_cves)} # Query Functions # Generic data def getCVEs(limit=False, query=[], skip=0, cves=None, collection=None): col = colCVE if not collection else db[collection] if type(query) == dict: query = [query] if type(cves) == list: query.append({"id": {"$in": cves}}) if len(query) == 0: if mongo_version > [4, 4]: cve = ( col.find() .sort("modified", pymongo.DESCENDING) .limit(limit) .skip(skip) .allow_disk_use(True) ) else: cve = ( col.find().sort("modified", pymongo.DESCENDING).limit(limit).skip(skip) ) elif len(query) == 1: if mongo_version > [4, 4]: cve = ( col.find(query[0]) .sort("modified", pymongo.DESCENDING) .limit(limit) .skip(skip) .allow_disk_use(True) ) else: cve = ( col.find(query[0]) .sort("modified", pymongo.DESCENDING) .limit(limit) .skip(skip) ) else: if mongo_version > [4, 4]: cve = ( col.find({"$and": query}) .sort("modified", pymongo.DESCENDING) .limit(limit) .skip(skip) .allow_disk_use(True) ) else: cve = ( col.find({"$and": query}) .sort("modified", pymongo.DESCENDING) .limit(limit) .skip(skip) ) return {"results": sanitize(cve), "total": len(list(cve))} def getCVEsNewerThan(dt): return getCVEs(query={"lastModified": {"$gt": dt}}) def getCVEIDs(limit=-1): if mongo_version > [4, 4]: return [ x["id"] for x in colCVE.find() .limit(limit) .sort("modified", pymongo.DESCENDING) .allow_disk_use(True) ] else: return [ x["id"] for x in colCVE.find().limit(limit).sort("modified", pymongo.DESCENDING) ] def searchCVE(find_params=None, limit=-1): return ( colCVE.find({} if find_params is None else find_params) .limit(limit) .sort("modified", pymongo.DESCENDING) ) def getCVE(id, collection=None): col = colCVE if not collection else db[collection] return sanitize(col.find_one({"id": id})) def getCPE(id): return sanitize(colCPE.find_one({"id": id})) def getCPEs(): return sanitize(colCPE.find()) def getAlternativeCPE(id): return sanitize(colCPEOTHER.find_one({"id": id})) def getAlternativeCPEs(): return sanitize(colCPEOTHER.find()) def getVIA4(id): return sanitize(colVIA4.find_one({"id": id})) def getCPEMatching(regex, fullSearch=False): lst = list(colCPE.find({"title": {"$regex": regex}})) if fullSearch: lst.extend(colCPEOTHER.find({"title": {"$regex": regex}})) return lst def getFreeText(text): try: # Before Mongo 3 return [x["obj"] for x in db.command("text", "cves", search=text)["results"]] except: # As of Mongo 3 return sanitize(colCVE.find({"$text": {"$search": text}})) def getSearchResults(search): result = {"data": []} regSearch = re.compile(re.escape(search), re.IGNORECASE) links = {"n": "Link", "d": []} via4 = getInfo("via4") if via4: for vLink in via4.get("searchables", []): links["d"].extend(sanitize(colVIA4.find({vLink: {"$in": [regSearch]}}))) try: textsearch = {"n": "Text search", "d": getFreeText(search)} except: textsearch = {"n": "Text search", "d": []} result["errors"] = ["textsearch"] search = search.lower() vendor_query = { "n": "Vendor", "d": getCVEs(query=[{"vendors": search.replace(" ", "")}])["results"], } product_query = { "n": "Product", "d": getCVEs(query=[{"products": search.replace(" ", "_")}])["results"], } for collection in [vendor_query, product_query, links, textsearch]: for item in collection["d"]: # Check if already in result data if not any(item["id"] == entry["id"] for entry in result["data"]): entry = getCVE(item["id"]) if entry: entry["reason"] = collection["n"] result["data"].append(entry) return result def getCAPECFor(capecid): return sanitize(colCAPEC.find({"related_weakness": {"$in": [capecid]}})) def getCAPEC(capecid): return sanitize(colCAPEC.find_one({"id": capecid})) def getCWEs(cweid=None): if cweid is None: return sanitize(sorted(colCWE.find(), key=lambda k: int(k["id"]))) else: return sanitize(colCWE.find_one({"id": cweid})) def getInfo(collection): return sanitize(colINFO.find_one({"db": collection})) def getLastModified(collection): info = getInfo(collection) return info["lastModified"] if info else None def getSize(collection): return db[collection].count_documents(filter={}) def via4Linked(key, val): cveList = [x["id"] for x in colVIA4.find({key: val})] return sanitize(getCVEs(query={"id": {"$in": cveList}})) def getDBStats(include_admin=False): data = {"cves": {}, "cpe": {}, "cpeOther": {}, "capec": {}, "cwe": {}, "via4": {}} for key in data.keys(): data[key] = { "size": getSize(key.lower()), "last_update": getLastModified(key.lower()), } if include_admin: data["whitelist"] = {"size": colWHITELIST.count_documents(filter={})} data["blacklist"] = {"size": colBLACKLIST.count_documents(filter={})} data = { "stats": { "size_on_disk": db.command("dbstats")["storageSize"], "db_size": db.command("dbstats")["dataSize"], "name": conf.getMongoDB(), }, "data": data, } return data # Dynamic data def getWhitelist(): return sanitize(colWHITELIST.find()) def getBlacklist(): return sanitize(colBLACKLIST.find()) def getRules(list): if list.lower() == "whitelist": col = colWHITELIST elif list.lower() == "blacklist": col = colBLACKLIST else: return [] rlist = col.find({"type": "cpe"}).distinct("id") rlist.extend( [ "cpe:2.3:([^:]*:){9}" + re.escape(x) for x in col.find({"type": "targethardware"}).distinct("id") ] ) rlist.extend( [ "cpe:2.3:([^:]*:){8}" + re.escape(x) for x in col.find({"type": "targetsoftware"}).distinct("id") ] ) return rlist def addRanking(cpe, key, rank): item = findRanking(cpe) if item is None: colRANKING.update({"cpe": cpe}, {"$push": {"rank": {key: rank}}}, upsert=True) else: l = [] for i in item["rank"]: i[key] = rank l.append(i) colRANKING.update({"cpe": cpe}, {"$set": {"rank": l}}) return True def removeRanking(cpe): return sanitize(colRANKING.remove({"cpe": {"$regex": cpe, "$options": "i"}})) def findRanking(cpe=None, regex=False): if not cpe: # return sanitize(colRANKING.find()) return None if regex: # return sanitize(colRANKING.find_one({'cpe': {'$regex': cpe}})) return None else: return None # return sanitize(colRANKING.find_one({'cpe': cpe}))
17,011
Python
.py
448
28.162946
109
0.550392
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,211
Toolkit.py
cve-search_cve-search/lib/Toolkit.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Toolkit for functions between scripts # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2014-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com import re import lib.cpe_conversion # Note of warning: CPEs like cpe:/o:microsoft:windows_8:-:-:x64 are given to us by Mitre # x64 will be parsed as Edition in this case, not Architecture def toStringFormattedCPE(cpe, autofill=False): cpe = cpe.strip() if not cpe.startswith("cpe:2.3:"): if not cpe.startswith("cpe:/"): return False cpe = lib.cpe_conversion.cpe_uri_to_fs(cpe) if autofill: e = lib.cpe_conversion.split_cpe_name(cpe) for x in range(0, 13 - len(e)): cpe += ":-" return cpe # Note of warning: Old CPE's can come in different formats, and are not uniform. Possibilities are: # cpe:/a:7-zip:7-zip:4.65::~~~~x64~ # cpe:/a:7-zip:7-zip:4.65:-:~~~~x64~ # cpe:/a:7-zip:7-zip:4.65:-:~-~-~-~x64~ def toOldCPE(cpe): cpe = cpe.strip() if not cpe.startswith("cpe:/"): if not cpe.startswith("cpe:2.3:"): return False cpe = lib.cpe_conversion.cpe_fs_to_uri(cpe) return cpe def isURL(string): urlTypes = [re.escape(x) for x in ["http://", "https://", "www."]] return re.match("^(" + "|".join(urlTypes) + ")", string) def tk_compile(regexes): if type(regexes) not in [list, tuple]: regexes = [regexes] r = [] for rule in regexes: r.append(re.compile(rule)) return r
1,584
Python
.py
44
31.318182
99
0.637255
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,212
CVEs.py
cve-search_cve-search/lib/CVEs.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Minimal class to get the last entries from the CVE database. # # Ranking and CPE lookup are optional. # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2012-2018 Alexandre Dulaunoy - a@foo.be # Copyright (c) 2015-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com import itertools import os import sys from lib.DatabaseLayer import getCVE, sanitize from lib.cpe_conversion import split_cpe_name runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) class CveHandler(object): def __init__( self, collection="cves", rankinglookup=False, namelookup=False, capeclookup=False, via4lookup=False, subscorelookup=False, ): self.collectionname = collection self.rankinglookup = rankinglookup self.namelookup = namelookup self.capeclookup = capeclookup self.subscorelookup = subscorelookup self.via4lookup = via4lookup self.collection = collection def getcapec(self, cweid=None): from lib.DatabaseLayer import ( getCAPECFor, ) if cweid is None or not self.capeclookup: return False e = getCAPECFor(cweid) capec = [] for f in e: capec.append(f) return capec def getcpe(self, cpeid=None): from lib.DatabaseLayer import ( getCPE, getAlternativeCPE, ) if not self.namelookup: return cpeid e = getCPE(cpeid) if e is None: e = getAlternativeCPE(cpeid) if e is None: return cpeid if "id" in e: return e["title"] def getVIA4(self, cveid=None): from lib.DatabaseLayer import ( getVIA4, ) if not self.via4lookup: return cveid e = getVIA4(cveid) return e if e else cveid def getCveById(self, cveid): if cveid is None: return None return self.getcve(cveid) # This method can be used to standardize a mongo doc # after getting it from mongo def getCveFromMongoDbDoc(self, cve_doc): if cve_doc is None: return None cve_doc = sanitize(cve_doc) if "cwe" in cve_doc and self.capeclookup: if cve_doc["cwe"].lower() != "unknown": cve_doc["capec"] = self.getcapec(cweid=(cve_doc["cwe"].split("-")[1])) if "vulnerable_configuration" in cve_doc: vulconf = [] ranking = [] for conf in cve_doc["vulnerable_configuration"]: vulconf.append({"id": conf, "title": self.getcpe(cpeid=conf)}) if self.rankinglookup: rank = self.getranking(cpeid=conf) if rank and rank not in ranking: ranking.append(rank) cve_doc["vulnerable_configuration"] = vulconf # if self.rankinglookup and len(ranking) > 0: # e["ranking"] = ranking if self.via4lookup: f = self.getVIA4(cve_doc.get("id")) if isinstance(f, dict): cve_doc = dict(itertools.chain(cve_doc.items(), f.items())) return cve_doc def getcve(self, cveid=None): return ( None if cveid is None else self.getCveFromMongoDbDoc(getCVE(cveid, collection=self.collection)) ) def getranking(self, cpeid=None, loosy=True): from lib.DatabaseLayer import ( findRanking, ) if cpeid is None: return False result = False i = None if loosy: for x in split_cpe_name(cpeid): if x != "": i = findRanking(x, regex=True) if i is None: continue if "rank" in i: result = i["rank"] else: i = findRanking(cpeid, regex=True) if i is None: return result if "rank" in i: result = i["rank"] return result def get(self, limit=5, skip=0): from lib.DatabaseLayer import ( getCVEs, ) entries = [] for item in getCVEs(limit=limit, skip=skip, collection=self.collection)[ "results" ]: if not self.namelookup and not self.rankinglookup: entries.append(item) elif self.namelookup or self.rankinglookup: if "vulnerable_configuration" in item: vulconf = [] ranking = [] for conf in item["vulnerable_configuration"]: vulconf.append(self.getcpe(cpeid=conf)) if self.rankinglookup: rank = self.getranking(cpeid=conf) if rank and rank not in ranking: ranking.append(rank) item["vulnerable_configuration"] = vulconf if self.rankinglookup: item["ranking"] = ranking if "ranking" in item: if len(item["ranking"]) == 0: del item["ranking"] if "cwe" in item and self.capeclookup: if item["cwe"].lower() != "unknown": item["capec"] = self.getcapec(cweid=(item["cwe"].split("-")[1])) entries.append(item) return entries
5,686
Python
.py
158
24.563291
88
0.544446
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,213
Query.py
cve-search_cve-search/lib/Query.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Query tools # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2014-2018 Alexandre Dulaunoy - a@foo.be # Copyright (c) 2014-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com import os import sys import urllib.parse import requests runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) from lib.Toolkit import toStringFormattedCPE from lib.CVEs import CveHandler from lib.Config import Configuration from lib.cpe_conversion import split_cpe_name rankinglookup = True redisdb = Configuration.getRedisVendorConnection() SCAN_COUNT = 1000 def findranking(cpe=None, loosy=True): from lib.DatabaseLayer import findRanking i = None if cpe is None: return False result = False if loosy: for x in split_cpe_name(cpe): if x != "": i = findRanking(cpe, regex=True) if i is None: continue if "rank" in i: result = i["rank"] else: i = findRanking(cpe, regex=True) print(cpe) if i is None: return result if "rank" in i: result = i["rank"] return result def lookupcpe(cpeid=None): from lib.DatabaseLayer import getCPE e = getCPE(cpeid) if e is None: return cpeid if "id" in e: return e["title"] def apigetcve(api, cveid=None): if cveid is None: return False url = urllib.parse.urljoin(api, "api/cve/" + cveid) urltoget = urllib.parse.urljoin(url, cveid) with requests.Session() as session: r = session.get(urltoget) if r.status_code == 200: return r.text else: return False # Lastly added def qcvesForCPE(cpe, limit=0): from lib.DatabaseLayer import cvesForCPE cpe = toStringFormattedCPE(cpe) data = [] if cpe: cvesp = CveHandler( rankinglookup=False, namelookup=False, via4lookup=True, capeclookup=False ) r = cvesForCPE(cpe, limit=limit) for x in r["results"]: data.append(cvesp.getcve(x["id"])) return data def getBrowseList(vendor): result = {} if (vendor is None) or type(vendor) == list: v1 = redisdb.smembers("o") v2 = redisdb.smembers("a") v3 = redisdb.smembers("h") vendor = sorted(list(set(list(v1) + list(v2) + list(v3)))) cpe = None else: cpenum = redisdb.scard("v:" + vendor) if cpenum < 1: return None p = redisdb.smembers("v:" + vendor) cpe = sorted(list(p)) result["vendor"] = vendor result["product"] = cpe return result def getVersionsOfProduct(product): p = redisdb.smembers("p:" + product) return sorted(list(p)) def searchVendors(vendor_part): vendor_iterator = redisdb.scan_iter(f"v:*{vendor_part}*", count=SCAN_COUNT) vendor_list = [] for vendor in vendor_iterator: vendor_list.append(vendor.replace("v:", "")) return {"vendor": vendor_list} def searchProductsByVendor(vendor, product_part): product_iterator = redisdb.sscan_iter( f"v:{vendor}", f"*{product_part}*", count=SCAN_COUNT ) product_list = [] for product in product_iterator: product_list.append(product.replace("p:", "")) return {"product": product_list, "vendor": vendor} def searchVersionsByProduct(vendor, product, version_part): version_iterator = redisdb.sscan_iter( f"p:{product}", f"*{version_part}*", count=SCAN_COUNT ) version_list = list(version_iterator) return {"version": version_list, "product": product, "vendor": vendor}
3,751
Python
.py
115
26.530435
87
0.644068
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,214
Authentication.py
cve-search_cve-search/lib/Authentication.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Plugin manager # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2016-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com # Imports import datetime import importlib import logging import os import sys import uuid from abc import ABC, abstractmethod runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) from lib.DatabaseHandler import DatabaseHandler from lib.LogHandler import AppLogger from lib.Config import Configuration as conf from lib.Singleton import Singleton logging.setLoggerClass(AppLogger) # Constants UNREACHABLE = -1 WRONG_CREDS = 0 AUTHENTICATED = 1 class AuthenticationMethod(ABC): @abstractmethod def validateUser(self, user, pwd): raise NotImplementedError class AuthenticationHandler(metaclass=Singleton): def __init__(self, **kwargs): self.logger = logging.getLogger(__name__) self.methods = [] self._load_methods() self.api_sessions = {} self.dbh = DatabaseHandler() def _load_methods(self): self.methods = [] if not os.path.exists(conf.getAuthLoadSettings()): self.logger.warning("Could not find auth loader file!") return # Read and parse plugin file data = open(conf.getAuthLoadSettings(), "r").read() data = [ x.split(maxsplit=2) for x in data.splitlines() if not x.startswith("#") and x ] for x in [x for x in data if len(x) in [2, 3]]: try: x.extend([""] * (3 - len(x))) # add empty args if none exist method, authType, args = x if authType.lower() not in [ "required", "sufficient", ]: # Skip if authType not known continue # Create object args = {y.split("=")[0]: y.split("=")[1] for y in args.split()} i = importlib.import_module("lib.authenticationMethods.%s" % method) authMethod = getattr(i, method.split("/")[-1])(**args) # Add object to list self.methods.append((method, authType.lower(), authMethod)) self.logger.info("Loaded Auth Method {}".format(x[0])) except Exception as e: self.logger.error( "Failed to load Auth Method {}: -> {}".format(x[0], e) ) def isCVESearchUser(self, user): return self.dbh.connection.userExists(user) def validateUser(self, user, password): user_obj = self.dbh.connection.getUser(user) if not user_obj: return False # 'local_only' users bypass other auth methods. If the user is not, # we try the other auth methods first if not "local_only" in user_obj.keys() or user_obj["local_only"] is False: for name, authType, method in self.methods: try: result = method.validateUser(user, password) if result is UNREACHABLE: continue # Skip to next if result is AUTHENTICATED: return True # Successful if authType == "required" and result is WRONG_CREDS: return False if authType == "sufficient" and result is WRONG_CREDS: continue except Exception as e: self.logger.error( "Exception trying to authenticate user: {} -> {}".format( name, e ) ) # If we reach here, all methods (if any) failed to authenticate the user # so we check the user against the local database. return self.dbh.connection.verifyUser(user, password) def new_api_session(self, user): self.api_sessions[user] = (uuid.uuid4().hex, datetime.datetime.now()) return self.api_sessions[user][0] def get_api_session(self, user, extend=True): return self.api_sessions.get(user)
4,250
Python
.py
104
30.384615
87
0.581801
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,215
Plugins.py
cve-search_cve-search/lib/Plugins.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Plugin Classes # Classes for all plug-ins to be based on # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2016-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com class Plugin: def __init__(self): self.name = None self.uid = None self.requiresAuth = False self.loadstate = "default" # Get def getName(self): return self.name def getUID(self): return self.uid def getLoadState(self): return self.loadstate # Set def setUID(self, uid): self.uid = uid def setLoadState(self, state): self.loadstate = state # Don't override def isWebPlugin(self): return False # To override without returns def loadSettings(self, reader): pass def onDatabaseUpdate(self): pass # To override with returns def search(self, text, **args): pass class WebPlugin(Plugin): # Don't override def isWebPlugin(self): return True # To override with returns def getPage(self, **args): return (None, None) def getSubpage(self, page, **args): return (None, None) def getCVEActions(self, cve, **args): return [] def getFilters(self, **args): return [] def doFilter(self, filters, **args): return [] def cvePluginInfo(self, cve, **args): pass def mark(self, cve, **args): return (None, None) # To override without returns def onCVEAction(self, cve, action, **args): pass def onCVEOpen(self, cve, **args): pass
1,704
Python
.py
62
21.354839
87
0.623457
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,216
DatabaseHandler.py
cve-search_cve-search/lib/DatabaseHandler.py
from lib.ApiRequests import JSONApiRequest from lib.Config import Configuration from lib.DatabasePluginBase import DatabasePluginBase from lib.DatabasePlugins.config import DatabasePluginLoader class DatabaseHandler(object): def __init__(self): self.config = Configuration() database_plugin = self.config.readSetting( "Database", "PluginName", self.config.default["DatabasePluginName"] ) self.dbpluginloader = DatabasePluginLoader() fetched_plugin = self.dbpluginloader.load_plugin(database_plugin)() if isinstance(fetched_plugin, DatabasePluginBase): self.connection = fetched_plugin else: raise TypeError( "The provided plugin is not derived from the DatabasePluginBase class!" ) def handle_api_json_query(self, request): if not isinstance(request, JSONApiRequest): raise TypeError( "Wrong type received, expected JSONApiRequest but got: {}".format( type(request) ) ) results = request.process(self.connection) return results
1,164
Python
.py
27
33.37037
87
0.666962
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,217
LogHandler.py
cve-search_cve-search/lib/LogHandler.py
""" LogHandler.py ============= """ import logging import os import platform import sys from logging.config import dictConfig from logging.handlers import RotatingFileHandler import colors from lib.Config import Configuration class HostnameFilter(logging.Filter): hostname = platform.node() def filter(self, record): record.hostname = HostnameFilter.hostname return True class HelperLogger(logging.Logger): """ The HelperLogger is used by the application / gui as their logging class and *extends* the default python logger.logging class. This will separate the logging from the application / gui from that of the daemons. """ # Logging state variables for fault tolerance; reference as "static" with 'HelperLogger.variableName'. testedLogFile = False testedUpdateLogFile = False failedLogFile = False failedUpdateLogFile = False config = Configuration() logDict = { "version": 1, "formatters": { "sysLogFormatter": { "format": "%(asctime)s - %(name)-8s - %(levelname)-8s - %(message)s" }, "simpleFormatter": { "format": "%(asctime)s - %(name)-8s - %(levelname)-8s - %(message)s" }, }, "handlers": { "consoleHandler": { "class": "logging.StreamHandler", "level": "INFO", "stream": "ext://sys.stdout", "formatter": "simpleFormatter", } }, "root": {"level": "DEBUG", "handlers": ["consoleHandler"]}, } dictConfig(logDict) level_map = { "debug": "magenta", "info": "white", "warning": "yellow", "error": "red", "critical": "red", } def __init__(self, name, level=logging.NOTSET): super().__init__(name, level) def debug(self, msg, *args, **kwargs): """ Log ‘msg % args’ with severity ‘DEBUG’ and color *MAGENTA. To pass exception information, use the keyword argument exc_info with a true value, e.g. logger.debug(“Houston, we have a %s”, “thorny problem”, exc_info=1) :param msg: Message to log :type msg: str """ msg = colors.color("{}".format(msg), fg=HelperLogger.level_map["debug"]) return super(HelperLogger, self).debug(msg, *args, **kwargs) def info(self, msg, *args, **kwargs): """ Log ‘msg % args’ with severity ‘INFO’ and color *WHITE*. To pass exception information, use the keyword argument exc_info with a true value, e.g. logger.info(“Houston, we have a %s”, “interesting problem”, exc_info=1) :param msg: Message to log :type msg: str """ msg = colors.color("{}".format(msg), fg=HelperLogger.level_map["info"]) return super(HelperLogger, self).info(msg, *args, **kwargs) def warning(self, msg, *args, **kwargs): """ Log ‘msg % args’ with severity ‘WARNING’ and color *YELLOW*. To pass exception information, use the keyword argument exc_info with a true value, e.g. logger.warning(“Houston, we have a %s”, “bit of a problem”, exc_info=1) :param msg: Message to log :type msg: str """ msg = colors.color("{}".format(msg), fg=HelperLogger.level_map["warning"]) return super(HelperLogger, self).warning(msg, *args, **kwargs) def error(self, msg, *args, **kwargs): """ Log ‘msg % args’ with severity ‘ERROR’ and color *RED*. Store logged message to the database for dashboard alerting. To pass exception information, use the keyword argument exc_info with a true value, e.g. logger.error(“Houston, we have a %s”, “major problem”, exc_info=1) :param msg: Message to log :type msg: str """ msg = colors.color("{}".format(msg), fg=HelperLogger.level_map["error"]) return super(HelperLogger, self).error(msg, *args, **kwargs) def critical(self, msg, *args, **kwargs): """ Log ‘msg % args’ with severity ‘CRITICAL’ and color *RED*. Store logged message to the database for dashboard alerting. To pass exception information, use the keyword argument exc_info with a true value, e.g. logger.critical(“Houston, we have a %s”, “hell of a problem”, exc_info=1) :param msg: Message to log :type msg: str """ msg = colors.color("{}".format(msg), fg=HelperLogger.level_map["critical"]) return super(HelperLogger, self).critical(msg, *args, **kwargs) @staticmethod def testLogging(log): """ Static method for creating missing log directories and testing log operation. Returns True if logging is possible and False on any failure. :param log: Path to the log file to test/create. :type log: str (or os.PathLike object) """ logFile = os.path.realpath(log) logPath = os.path.dirname(logFile) try: if not os.path.exists(logPath): os.makedirs(logPath) with open(logFile, "a"): os.utime(logFile, None) except: print( "Warning! Could not write log to {}. Disabling temporarily.".format( logFile ) ) return False return True class AppLogger(HelperLogger): def __init__(self, name, level=logging.NOTSET): formatter = logging.Formatter( "%(asctime)s - %(name)-8s - %(levelname)-8s - %(message)s" ) root = logging.getLogger() root.setLevel(logging.DEBUG) root.handlers.clear() cli = logging.StreamHandler(stream=sys.stdout) cli.setFormatter(formatter) cli.setLevel(logging.INFO) root.addHandler(cli) super().__init__(name, level) if self.config.getLogging() and not HelperLogger.testedLogFile: if not HelperLogger.testLogging(self.config.getLogfile()): HelperLogger.failedLogFile = True HelperLogger.testedLogFile = True if self.config.getLogging() and not HelperLogger.failedLogFile: crf = RotatingFileHandler( filename=self.config.getLogfile(), maxBytes=self.config.getMaxLogSize(), backupCount=self.config.getBacklog(), ) crf.setLevel(logging.DEBUG) crf.setFormatter(formatter) self.addHandler(crf) # syslog_formatter = logging.Formatter( # "%(asctime)s [%(hostname)s] - %(name)-8s - %(levelname)-8s - %(message)s" # ) # # if self.config.SYSLOG_ENABLE: # syslog = SysLogHandler( # address=(self.config.SYSLOG_SERVER, int(self.config.SYSLOG_PORT)), # facility=SysLogHandler.LOG_LOCAL0, # ) # # syslog.setLevel(logging.DEBUG) # syslog.addFilter(HostnameFilter()) # syslog.setFormatter(syslog_formatter) # self.addHandler(syslog) class UpdateHandler(HelperLogger): def __init__(self, name, level=logging.NOTSET): super().__init__(name, level) formatter = logging.Formatter( "%(asctime)s - %(name)-8s - %(levelname)-8s - %(message)s" ) if self.config.getLogging() and not HelperLogger.testedUpdateLogFile: if not HelperLogger.testLogging(self.config.getUpdateLogFile()): HelperLogger.failedUpdateLogFile = True HelperLogger.testedUpdateLogFile = True if self.config.getLogging() and not HelperLogger.failedUpdateLogFile: crf = RotatingFileHandler( filename=self.config.getUpdateLogFile(), maxBytes=self.config.getMaxLogSize(), backupCount=self.config.getBacklog(), ) crf.setLevel(logging.DEBUG) crf.setFormatter(formatter) self.addHandler(crf)
8,187
Python
.py
193
32.533679
109
0.601376
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,218
DatabasePluginBase.py
cve-search_cve-search/lib/DatabasePluginBase.py
from abc import ABC, abstractmethod class DatabasePluginBase(ABC): """ The DatabasePluginBase is the base class of all database backend plugins supported by cve search. The default backend plugin is mongodb. If you wish to use a different backend you could provide your own plugin. Plugins should be placed within the lib.DatabasePlugins folder. Plugins should be a class derived from this class and the class name should end with 'Plugin' for it to be automatically picked up by the DatabasePluginLoader and presented to cve search. The name of the plugin should be defined in the 'PluginName' variable of the configuration.ini file and should be the same as the name of the file (minus the '.py') in which the plugin class resides. ****************************************************************************************************************** FOR Now only a small part of the API makes use of this plugin based database access all other endpoints and functionalities do not use these plugins yet ****************************************************************************************************************** """ def __init__(self): pass @abstractmethod def query_docs(self, **kwargs): """ Method used to perform a extended query against the database in order to fetch data. This method should accept: :param retrieve: Collection/table name where to retrieve the documents from :type retrieve: str :param dict_filter: A column filter based on a python dictionary :type dict_filter: dict :param sort: Field to sort on or list of tuples of field and direction; e.g. (for mongodb) [("field", pymongo.DESCENDING), ("field2", pymongo.ASCENDING)] :type sort: str or list :param limit: Can be used to limit the amount of returned results :type limit: int :param skip: Can be used to skip the first x records of the returned results :type skip: int :param query_filter: Python Dictionary to include fields to return in the query results (e.g.: {field1: 1, field2: 1}) :type query_filter: dict :param sort_dir: A general sorting direction; e.g. DESC for DESCENDING, ASC for ASCENDING :type sort_dir: str This method should return: :return: A list of dictionaries whith the data saved in the backend. Each dictionary represents a single row/document and the dictionary keys represent the fields/columns in the row/document :rtype: list """ raise NotImplementedError @abstractmethod def fetch_one(self, **kwargs): """ The fetch one method returns a single record based on the provided parameters. This method should accept: :param retrieve: Collection name where to retrieve the documents from :type retrieve: str :param dict_filter: A column filter based on a python dictionary :type dict_filter: dict :param query_filter: Dict with fields to exclude or include; e.g. {"hosts": 0} or {"hosts": 1} :type query_filter: dict This method should return: :return: Dictionary with items from database or None :rtype: dict or None """ raise NotImplementedError @abstractmethod def create_schema(self, **kwargs): raise NotImplementedError @abstractmethod def count(self, **kwargs): """ Method for retrieving a document count This method should accept: :param retrieve: Collection/table to retrieve the count from :type retrieve: str :param dict_filter: A column filter based on a python dictionary :type dict_filter: dict This method should return: :return: Count :rtype: int """ raise NotImplementedError @abstractmethod def datatables_data_columns_ordering(self, **kwargs): raise NotImplementedError @abstractmethod def datatables_data_filter(self, **kwargs): raise NotImplementedError @abstractmethod def datatables_data_order(self, **kwargs): raise NotImplementedError @abstractmethod def addUser(self, **kwargs): raise NotImplementedError @abstractmethod def changePassword(self, **kwargs): raise NotImplementedError @abstractmethod def verifyUser(self, **kwargs): raise NotImplementedError @abstractmethod def deleteUser(self, **kwargs): raise NotImplementedError @abstractmethod def setAdmin(self, **kwargs): raise NotImplementedError @abstractmethod def setLocalOnly(self, **kwargs): raise NotImplementedError @abstractmethod def isMasterAccount(self, **kwargs): raise NotImplementedError @abstractmethod def userExists(self, **kwargs): raise NotImplementedError @abstractmethod def isSingleMaster(self, **kwargs): raise NotImplementedError @abstractmethod def getUser(self, **kwargs): raise NotImplementedError
5,233
Python
.py
115
37.33913
119
0.651456
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,219
config.py
cve-search_cve-search/lib/DatabasePlugins/config.py
import glob import importlib from os.path import dirname, basename, isfile, join modules = glob.glob(join(dirname(__file__), "*.py")) all_plugins = [ basename(f)[:-3] for f in modules if isfile(f) and not f.endswith("__init__.py") and not f.endswith("config.py") ] class DatabasePluginNotFound(Exception): pass class DatabasePluginLoader(object): def __init__(self): mods = [ {plugin: importlib.import_module(f"lib.DatabasePlugins.{plugin}")} for plugin in all_plugins if not plugin.startswith("_") and not plugin.startswith("DatabasePluginLoader") and not plugin.startswith("DatabasePluginNotFound") ] plugins = {} for each in mods: for key, val in each.items(): plugin_class = [plug for plug in dir(val) if plug.endswith("Plugin")] plugins[key] = getattr(val, plugin_class[0]) self.database_choises = dict(plugins) def load_plugin(self, name): """ Method to load the requested plugin :param name: Name of the database plugin to load :type name: str :return: Plugin class :rtype: class """ try: plugin = self.database_choises[name] return plugin except KeyError: raise DatabasePluginNotFound("Cannot find the requested plugin!")
1,416
Python
.py
39
27.974359
85
0.615947
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,220
mongodb.py
cve-search_cve-search/lib/DatabasePlugins/mongodb.py
import re import sre_constants import urllib from collections import defaultdict import bson import pymongo from pymongo import DESCENDING, ASCENDING from pymongo.collection import Collection from werkzeug.security import generate_password_hash, check_password_hash from lib.Config import Configuration from lib.DatabaseLayer import sanitize from lib.DatabasePluginBase import DatabasePluginBase config = Configuration() DNSSRV = config.readSetting("Database", "DnsSrvRecord", config.default["mongoSrv"]) HOST = config.readSetting("Database", "Host", config.default["mongoHost"]) PORT = config.readSetting("Database", "Port", config.default["mongoPort"]) AUTH = config.readSetting("Database", "AuthDB", config.default["mongoAuth"]) DATABASE = config.getMongoDB() USERNAME = urllib.parse.quote( config.readSetting("Database", "Username", config.default["mongoUsername"]) ) PASSWORD = urllib.parse.quote( config.readSetting("Database", "Password", config.default["mongoPassword"]) ) class MongoPlugin(DatabasePluginBase): def __init__(self): """ Custom MongoDBPlugin """ super().__init__() if USERNAME and PASSWORD and DNSSRV is True: mongoURI = "mongodb+srv://{username}:{password}@{host}/{db}?authSource={auth}&retryWrites=true&w=majority".format( username=USERNAME, password=PASSWORD, host=HOST, db=DATABASE, auth=AUTH ) elif USERNAME and PASSWORD: mongoURI = "mongodb://{username}:{password}@{host}:{port}/{db}?authSource={auth}".format( username=USERNAME, password=PASSWORD, host=HOST, port=PORT, db=DATABASE, auth=AUTH, ) else: mongoURI = "mongodb://{host}:{port}/{db}".format( host=HOST, port=PORT, db=DATABASE ) connect = pymongo.MongoClient(mongoURI, connect=False) self.connection = connect[DATABASE] self.user_store = connect[DATABASE]["mgmt_users"] for each in self.connection.list_collection_names(): setattr( self, f"store_{each}", Collection(database=self.connection, name=each) ) def create_schema(self, **kwargs): pass def count(self, retrieve, dict_filter={}): """ Method for retrieving a document count :param retrieve: Collection to retrieve the count from :type retrieve: str :param dict_filter: dict representing a filter see pyMongo doc :type dict_filter: dict :return: Count :rtype: int """ if isinstance(dict_filter, dict): return getattr(self, "store_{}".format(retrieve)).count_documents( filter=dict_filter ) else: return getattr(self, "store_{}".format(retrieve)).count_documents( filter={"$and": dict_filter} ) def query_docs( self, retrieve=None, dict_filter={}, sort=None, limit=None, skip=0, query_filter=None, sort_dir="DESC", id_to_string=True, ): """ Method used to perform a extended query against the database in order to fetch documents. :param retrieve: Collection name where to retrieve the documents from :type retrieve: str :param dict_filter: dict representing a filter see pyMongo doc :type dict_filter: dict :param sort: Field to sort on or list of tuples of field and direction [("field", pymongo.DESCENDING), ("field2", pymongo.DESCENDING)] :type sort: list :param limit: Can be used to limit the amount of returned results :type limit: int :param skip: Can be used to skip the first x records of the returned results :type skip: int :param query_filter: Dict to include fields to return in the query results (e.g.: {field1: 1, field2: 1}) :type query_filter: dict :param sort_dir: DESC (default) for DESCENDING, ASC for ASCENDING :type sort_dir: str :param id_to_string: Whether to convert mongodb '_id' from an ObjectId to a string :type id_to_string: bool :return: List of documents saved in the backend :rtype: list """ documentlist = [] if sort is not None: if isinstance(sort, str): if sort_dir == "DESC": if limit is not None: resultset = ( getattr(self, "store_{}".format(retrieve)) .find(dict_filter, {"json": 0}) .sort(sort, DESCENDING) .limit(limit) .skip(skip) ) else: resultset = ( getattr(self, "store_{}".format(retrieve)) .find(dict_filter, {"json": 0}) .sort(sort, DESCENDING) .skip(skip) ) elif sort_dir == "ASC": if limit is not None: resultset = ( getattr(self, "store_{}".format(retrieve)) .find(dict_filter, {"json": 0}) .sort(sort, ASCENDING) .limit(limit) .skip(skip) ) else: resultset = ( getattr(self, "store_{}".format(retrieve)) .find(dict_filter, {"json": 0}) .sort(sort, ASCENDING) .skip(skip) ) if isinstance(sort, list): if limit is not None: resultset = ( getattr(self, "store_{}".format(retrieve)) .find(dict_filter, {"json": 0}) .sort(sort) .limit(limit) .skip(skip) ) else: resultset = ( getattr(self, "store_{}".format(retrieve)) .find(dict_filter, {"json": 0}) .sort(sort) .skip(skip) ) else: if limit is not None: resultset = ( getattr(self, "store_{}".format(retrieve)) .find(dict_filter, {"json": 0}) .limit(limit) .skip(skip) ) else: resultset = ( getattr(self, "store_{}".format(retrieve)) .find(dict_filter, {"json": 0}) .skip(skip) ) if isinstance(sort_dir, str): if sort_dir.startswith("DESC"): sort_dir = DESCENDING elif sort_dir.startswith("ASC"): sort_dir = ASCENDING else: sort_dir = DESCENDING else: sort_dir = DESCENDING if query_filter is not None: if sort is not None: if isinstance(sort, str): if limit is not None: resultset = ( getattr(self, "store_{}".format(retrieve)) .find(dict_filter, query_filter) .sort(sort, sort_dir) .limit(limit) .skip(skip) ) else: resultset = ( getattr(self, "store_{}".format(retrieve)) .find(dict_filter, query_filter) .sort(sort, sort_dir) .skip(skip) ) if isinstance(sort, list): if limit is not None: resultset = ( getattr(self, "store_{}".format(retrieve)) .find(dict_filter, query_filter) .sort(sort) .limit(limit) .skip(skip) ) else: resultset = ( getattr(self, "store_{}".format(retrieve)) .find(dict_filter, query_filter) .sort(sort) .skip(skip) ) else: if limit is not None: resultset = ( getattr(self, "store_{}".format(retrieve)) .find(dict_filter, query_filter) .limit(limit) .skip(skip) ) else: resultset = ( getattr(self, "store_{}".format(retrieve)) .find(dict_filter, query_filter) .skip(skip) ) if id_to_string: for doc in resultset: doc["_id"] = str(doc["_id"]) documentlist.append(doc) else: for doc in resultset: documentlist.append(doc) return documentlist def fetch_one( self, retrieve=None, dict_filter={}, query_filter=None, id_to_string=True ): """ The fetch one method wraps the original find_one method from pyMongo and turns the _id into a string. :param retrieve: Collection name where to retrieve the documents from :type retrieve: str :param dict_filter: dict representing a filter see pyMongo doc :type dict_filter: dict :param query_filter: Dict with fields to exclude or include; e.g. {"hosts": 0} or {"hosts": 1} :type query_filter: dict :param id_to_string: Whether to convert mongodb '_id' from an ObjectId to a string :type id_to_string: bool :return: Dict with items from database or None :rtype: dict or None """ if "_id" in dict_filter: if isinstance(dict_filter["_id"], str): dict_filter["_id"] = bson.objectid.ObjectId(dict_filter["_id"]) if query_filter is not None: result = getattr(self, "store_{}".format(retrieve)).find_one( dict_filter, query_filter ) else: result = getattr(self, "store_{}".format(retrieve)).find_one(dict_filter) if result is not None: if id_to_string: result["_id"] = str(result["_id"]) return result def datatables_data_columns_ordering(self, request_values): """ Method responsible for retrieving the column and order details from the DataTables request values :param request_values: :type request_values: :return: 2 Dictionaries namely: the column details and order details :rtype: defaultdict, defaultdict """ col = defaultdict(lambda: defaultdict(lambda: defaultdict(dict))) order = defaultdict(lambda: defaultdict(dict)) col_regex = re.compile(r"columns\[(\d*)\]\[(\w*)\](?:\[(\w*)\])?") order_regex = re.compile(r"order\[(\d*)\]\[(\w*)\]") for each in sorted(request_values.keys()): check_col_match = col_regex.match(each) check_order_match = order_regex.match(each) if check_col_match: if check_col_match.group(2) == "search": try: col[check_col_match.group(1)][check_col_match.group(2)][ check_col_match.group(3) ] = int(request_values[each]) except ValueError: col[check_col_match.group(1)][check_col_match.group(2)][ check_col_match.group(3) ] = request_values[each] else: col[check_col_match.group(1)][check_col_match.group(2)] = ( request_values[each] ) if check_order_match: order[check_order_match.group(1)][check_order_match.group(2)] = ( request_values[each] ) return col, order def datatables_data_filter(self, request_values, columns, additional_filters): """ Method responsible for retrieving the filter values entered in the search box of the DataTables. :param request_values: :type request_values: :param columns: :type columns: :param additional_filters: :type additional_filters: :return: Prepared filter based on filterable columns and retrieved search value :rtype: dict """ docfilter = defaultdict(list) search_val = request_values["search[value]"] if search_val != "": try: regex = re.compile(search_val, re.IGNORECASE) # get list with searchable columns column_search_list = [ columns[i]["data"] for i in columns if columns[i]["searchable"] ] for each in column_search_list: docfilter["$or"].append({each: {"$regex": regex}}) except sre_constants.error: pass if additional_filters is not None: docfilter["$and"] = additional_filters # create an additional column filter with entries in the columns[x]['search']['value'] colfilter = { columns[key]["data"]: columns[key]["search"]["value"] for (key, value) in columns.items() if ( columns[key]["search"]["value"] != "" and columns[key]["search"]["regex"] == "false" ) } colregexfilter = { columns[key]["data"]: {"$regex": columns[key]["search"]["value"]} for (key, value) in columns.items() if ( columns[key]["search"]["value"] != "" and columns[key]["search"]["regex"] == "true" ) } if len(colfilter) != 0: docfilter["$and"].append(colfilter) if len(colregexfilter) != 0: docfilter["$and"].append(colregexfilter) return docfilter def datatables_data_order(self, ordering, columns): """ Method responsible for setting up the column sorting. :param ordering: :type ordering: :param columns: :type columns: :return: list with sorting instructions :rtype: list """ sort = [] for each in ordering: if ordering[each]["dir"] == "asc": sort.append( (columns[ordering[each]["column"]]["data"], pymongo.ASCENDING) ) else: sort.append( (columns[ordering[each]["column"]]["data"], pymongo.DESCENDING) ) return sort def addUser(self, user, pwd, admin=False, localOnly=False): hashed = generate_password_hash(pwd, method="pbkdf2:sha512") entry = {"username": user, "password": hashed} if admin: entry["master"] = True if localOnly: entry["local_only"] = True self.user_store.insert(entry) def changePassword(self, user, pwd): hashed = generate_password_hash(pwd, method="pbkdf2:sha512") self.user_store.update({"username": user}, {"$set": {"password": hashed}}) def verifyUser(self, user, pwd): person = self.getUser(user) return person and check_password_hash(person["password"], pwd) def deleteUser(self, user): self.user_store.remove({"username": user}) def setAdmin(self, user, admin=True): if admin: self.user_store.update({"username": user}, {"$set": {"master": True}}) else: self.user_store.update({"username": user}, {"$unset": {"master": ""}}) def setLocalOnly(self, user, localOnly=True): if localOnly: self.user_store.update({"username": user}, {"$set": {"local_only": True}}) else: self.user_store.update({"username": user}, {"$unset": {"local_only": ""}}) def isMasterAccount(self, user): return ( False if self.user_store.find({"username": user, "master": True}).count() == 0 else True ) def userExists(self, user): return ( True if self.user_store.count_documents({"username": user}) > 0 else False ) def isSingleMaster(self, user): return ( True if self.user_store.count_documents( {"username": {"$ne": user}, "master": True} ) > 0 else False ) def getUser(self, user): return sanitize(self.user_store.find_one({"username": user}))
17,445
Python
.py
417
27.57554
126
0.507807
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,221
db_updater.py
cve-search_cve-search/sbin/db_updater.py
#!/usr/bin/env python3 # # Updater script of CVE/CPE database # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2012-2019 Alexandre Dulaunoy - a@foo.be # Copyright (c) 2014-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com import argparse import logging import os import shlex import subprocess import sys import time runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) from lib.Config import Configuration # pass configuration to CveXplore Configuration.setCveXploreEnv() from CveXplore import CveXplore from lib.LogHandler import UpdateHandler from lib.Sources_process import ( CPERedisBrowser, ) from lib.DatabaseLayer import getSize, dropCollection, getTableNames logging.setLoggerClass(UpdateHandler) logger = logging.getLogger("DBUpdater") def nbelement(collection=None): if collection is None or collection == "cve": collection = "cves" return getSize(collection) def dropcollection(collection=None): if collection is None: return False if collection == "cve": collection = "cves" ret = dropCollection(collection) return ret def main(args): cvex = CveXplore() # Repopulation if args.force: logger.info("==========================") logger.info("Repopulate") logger.info(time.strftime("%a %d %B %Y %H:%M", time.gmtime())) logger.info("==========================") to_drop = ["cpeother", "mgmt_whitelist", "mgmt_blacklist", "info", "schema"] for each in to_drop: logger.info(f"Dropping metadata: {each}") dropcollection(each) if args.loop and args.days == 0: logger.info( "Drop collections (-f, --force) and running in loop (-l, --loop) used together; only dropping on the first iteration." ) logger.info("Starting initial import...") cvex.database.initialize() # Get sources from arguments or configuration and compare with sources provided by CveXplore update_sources = [] ignored_sources = [] if len(args.sources) > 0: logger.info( f'Using manually overridden sources instead of configured: {", ".join(args.sources)}' ) for source_available in cvex.database.sources: if source_available["name"] in args.sources: update_sources.append(source_available["name"]) elif len(args.sources) == 0 and Configuration.includesFeed( source_available["name"] ): update_sources.append(source_available["name"]) else: ignored_sources.append(source_available["name"]) if len(ignored_sources) > 0: logger.info( f'Ignored available CveXplore sources: {", ".join(ignored_sources)}' ) if len(args.sources) > 0: unavailable_sources = [i for i in args.sources if i not in update_sources] if len(unavailable_sources) > 0: logger.warning( f'Sources unavailable in CveXplore: {", ".join(unavailable_sources)}' ) if len(update_sources) == 0: logger.error(f"None of the sources available in CveXplore.") return 1 # Update sources handled by CveXplore loop = True loop_count = 0 while loop: if args.loop and args.days > 0: logger.warning( f"Loop (-l, --loop) not supported with manual days (-d, --days); only running once" ) if not args.loop or args.days > 0: loop = False else: loop_count += 1 logger.info("==========================") if args.minimal: redis_info = " ; minimal import without redis-cache-cpe source" elif args.cache: redis_info = " ; CPE redis cache enabled" else: redis_info = "" if args.days > 0: days_info = f" (manual interval of {str(args.days)} days)" loop_info = "" # loop not supported with manual days else: days_info = "" if args.loop: loop_info = f" (loop #{loop_count})" else: loop_info = "" logger.info( f'Update [{", ".join(update_sources)}]{redis_info}{loop_info}{days_info}' ) logger.info(time.strftime("%a %d %B %Y %H:%M", time.gmtime())) logger.info("==========================") if args.cache and args.minimal: logger.warning( f"CPE cache enabled (-c, --cache) does not do anything when " f"minimal import without redis-cache-cpe source (-m, --minimal) is used" ) cvex.database.update(update_source=update_sources, manual_days=args.days) # Update sources other than CveXplore newelement = 0 for source in sources: # Drop collections only if this was the first iteration of a repopulation if args.force and source["name"] != "redis-cache-cpe" and loop_count < 2: logger.info("Repopulation; dropping collection: " + source["name"]) if dropcollection(collection=source["name"]): logger.info(f"{source['name']} dropped") else: logger.info(f"{source['name']} did not exist") if ( not Configuration.includesFeed(source["name"]) and source["name"] != "redis-cache-cpe" ): logger.info(f"Skipping non-configured source: {source['name']}") continue if source["name"] == "cpeother": if "cpeother" not in getTableNames(): continue if source["name"] != "redis-cache-cpe": logger.info("Starting " + source["name"]) before = nbelement(collection=source["name"]) if isinstance(source["updater"], str): subprocess.Popen((shlex.split(source["updater"]))).wait() else: up = source["updater"]() up.update() after = nbelement(collection=source["name"]) message = ( source["name"] + " has " + str(after) + " elements (" + str(after - before) + " update)" ) newelement = str(after - before) logger.info(message) elif args.cache is True and source["name"] == "redis-cache-cpe": logger.info("Starting " + source["name"]) up = source["updater"]() up.update() logger.info(source["name"] + " updated") if args.index and int(newelement) > 0: logger.info("Indexing new cves entries in the fulltext indexer...") subprocess.Popen( ( shlex.split( "{} {} {}".format( sys.executable, os.path.join(runPath, "db_fulltext.py"), "-v -l " + newelement, ) ) ) ).wait() if args.loop and args.days == 0: logger.info("Sleeping 1 hour...") time.sleep(3600) if __name__ == "__main__": sources = [ { "name": "cpeother", "updater": "{} {}".format( sys.executable, os.path.join(runPath, "db_mgmt_cpe_other_dictionary.py") ), }, ] argParser = argparse.ArgumentParser(description="Database updater for cve-search") argParser.add_argument( "-s", "--sources", nargs="*", metavar="SOURCE", help="Sources to be updated if available in CveXplore. Defaults to all sources available & configured.", default=[], ) argParser.add_argument( "-i", "--index", action="store_true", help="Indexing new CVE entries in the fulltext indexer", default=False, ) argParser.add_argument( "-l", "--loop", action="store_true", help="Running at regular interval; waits 1 hour (disabled with -d, --days)", default=False, ) argParser.add_argument( "-f", "--force", action="store_true", help="Drop collections and force initial import (only on first iteration with -l, --loop)", default=False, ) argParser.add_argument( "-d", "--days", type=int, choices=range(1, 121), metavar="1..120", help="Set update interval (1-120 days) manually for NVD API (CPE, CVE)", default=0, # not manually set; updates CPE & CVE since last update ) argParser.add_argument( "-c", "--cache", action="store_true", help="Enable CPE redis cache (unless -m, --minimal is set)", default=False, ) argParser.add_argument( "-m", "--minimal", action="store_true", help="Minimal import without redis-cache-cpe source (disables CPE redis cache)", default=False, ) argParser.add_argument( "-v", action="store_true", help="Dummy option for backwards compatibility" ) args = argParser.parse_args() if not args.minimal: sources.extend( [ {"name": "redis-cache-cpe", "updater": CPERedisBrowser}, ] ) main(args)
9,686
Python
.py
257
27.494163
134
0.553568
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,222
db_mgmt_create_index.py
cve-search_cve-search/sbin/db_mgmt_create_index.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Script to check and ensure that the recommended index are created as recommended. # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2014 psychedelys # Copyright (c) 2015-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com # Imports import logging import os import sys from lib.Config import Configuration # pass configuration to CveXplore Configuration.setCveXploreEnv() from CveXplore.database.maintenance.Sources_process import DatabaseIndexer runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) from lib.LogHandler import UpdateHandler logging.setLoggerClass(UpdateHandler) if __name__ == "__main__": di = DatabaseIndexer() di.create_indexes()
829
Python
.py
24
32.833333
87
0.777638
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,223
db_fulltext.py
cve-search_cve-search/sbin/db_fulltext.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Fulltext indexer for the MongoDB CVE collection. # # The fulltext indexer is relying on Whoosh. # # The indexing is done by enumerating all items from # the MongoDB CVE collection and indexing the summary text of each # CVE. The Path of each document is the CVE-ID. # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2012-2018 Alexandre Dulaunoy - a@foo.be # Copyright (c) 2015-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com # Imports import argparse import logging import os import sys from tqdm import tqdm runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) from lib.LogHandler import UpdateHandler from lib.DatabaseLayer import getCVE, getCVEIDs from lib.Config import Configuration from lib.CVEs import CveHandler from whoosh.index import create_in, exists_in, open_dir from whoosh.fields import Schema, TEXT, ID logging.setLoggerClass(UpdateHandler) logger = logging.getLogger("DBFulltext") argParser = argparse.ArgumentParser( description="Fulltext indexer for the MongoDB CVE collection" ) argParser.add_argument("-v", action="store_true", default=False, help="Verbose logging") argParser.add_argument( "-l", default=5, help="Number of last entries to index (Default: 5) - 0 to index all documents", ) argParser.add_argument( "-n", action="store_true", default=False, help="lookup complete cpe (Common Platform Enumeration) name for vulnerable configuration to add in the index", ) args = argParser.parse_args() c = CveHandler(namelookup=args.n) indexpath = Configuration.getIndexdir() schema = Schema( title=TEXT(stored=True), path=ID(stored=True, unique=True), content=TEXT ) if not os.path.exists(indexpath): os.mkdir(indexpath) if not exists_in(indexpath): ix = create_in(indexpath, schema) else: ix = open_dir(indexpath) def dumpallcveid(entry=None): return getCVEIDs if not entry else getCVEIDs(int(entry)) def getcve(cveid=None): if cveid is None: return False return getCVE(cveid) for cveid in tqdm(dumpallcveid(entry=args.l), desc="Processing"): try: writer = ix.writer() except: logger.error("Index is locked. Another db_fulltext process running?") sys.exit(1) item = getcve(cveid=cveid) title = item["summary"][0:70] if args.n: for v in item["vulnerable_configuration"]: cpe = c.getcpe(cpeid=v).strip("\n") item["summary"] += " " + cpe if args.v: logger.debug("Indexing CVE-ID " + str(cveid) + " " + title) writer.update_document(title=title, path=cveid, content=item["summary"]) writer.commit()
2,761
Python
.py
80
31.2375
115
0.730755
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,224
db_mgmt_cpe_other_dictionary.py
cve-search_cve-search/sbin/db_mgmt_cpe_other_dictionary.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Import script of cpe (Common Platform Enumeration) definition # into a collection used for human readable lookup of product name. # This is locating the cpe used inside the cve, but only the cpe # not present inside the cpe official dictionary. # # Exemple: # CVE-2014-5446 -> cpe:/a:zohocorp:manageengine_netflow_analyzer:.* # but 'cpe:/a:zohocorp:manageengine_netflow_analyzer' is not in the # cpe official dictionary. # # Imported in cvedb in the collection named cpeother. # # The format of the collection is the following # # { "_id" : ObjectId("50a2739eae24ac2274eae7c0"), # "id" : "cpe:/a:zohocorp:manageengine_netflow_analyzer:10.2", # "title" : "cpe:/a:zohocorp:manageengine_netflow_analyzer:10.2" # } # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2014 psychedelys # Copyright (c) 2014-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com # Imports import os import sys import urllib from tqdm import tqdm runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) from lib.DatabaseLayer import ( getLastModified, getCVEsNewerThan, getCVEs, getAlternativeCPE, getCPE, cpeotherBulkInsert, setColUpdate, ) # get dates icve = getLastModified("cves") icpeo = getLastModified("cpeother") # check modification date date = False if icve is not None and icpeo is not None: # Go check date if icve >= icpeo: print("Not modified") sys.exit(0) else: date = True # only get collection of new CVE's collections = [] if date: collections = getCVEsNewerThan(icve)["results"] else: collections = getCVEs()["results"] # check cpes for cves and parse and store missing cpes in cpeother batch = [] # skip on empty collections col = list(collections) if not col: print("Empty collections, import skipped") sys.exit(2) for item in tqdm(col): for cpeentry in item["vulnerable_configuration"]: checkdup = getAlternativeCPE(cpeentry) if checkdup and len(checkdup) <= 0: entry = getCPE(cpeentry) if entry and len(entry.count) <= 0: title = cpeentry title = title[10:] title = title.replace(":-:", " ", 10) title = title.replace(":", " ", 10) title = title.replace("_", " ", 10) title = urllib.parse.unquote_plus(title) title = title.title() batch.append({"id": cpeentry, "title": title}) if len(batch) != 0: cpeotherBulkInsert(batch) # update database info after successful program-run setColUpdate("cpeother", icve)
2,747
Python
.py
85
28.176471
87
0.680498
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,225
db_ranking.py
cve-search_cve-search/sbin/db_ranking.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Import ranking values into the ranking collection. # # A cpe regex is use to match vulnerable configuration # and a ranking value is assigned per a group name. # # The idea is to set a specific weight for a vulnerability # when it's of a specific interest of a group/dept/organization # within your infrastructure. This can be also used to send # notification when you have an urgent vulnerability that need # to be worked on. # # The format of the collection is the following # # { "_id" : ObjectId("50b1f33e597549f61b2a259b"), "cpe" : "google:chrome", "rank" : [ { "circl" : 3, "other" : 3 } ] } # { "_id" : ObjectId("50b1fd79597549f61b2a259f"), "cpe" : "cisco", "rank" : [ { "circl" : 2 } ] } # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2012-2018 Alexandre Dulaunoy - a@foo.be # Copyright (c) 2015-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com import argparse import os import sys runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) from lib.DatabaseLayer import addRanking, findRanking, removeRanking from lib.cpe_conversion import split_cpe_name def add(cpe=None, key=None, rank=1): if cpe is None or key is None: return False return addRanking(cpe, key, rank) def findranking(cpe=None, loosy=True): if cpe is None: return False result = False i = None if loosy: for x in split_cpe_name(cpe): if x != "": i = findRanking(x, regex=True) if i is None: continue if "rank" in i: result = i["rank"] else: i = findRanking(cpe, regex=True) print(cpe) if i is None: return result if "rank" in i: result = i["rank"] return result def removeranking(cpe=None): if cpe is None or cpe == "": return False return removeRanking(cpe) def listranking(format="json"): ranks = [] for x in findRanking(): if format == "json": ranks.append(x) else: ranks.append(x["cpe"] + " " + str(x["rank"])) return ranks argParser = argparse.ArgumentParser( description="Ranking database management for cve-search", epilog="You can add a specific cpe to rank: 'db_ranking.py -c oracle:java -g mycompany -r 4'\n and then lookup " "for 'db_ranking.py -f java'\n Rankings encoded are used to enhance the output of the other cve-search " "query tools.\n", ) argParser.add_argument("-c", type=str, help="CPE name to add (e.g. google:chrome)") argParser.add_argument("-g", type=str, help="Name of the organization (e.g. mycompany)") argParser.add_argument( "-r", type=int, default=1, help="Ranking value (integer) default value is 1" ) argParser.add_argument("-f", type=str, help="Find ranking based on a CPE name regexp") argParser.add_argument("-l", action="store_true", help="List all ranking") argParser.add_argument( "-d", type=str, default=None, help="Remove ranking based on a CPE name regexp" ) args = argParser.parse_args() if args.c is not None and args.g is not None: add(cpe=args.c, key=args.g, rank=args.r) elif args.f is not None: print(findranking(cpe=args.f)) elif args.l: print(listranking()) elif args.d: print(removeranking(cpe=args.d)) else: argParser.print_help()
3,449
Python
.py
94
32.223404
118
0.670962
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,226
db_notification.py
cve-search_cve-search/sbin/db_notification.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Notification database # includes the user who will receive a notification # when a new CVE is published and matching their monitored CPE # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2014-2018 Alexandre Dulaunoy - a@foo.be # Copyright (c) 2015-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com # Imports import os import sys runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) import argparse import lib.DatabaseLayer as dbLayer from lib.Config import Configuration argParser = argparse.ArgumentParser( description="Notification database management for cve-search", epilog="" ) argParser.add_argument( "-c", action="append", help="CPE name(s) to add (e.g. google:chrome)" ) argParser.add_argument("-g", type=str, help="Name of the organization (e.g. mycompany)") argParser.add_argument( "-d", action="append", help="Destination(s) of matching CPE (mailto:foo@bar.com)" ) argParser.add_argument( "-a", action="store_true", default=False, help="Add a notification entry" ) argParser.add_argument( "-r", action="store_true", default=False, help="Remove a notification entry" ) argParser.add_argument("-v", action="store_true", default=False, help="Verbose logging") argParser.add_argument( "-n", action="store_true", default=False, help="Run notification" ) argParser.add_argument("-f", action="store_true", default=False, help="Flush state") argParser.add_argument( "-l", action="store_true", default=False, help="List notification entries" ) args = argParser.parse_args() def checkreq(): if args.c is None: print("You need at least one cpe or partial cpe entry (-c) \n") argParser.print_help() exit(1) if args.g is None: print("Organization is missing (-g) \n") argParser.print_help() exit(1) def searchcve(cpe=None): if cpe is None: return False cve = dbLayer.cvesForCPE(cpe) return cve def updatestate(org=None, cve=None): if cve is None or org is None: return False for c in cve: r.sadd("s:" + org, c) def sendnotification(org=None, cve=None): if org is None or cve is None: return False for destination in r.smembers("d:" + org): for c in cve: print("notification of " + c + " to " + destination) # Redis db 10 (cpe) # Redis db 11 (notification) # Set of notification for an organization set(d:orgname) -> notification destination # Set of cpe value for an organization set(c:orgname) -> cpe values # Set of organizations set(orgs) -> organisations # Set of state notification set(s:orgs) -> CVEs r = Configuration.getRedisNotificationsConnection() if args.a and args.r and args.n and args.f and args.l: argParser.print_help() exit(1) if args.a: checkreq() if not r.sismember("orgs", args.g): if args.v: print("Organization " + args.g + " added.") r.sadd("orgs", args.g) for cpe in args.c: r.sadd("c:" + args.g, cpe) if args.v: print(cpe + " added") if not r.scard("d:" + args.g): if args.g: for destination in args.d: r.sadd("d:" + args.g, destination) else: print( "destination missing for " + args.g + " you need at least one destination -d" ) exit(1) elif args.r: checkreq() for cpe in args.c: r.srem("c:" + args.g, cpe) if args.v: print(cpe + " removed") if r.scard("c:" + args.g) < 1: r.srem("orgs", args.g) if args.v: print("org " + args.g + " removed") elif args.n: for org in r.smembers("orgs"): if args.v: print("Notification for " + org) knowncve = set() for cpe in r.smembers("c:" + org): if args.v: print("CPE " + cpe) for cve in searchcve(cpe=cpe)["results"]: knowncve.add(cve["id"]) if r.exists("s:" + org): x = r.smembers("s:" + org) diff = knowncve.difference(x) if diff: sendnotification(org=org, cve=diff) updatestate(org=org, cve=knowncve) elif args.f: for org in r.smembers("orgs"): r.delete("s:" + org) if args.v: print("State for " + org + " deleted") elif args.l: for org in r.smembers("orgs"): print(org) for cpe in r.smembers("c:" + org): print(" " + cpe) for destination in r.smembers("d:" + org): print("->" + destination) else: argParser.print_help()
4,770
Python
.py
140
27.935714
88
0.619813
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,227
db_whitelist.py
cve-search_cve-search/sbin/db_whitelist.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Whitelist feature to mark CVE's for CPE's of personal interest # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2014-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com # Imports # make sure these modules are available on your system import os import sys runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) import argparse from lib.cpelist import CPEList # parse command line arguments argparser = argparse.ArgumentParser( description="populate/update the whitelist used in webviews" ) argparser.add_argument( "-a", metavar="CPE", nargs="*", help="Add one or more CPE to the whitelist" ) argparser.add_argument( "-A", action="append", metavar="file", help="Read a file of CPEs and add them to the whitelist", ) argparser.add_argument( "-r", metavar="CPE", nargs="*", help="Remove one or more CPE from the whitelist" ) argparser.add_argument( "-R", action="append", metavar="file", help="Read a file of CPEs and remove them from the whitelist", ) argparser.add_argument( "-t", metavar="type", default="cpe", help="Type of item to blacklist. Default: CPE" ) argparser.add_argument("-i", metavar="file", help="Import whitelist from file") argparser.add_argument("-e", metavar="file", help="Export whitelist to file") argparser.add_argument("-d", action="store_true", help="Drop the whitelist") argparser.add_argument("-f", action="store_true", help="Force") argparser.add_argument("-v", action="store_true", help="Verbose") args = argparser.parse_args() # Variables collection = "whitelist" def importWhitelist(importFile): oList = CPEList(collection, args) return oList.importList(importFile) def exportWhitelist(exportFile=None): oList = CPEList(collection, args) return oList.exportList(exportFile) def dropWhitelist(): oList = CPEList(collection, args) return oList.dropCollection() def countWhitelist(): oList = CPEList(collection, args) return oList.countItems() def checkWhitelist(cpe): oList = CPEList(collection, args) amount = oList.check(cpe) return amount def insertWhitelist(cpe, cpeType, comments=None): oList = CPEList(collection, args) return oList.insert(cpe, cpeType, comments) def removeWhitelist(cpe): oList = CPEList(collection, args) return oList.remove(cpe) def updateWhitelist(cpeOld, cpeNew, cpeType): oList = CPEList(collection, args) return oList.update(cpeOld, cpeNew, cpeType) if __name__ == "__main__": oList = CPEList(collection, args) oList.process()
2,688
Python
.py
77
31.987013
87
0.734055
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,228
db_mgmt_admin.py
cve-search_cve-search/sbin/db_mgmt_admin.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Admin creator script # # Creates an admin account in the database # Only master accounts are allowed to add and remove users # First account registered is the master account # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2015-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com import argparse import getpass import os import sys from hmac import compare_digest from pymongo.errors import ConnectionFailure runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) from lib.DatabaseHandler import DatabaseHandler from lib.DatabaseLayer import getSize dbh = DatabaseHandler() # args argParser = argparse.ArgumentParser( description="Admin account creator for the mongo database" ) argParser.add_argument("-a", help="<name> Add an account", default=False) argParser.add_argument("-c", help="Change the password of an account", default=None) argParser.add_argument("-r", help="Remove account", default=False) argParser.add_argument("-p", help="Promote account to master", default=False) argParser.add_argument("-d", help="Demote account to normal user", default=False) argParser.add_argument("-l", help="Make the user local-only", action="store_true") args = argParser.parse_args() # vars col = "mgmt_users" exits = { "userInDb": "User already exists in database", "userNotInDb": "User does not exist in database", "userpasscombo": "Master user/password combination does not exist", "passwordMatch": "The passwords don't match!", "noMaster": "Not a master account!", "lastMaster": "This user is the last admin in the database and thus can not be removed", "dummy": "_dummy_ is a placeholder, and thus cannot be used", } # functions def verifyPass(password, user): if not dbh.connection.userExists(user): sys.exit(exits["userNotInDb"]) if not dbh.connection.verifyUser(user, password): sys.exit(exits["userpasscombo"]) return True def promptNewPass(): password = getpass.getpass("New password:") verify = getpass.getpass("Verify password:") if not compare_digest(password, verify): sys.exit(exits["passwordMatch"]) return password def masterLogin(): master = input("Master account username: ") if verifyPass(getpass.getpass("Master password:"), master): if not dbh.connection.isMasterAccount(master): sys.exit(exits["noMaster"]) else: sys.exit("Master user/password combination does not exist") return True def isLastAdmin(user): if dbh.connection.isSingleMaster(user): sys.exit(exits["lastMaster"]) # script run try: if args.a: username = args.a if username.strip() == "_dummy_": sys.exit(exits["dummy"]) if dbh.connection.userExists(username): sys.exit(exits["userInDb"]) # set master if db is empty if getSize(col) > 0: masterLogin() password = promptNewPass() dbh.connection.addUser(username, password, localOnly=args.l) else: password = promptNewPass() dbh.connection.addUser(username, password, admin=True, localOnly=args.l) sys.exit("User added") elif args.c: username = args.c verifyPass(getpass.getpass("Old password:"), username) password = promptNewPass() dbh.connection.changePassword(username, password) sys.exit("Password updated") elif args.r: username = args.r if not dbh.connection.userExists(username): sys.exit(exits["userNotInDb"]) dbh.connection.masterLogin() dbh.connection.isLastAdmin(username) dbh.connection.deleteUser(username) sys.exit("User removed from database") elif args.p: username = args.p if not dbh.connection.userExists(username): sys.exit(exits["userNotInDb"]) dbh.connection.masterLogin() # promote dbh.connection.setAdmin(username, True) sys.exit("User promoted") elif args.d: username = args.d if not dbh.connection.userExists(username): sys.exit(exits["userNotInDb"]) dbh.connection.masterLogin() dbh.connection.isLastAdmin(username) # demote dbh.connection.setAdmin(username, False) sys.exit("User demoted") except ConnectionFailure: print("Can't connect to the mongo database") except Exception as e: print(e) print("Outdated database. Please drop and re-fill your database")
4,632
Python
.py
122
32.377049
92
0.694432
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,229
db_blacklist.py
cve-search_cve-search/sbin/db_blacklist.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Blacklist feature to mark CVE's for CPE's of personal interest # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2014-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com # Imports # make sure these modules are available on your system import os import sys runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) import argparse from lib.cpelist import CPEList # parse command line arguments argparser = argparse.ArgumentParser( description="populate/update the blacklist used in webviews" ) argparser.add_argument( "-a", metavar="CPE", nargs="*", help="Add one or more CPE to the blacklist" ) argparser.add_argument( "-A", action="append", metavar="file", help="Read a file of CPEs and add them to the blacklist", ) argparser.add_argument( "-r", metavar="CPE", nargs="*", help="Remove one or more CPE from the blacklist" ) argparser.add_argument( "-R", action="append", metavar="file", help="Read a file of CPEs and remove them from the blacklist", ) argparser.add_argument( "-t", metavar="type", default="cpe", help="Type of item to blacklist. Default: CPE" ) argparser.add_argument("-i", metavar="file", help="Import blacklist from file") argparser.add_argument("-e", metavar="file", help="Export blacklist to file") argparser.add_argument("-d", action="store_true", help="Drop the blacklist") argparser.add_argument("-f", action="store_true", help="Force") argparser.add_argument("-v", action="store_true", help="Verbose") args = argparser.parse_args() # Variables collection = "blacklist" # Functions def importBlacklist(importFile): oList = CPEList(collection, args) return oList.importList(importFile) def exportBlacklist(exportFile=None): oList = CPEList(collection, args) return oList.exportList(exportFile) def dropBlacklist(): oList = CPEList(collection, args) return oList.dropCollection() def countBlacklist(): oList = CPEList(collection, args) return oList.countItems() def checkBlacklist(cpe): oList = CPEList(collection, args) amount = oList.check(cpe) return amount def insertBlacklist(cpe, cpeType, comments=None): oList = CPEList(collection, args) return oList.insert(cpe, cpeType, comments) def removeBlacklist(cpe): oList = CPEList(collection, args) return oList.remove(cpe) def updateBlacklist(cpeOld, cpeNew, cpeType): oList = CPEList(collection, args) return oList.update(cpeOld, cpeNew, cpeType) if __name__ == "__main__": oList = CPEList(collection, args) oList.process()
2,700
Python
.py
78
31.717949
87
0.734411
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,230
db_cpe_browser.py
cve-search_cve-search/sbin/db_cpe_browser.py
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Importing CPE entries in a Redis database to improve lookup # # Until now, this part is only used by the web interface to improve response time # # Software is free software released under the "GNU Affero General Public License v3.0" # # Copyright (c) 2014-2018 Alexandre Dulaunoy - a@foo.be # Copyright (c) 2014-2018 Pieter-Jan Moreels - pieterjan.moreels@gmail.com # Imports import argparse import os import sys runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(runPath, "..")) from lib.Sources_process import CPERedisBrowser from lib.DatabaseLayer import getAlternativeCPEs argParser = argparse.ArgumentParser(description="CPE entries importer in Redis cache") argParser.add_argument("-v", action="store_true", default=False, help="Verbose logging") argParser.add_argument( "-o", action="store_true", default=False, help="Import cpeother database in Redis cache", ) args = argParser.parse_args() if __name__ == "__main__": if args.o: cpe = getAlternativeCPEs() crb = CPERedisBrowser(cpes=cpe) else: crb = CPERedisBrowser() if args.v: crb.set_debug_logging = True crb.update()
1,237
Python
.py
37
30.486486
88
0.729866
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,231
conf.py
cve-search_cve-search/docs/source/conf.py
# Configuration file for the Sphinx documentation builder. # # This file only contains a selection of the most common options. For a full # list see the documentation: # https://www.sphinx-doc.org/en/master/usage/configuration.html # -- Path setup -------------------------------------------------------------- # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the # documentation root, use os.path.abspath to make it absolute, like shown here. # import os import sys sys.path.insert(0, os.path.abspath("../../..")) # -- Project information ----------------------------------------------------- project = "CVE-Search" copyright = "2020-2024, https://github.com/cve-search/cve-search" author = "https://github.com/cve-search/cve-search" html_favicon = "_static/favicon.ico" # -- General configuration --------------------------------------------------- # source_suffix = [".rst", ".md"] # Add any Sphinx extension module names here, as strings. They can be # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # ones. extensions = [ "sphinx.ext.autodoc", "sphinx.ext.viewcode", "sphinx.ext.githubpages", "sphinx.ext.intersphinx", ] # Add any paths that contain templates here, relative to this directory. templates_path = ["_templates"] # List of patterns, relative to source directory, that match files and # directories to ignore when looking for source files. # This pattern also affects html_static_path and html_extra_path. exclude_patterns = [] # -- Options for HTML output ------------------------------------------------- # The theme to use for HTML and HTML Help pages. See the documentation for # a list of builtin themes. # html_theme = "sphinx_rtd_theme" # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files, # so a file named "default.css" will overwrite the builtin "default.css". html_static_path = ["_static"]
2,081
Python
.py
44
45.568182
79
0.674913
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,232
set_version.py
cve-search_cve-search/web/set_version.py
import os import re import subprocess # nosec _PKG_DIR = os.path.dirname(os.path.realpath(__file__)) def _version_from_git_describe(): """ Read the version from ``git describe``. It returns the latest tag with an optional suffix if the current directory is not exactly on the tag. Example:: $ git describe --always v2.3.2-346-g164a52c075c8 The tag prefix (``v``) and the git commit sha1 (``-g164a52c075c8``) are removed if present. If the current directory is not exactly on the tag, a ``.devN`` suffix is appended where N is the number of commits made after the last tag. Example:: '>>> _version_from_git_describe()' '2.3.2.dev346' """ if not os.path.isdir(os.path.join(_PKG_DIR, "../.git")): # noqa: E501 raise ValueError("not in git repo") process = subprocess.Popen( # nosec ["git", "describe", "--always"], cwd=_PKG_DIR, stdout=subprocess.PIPE, stderr=subprocess.PIPE, ) out, err = process.communicate() if process.returncode == 0: tag = out.decode().strip() match = re.match("^v?(.+?)-(\\d+)-g[a-f0-9]+$", tag) if match: # remove the 'v' prefix and add a '.devN' suffix return "%s.dev%s" % (match.group(1), match.group(2)) else: # just remove the 'v' prefix return re.sub("^v", "", tag) else: raise subprocess.CalledProcessError(process.returncode, err) def _version(): version_file = os.path.join(_PKG_DIR, "VERSION") try: tag = _version_from_git_describe() # successfully read the tag from git, write it in VERSION for # installation and/or archive generation. with open(version_file, "w") as fdesc: fdesc.write(tag) return tag except Exception: # failed to read the tag from git, try to read it from a VERSION file try: with open(version_file, "r") as fdsec: tag = fdsec.read() return tag except Exception: # Rely on git archive "export-subst" git attribute. # See 'man gitattributes' for more details. git_archive_id = "$Format:%h %d$" sha1 = git_archive_id.strip().split()[0] match = re.search("tag:(\\S+)", git_archive_id) if match: return "git-archive.dev" + match.group(1) elif sha1: return "git-archive.dev" + sha1 else: return "unknown.version" VERSION = __version__ = _version() VERSION_MAIN = re.search(r"[0-9.]+", VERSION).group()
2,659
Python
.py
68
30.661765
77
0.586475
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,233
run.py
cve-search_cve-search/web/run.py
import logging import random import urllib from datetime import timedelta from CveXplore import CveXplore from CveXplore.errors.database import DatabaseSchemaVersionError from flask import Flask, render_template, request from flask_bootstrap import Bootstrap from flask_breadcrumbs import Breadcrumbs from flask_jwt_extended import JWTManager from flask_login import LoginManager from flask_plugins import PluginManager, get_enabled_plugins from oauthlib.oauth2 import WebApplicationClient from lib.Config import Configuration from lib.LogHandler import AppLogger from lib.Toolkit import isURL from lib.User import User from web.helpers.flask_authentication import FlaskAuthHandler from web.helpers.flask_database import FlaskDatabaseHandler login_manager = LoginManager() auth_handler = FlaskAuthHandler() plugins = PluginManager() dbh = FlaskDatabaseHandler() config = Configuration() cvex = CveXplore(mongodb_connection_details={"host": config.getMongoUri()}) app = None token_blacklist = None oidcClient = None ACCESS_EXPIRES = timedelta(minutes=15) REFRESH_EXPIRES = timedelta(days=30) logging.setLoggerClass(AppLogger) def create_app(version, run_path): global app, token_blacklist, oidcClient, config app = Flask(__name__) app.config["version"] = version app.config["run_path"] = run_path if config.getWebInterface().lower() == "full": app.config["WebInterface"] = False else: app.config["WebInterface"] = True app.config["MONGO_DBNAME"] = config.getMongoDB() app.config["SECRET_KEY"] = str(random.getrandbits(256)) app.config["JWT_SECRET_KEY"] = str(random.getrandbits(256)) app.config["JWT_ACCESS_TOKEN_EXPIRES"] = ACCESS_EXPIRES app.config["JWT_REFRESH_TOKEN_EXPIRES"] = REFRESH_EXPIRES app.config["JWT_BLACKLIST_ENABLED"] = True app.config["JWT_BLACKLIST_TOKEN_CHECKS"] = ["access", "refresh"] token_blacklist = config.getRedisTokenConnection() app.config["RESTX_MASK_SWAGGER"] = False app.config["SWAGGER_UI_DOC_EXPANSION"] = "list" Breadcrumbs(app=app) Bootstrap(app) jwt = JWTManager(app) plugins.init_app(app) dbh.init_app(app) auth_handler.init_app(app) @jwt.additional_claims_loader def add_claims_to_access_token(identity): return {"user": identity} @jwt.token_in_blocklist_loader def check_if_token_is_revoked(decrypted_token): jti = decrypted_token["jti"] entry = token_blacklist.get(jti) if entry == "true": return True return False login_manager.init_app(app) login_manager.login_message = "You must be logged in to access this page!!!" login_manager.login_view = "auth.login" # CORS @app.after_request def apply_caching(response): reqURL = request.base_url if ( config.getCORS() and reqURL.count("/api/") == 1 and reqURL.count("/admin") == 0 ): response.headers.add( "Access-Control-Allow-Origin", config.getCORSAllowOrigin() ) return response # OAuth 2 client setup if config.useOIDC(): oidcClient = WebApplicationClient(config.getClientID()) @login_manager.user_loader def load_user(id): return User.get(id, auth_handler) from .home import home as home_blueprint app.register_blueprint(home_blueprint) if not app.config["WebInterface"]: from .auth import auth as auth_blueprint app.register_blueprint(auth_blueprint) from .admin import admin as admin_blueprint app.register_blueprint(admin_blueprint, url_prefix="/admin") from .restapi import blueprint as api app.register_blueprint(api) @app.context_processor def version(): def get_version(): return app.config["version"] return dict(get_version=get_version) @app.context_processor def get_active_plugins(): def get_active_plugins(): all = list(get_enabled_plugins()) if len(all) != 0: return True return False return dict(get_active_plugins=get_active_plugins) @app.context_processor def db_schema(): def db_schema(): try: return cvex.database.validate_schema() except DatabaseSchemaVersionError as err: return err return dict(db_schema=db_schema) @app.context_processor def WebInterface(): def get_WebInterface(): return app.config["WebInterface"] return dict(get_WebInterface=get_WebInterface) @app.context_processor def JSON2HTMLTable(): # Doublequote, because we have to |safe the content for the tags def doublequote(data): return urllib.parse.quote_plus(urllib.parse.quote_plus(data)) def JSON2HTMLTableFilter(data, stack=None): _return = "" if type(stack) == str: stack = [stack] if type(data) == list: if len(data) == 1: _return += JSON2HTMLTableFilter(data[0], stack) else: _return += '<ul class="via4">' for item in data: _return += "<li>%s</li>" % JSON2HTMLTableFilter(item, stack) _return += "</ul>" elif type(data) == dict: _return += '<table class="invisiTable">' for key, val in sorted(data.items()): _return += "<tr><td><b>%s</b></td><td>%s</td></tr>" % ( key, JSON2HTMLTableFilter(val, stack + [key]), ) _return += "</table>" elif type(data) == str: if stack: _return += ( "<a href='/link/" + doublequote(".".join(stack)) + "/" + doublequote(data) + "'>" ) # link opening _return += "<i class='fas fa-link' aria-hidden='true'></i> </a>" _return += ( "<a target='_blank' href='%s'>%s</a>" % (data, data) if isURL(data) else data ) _return += "" return _return return dict(JSON2HTMLTable=JSON2HTMLTableFilter) @app.template_filter("htmlEncode") def htmlEncode(string): return urllib.parse.quote_plus(string).lower() @app.template_filter("htmlDecode") def htmlDecode(string): return urllib.parse.unquote_plus(string) @app.template_filter("sortIntLikeStr") def sortIntLikeStr(datalist): return sorted(datalist, key=lambda k: int(k)) @app.errorhandler(404) def page_not_found(error): return render_template("404.html"), 404 return app
6,972
Python
.py
179
29.871508
84
0.619161
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,234
index.py
cve-search_cve-search/web/index.py
import os import sys _runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(_runPath, "..")) import multiprocessing import logging import gunicorn from lib.Config import Configuration from lib.LogHandler import AppLogger from web.run import create_app from web.set_version import _version from flask import Flask from logging.config import fileConfig, dictConfig from gunicorn.glogging import CONFIG_DEFAULTS from gunicorn.app.base import BaseApplication config = Configuration() logging.setLoggerClass(AppLogger) __version__ = _version() class StandaloneApplication(BaseApplication): def __init__(self, app, options=None): self.options = options or {} self.application = app super().__init__() def load_config(self): config = { key: value for key, value in self.options.items() if key in self.cfg.settings and value is not None } for key, value in config.items(): self.cfg.set(key.lower(), value) def load(self): return self.application class GunicornLogger(gunicorn.glogging.Logger): def __init__(self, cfg): super().__init__(cfg) def setup(self, cfg): self.loglevel = self.LOG_LEVELS.get(cfg.loglevel.lower(), logging.INFO) self.error_log.setLevel(self.loglevel) self.access_log.setLevel(logging.INFO) # set gunicorn.error handler if self.cfg.capture_output and cfg.errorlog != "-": for stream in sys.stdout, sys.stderr: stream.flush() self.logfile = open(cfg.errorlog, "a+") os.dup2(self.logfile.fileno(), sys.stdout.fileno()) os.dup2(self.logfile.fileno(), sys.stderr.fileno()) # Force gunicorn to produce an access log; without pushing this to stdout from this instance self.cfg.set("accesslog", "Y") if cfg.logconfig_dict: config = CONFIG_DEFAULTS.copy() config.update(cfg.logconfig_dict) try: dictConfig(config) except (AttributeError, ImportError, ValueError, TypeError) as exc: raise RuntimeError(str(exc)) elif cfg.logconfig: if os.path.exists(cfg.logconfig): defaults = CONFIG_DEFAULTS.copy() defaults["__file__"] = cfg.logconfig defaults["here"] = os.path.dirname(cfg.logconfig) fileConfig( cfg.logconfig, defaults=defaults, disable_existing_loggers=False ) else: msg = "Error: log config '%s' not found" raise RuntimeError(msg % cfg.logconfig) class FlaskAppManager(object): def __init__(self, version: str, app: Flask, *args, **kwargs): self.logger = logging.getLogger(__name__) self.logger.info("Initializing FlaskAppManager...") self.app = app if not isinstance(self.app, Flask): raise AttributeError( f"The provided app variable is not of type 'Flask' but {type(self.app)}" ) self.version = version self.max_workers = int(os.getenv("WEB_MAX_WORKERS", 0)) self.web_worker_timeout = int(os.getenv("WEB_WORKER_TIMEOUT", 60)) self.web_tls_key_path = os.path.join(_runPath, "../", config.getSSLKey()) self.web_tls_cert_path = os.path.join(_runPath, "../", config.getSSLCert()) self.debug = config.getFlaskDebug() self.debug_with_ssl = config.getFlaskSSLDebug() self.bind_host = config.getFlaskHost() self.bind_port = config.getFlaskPort() self.logger.info( f"Initialization complete, call the run method to start the app!" ) def run(self): self.logger.info("Trying to start the app...") try: self.logger.info(f"Running version: {self.version}") if self.debug: if self.debug_with_ssl: self.app.run( host=self.bind_host, port=self.bind_port, ssl_context="adhoc", ) else: self.app.run( host=self.bind_host, port=self.bind_port, ) else: options = { "bind": f"{self.bind_host}:{self.bind_port}", "workers": self._number_of_workers(), "timeout": self.web_worker_timeout, "logger_class": "web.index.GunicornLogger", "access_log_format": "%(t)s src_ip=%(h)s request=%(r)s request_method=%(m)s status=%(s)s " "response_length=%(b)s referrer=%(f)s url=%(U)s query=?%(q)s user_agent=%(a)s t_ms=%(L)s", } if os.path.exists(self.web_tls_key_path) and os.path.exists( self.web_tls_cert_path ): options["keyfile"] = self.web_tls_key_path options["certfile"] = self.web_tls_cert_path StandaloneApplication(self.app, options).run() else: # no TLS; assume running behind reverse proxy that handles TLS offloading; switching to plain http StandaloneApplication(self.app, options).run() except Exception: raise def _number_of_workers(self): if self.max_workers != 0: return self.max_workers else: return (multiprocessing.cpu_count() * 2) + 1 app = create_app(__version__, _runPath) if __name__ == "__main__": fam = FlaskAppManager(version=__version__, app=app) fam.run()
5,791
Python
.py
133
32.030075
118
0.578114
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,235
wsgi.py
cve-search_cve-search/web/wsgi.py
import os import sys from flask import Flask from werkzeug.middleware.dispatcher import DispatcherMiddleware _runPath = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(_runPath, "..")) from lib.Config import Configuration from web.run import create_app from web.set_version import _version __version__ = _version() config = Configuration() app = Flask(__name__) cveapp = create_app(__version__, _runPath) app.wsgi_app = DispatcherMiddleware(Flask("FRAME"), {config.getMountPath(): cveapp}) if __name__ == "__main__": app.run(host="0.0.0.0")
579
Python
.py
16
34.375
84
0.743682
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,236
capec.py
cve-search_cve-search/web/restapi/capec.py
from flask_restx import Namespace, Resource from web.restapi.cpe_convert import message from web.restapi.cve import capec_entry api = Namespace( "capec", description="Endpoints for requesting capec information", path="/" ) @api.route("/capec/show/<capec_id>") @api.param("capec_id", "CAPEC id", example="112") @api.response(400, "Error processing request", model=message) @api.response(404, "The requested CAPEC is not found", model=message) @api.response(500, "Server error", model=message) class CapecId(Resource): @api.marshal_with(capec_entry) def get(self, capec_id): """ CAPEC from CAPEC ID Outputs a CAPEC specified by it's id. CAPEC (Common Attack Pattern Enumeration and Classification) are a list of attack types commonly used by attackers. """ from lib.DatabaseLayer import getCAPEC capec = getCAPEC(capec_id) if capec is None: api.abort(404, "The requested CAPEC is not found") else: return capec @api.route("/capec/<cwe_id>") @api.param("cwe_id", "CWE id", example="1253") @api.response(400, "Error processing request", model=message) @api.response(404, "The requested CAPEC is not found", model=message) @api.response(500, "Server error", model=message) class CapecByCweId(Resource): @api.marshal_list_with(capec_entry) def get(self, cwe_id): """ CAPEC's from CWE ID Outputs a list of CAPEC related to a CWE. CAPEC (Common Attack Pattern Enumeration and Classification) are a list of attack types commonly used by attackers. """ from lib.DatabaseLayer import getCAPECFor capecs = getCAPECFor(cwe_id) if len(capecs) == 0: api.abort(404, "The requested CAPEC is not found") else: return capecs
1,830
Python
.py
44
35.5
123
0.684329
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,237
cwe.py
cve-search_cve-search/web/restapi/cwe.py
from flask_restx import Namespace, Resource, fields from web.restapi.cpe_convert import message api = Namespace("cwe", description="Endpoints for requesting cwe information", path="/") cwe = api.model( "Cwe", { "name": fields.String( description="Name of the CWE", example="Incorrect Selection of Fuse Values" ), "id": fields.String(description="ID of the CWE", example="1253"), "status": fields.String(description="Status of the CWE", example="Draft"), "weaknessabs": fields.String(description="Category of the CWE", example="Base"), "description": fields.String( description="Description of the CWE", example="Logic should be designed in a way that blown fuses do not put the product into an insecure state " "that can be leveraged by an attacker. Logic should be designed in a way that blown fuses do not " "put the product into an insecure state that can be leveraged by an attacker. ", ), "related_weaknesses": fields.List( fields.String, description="List of related weaknesses of the CWE", example=["693"], ), }, ) @api.route("/cwe") @api.response(400, "Error processing request", model=message) @api.response(404, "The requested CWE is not found", model=message) @api.response(500, "Server error", model=message) class CweId(Resource): @api.marshal_list_with(cwe, skip_none=True) def get(self): """ List all CWE's Outputs a list of all CWEs (Common Weakness Enumeration). """ from lib.DatabaseLayer import getCWEs cwes = getCWEs() if cwes is None: api.abort(404, "The requested CWE is not found") else: return cwes @api.route("/cwe/<cwe_id>") @api.param("cwe_id", "CWE id", example="1253") @api.response(400, "Error processing request", model=message) @api.response(404, "The requested CWE is not found", model=message) @api.response(500, "Server error", model=message) class CweId(Resource): @api.marshal_with(cwe, skip_none=True) def get(self, cwe_id): """ CWE from CWE ID Outputs a specific CWE (Common Weakness Enumeration). """ from lib.DatabaseLayer import getCWEs cwes = getCWEs(cwe_id) if cwes is None: api.abort(404, "The requested CWE is not found") else: return cwes
2,471
Python
.py
60
33.766667
119
0.644704
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,238
auth.py
cve-search_cve-search/web/restapi/auth.py
from flask import request from flask_jwt_extended import create_access_token, get_jti, jwt_required, get_jwt from flask_restx import Namespace, Resource, fields from lib.User import User from web.restapi.cpe_convert import message from web.run import ACCESS_EXPIRES, token_blacklist, app api = Namespace("auth", description="Endpoints for authorisation", path="/") login_user = api.model("ApiLogin", {"credentials": fields.Raw(required=True)}) user_token = api.model( "UserToken", { "access_token": fields.String( required=True, description="Access token provided", example="eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpYXQiOjE1OTQ2NzE3NDAsIm5iZiI6MTU5NDY3MTc0MCwianRpIjoiYjcw" "ZWQ1MTMtMTgyMS00MGFiLWE4YjQtZjkxNGM4ZDE1OTgzIiwiZXhwIjoxNTk0NjcyNjQwLCJpZGVudGl0eSI6ImFkbWluIiwiZn" "Jlc2giOmZhbHNlLCJ0eXBlIjoiYWNjZXNzIn0.6gs-yGoEH_ecjgiFgfuxI7CpE5JJPlcdS6xq0ZxGxQ4", ) }, ) credentials = api.model( "credentials", { "username": fields.String( required=True, description="Username to login", example="reaper" ), "password": fields.String( required=True, description="Password to login", example="SuperSecretPassWd.01", ), }, ) @api.route("/login") @api.response(400, "Error processing request", model=message) @api.response(500, "Server error", model=message) class ApiLogin(Resource): @api.doc(body=credentials) @api.marshal_with(user_token) def post(self): """ login Endpoint used for requesting JWT token via a username and password """ if not request.is_json: api.abort(400, "Missing JSON in request") username = request.json.get("username", None) password = request.json.get("password", None) if not username: api.abort(400, "Missing username parameter in request body") if not password: api.abort(400, "Missing password parameter in request body") user = User.get(username, app.auth_handler) if user is None: api.abort(400, "Bad username or password") if user is not None and user.authenticate(password): access_token = create_access_token(identity="user_{}".format(user.id)) access_jti = get_jti(encoded_token=access_token) token_blacklist.set(access_jti, "false", ACCESS_EXPIRES * 1.2) ret = {"access_token": access_token} return ret else: api.abort(400, "Bad username or password") @api.route("/logout") @api.response(400, "Error processing request", model=message) @api.response(401, "Unauthorized or missing token in request", model=message) @api.response(500, "Server error", model=message) @api.param( name="Authorization", description="JWT Token", _in="header", required=True, example="Bearer 'extreme long jwt token'", ) class ApiLogout(Resource): @api.response(200, "Logout successful", model=message) @jwt_required def get(self): """ logout Endpoint used for logging out and revoking the used JWT token """ jti = get_jwt()["jti"] token_blacklist.set(jti, "true", ACCESS_EXPIRES * 1.2) return {"message": "Logout successful"}
3,358
Python
.py
85
32.341176
119
0.670151
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,239
__init__.py
cve-search_cve-search/web/restapi/__init__.py
from flask import Blueprint from flask_restx import Api from web.run import app from .admin import bl as bl_api from .admin import wl as wl_api from .auth import api as auth_api from .browse_vendor import api as browse_api from .capec import api as capec_api from .cpe_convert import api as cpe_api from .cve import api as cve_api from .cwe import api as cwe_api from .dbinfo import api as dbinfo_api from .query import api as query_api from .search_vendor import api as search_vendor_api namespaces = [ cpe_api, cve_api, cwe_api, capec_api, query_api, browse_api, search_vendor_api, dbinfo_api, ] blueprint = Blueprint("api", __name__, url_prefix="/api") api = Api( blueprint, title="CVE-Search", version=app.config["version"], description="CVE-Search API documentation", ) for each in namespaces: api.add_namespace(each) if not app.config["WebInterface"]: api.add_namespace(auth_api) api.add_namespace(wl_api) api.add_namespace(bl_api)
1,008
Python
.py
37
24.351351
57
0.736788
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,240
admin.py
cve-search_cve-search/web/restapi/admin.py
import json from collections import defaultdict from flask import request from flask_jwt_extended import jwt_required from flask_restx import Namespace, Resource, fields from sbin.db_blacklist import ( dropBlacklist, insertBlacklist, removeBlacklist, importBlacklist, ) from sbin.db_whitelist import ( dropWhitelist, insertWhitelist, removeWhitelist, importWhitelist, ) from web.restapi.cpe_convert import message wl = Namespace("whitelist", description="Endpoints for whitelist", path="/admin/") bl = Namespace("blacklist", description="Endpoints for blacklist", path="/admin/") white_black_list = wl.model( "WBList", { "id": fields.String( description="The id of a listed CPE", example="cpe:2.3:h:-:wireless_ip_camera_360:-:*:*:*:*:*:*:*", required=True, ), "type": fields.String( description="The type of the listed entry (cpe or type)", example="cpe, targetsoftware or targethardware", required=True, ), "comments": fields.List( fields.String, description="A list of given comments related to the entry", example=["Comment 1", "Comment 2", "Comment 3"], ), }, ) white_black_entry = wl.model( "WBEntry", { "cpe": fields.String( description="CPE code in cpe2.2 or cpe2.3 format", example="cpe:2.3:o:gnu:gcc", required=True, ), "type": fields.String( description="CPE type", example="cpe, targetsoftware or targethardware", required=True, ), "comments": fields.List( fields.String, description="A list of comments", example=["Comment 1", "Comment 2", "Comment 3"], ), }, ) white_black_del = wl.model( "WBEntryDel", { "cpe": fields.String( description="CPE code in cpe2.2 or cpe2.3 format", example="cpe:2.3:o:gnu:gcc", required=True, ) }, ) @wl.route("/whitelist") @wl.response(400, "Error processing request", model=message) @wl.response(401, "Unauthorized or missing token in request", model=message) @wl.response(500, "Server error", model=message) @wl.param( name="Authorization", description="JWT Token", _in="header", required=True, example="Bearer 'extreme long jwt token'", ) class WhitelistClass(Resource): @wl.marshal_list_with(white_black_list, skip_none=True) @jwt_required def get(self): """ List Returns the content of the whitelist. The whitelist is a list of CPEs that will mark a CVE when the CVE applies to the product. It is intended to be used as a notification/warning mechanism. There are three types of CPEs: <ul> <li>cpe - A fully qualified CPE code in CPE2.2 or CPE2.3 format</li> <li>targetsoftware - A software the CPE applies to. Equivalent to cpe:2.3:-:-:-:-:-:-:-:-:&lt;cpe&gt;</li> <li>targethardware - A hardware the CPE applies to. Equivalent to cpe:2.3:-:-:-:-:-:-:-:-:-:&lt;cpe&gt;</li> </ul> Other types are possible, but are not used by the software. """ from lib.DatabaseLayer import getWhitelist return getWhitelist() @wl.marshal_with(message) @jwt_required def delete(self): """ Drop Endpoint that drops the content of the whitelist. """ return {"message": dropWhitelist()} @wl.marshal_with(message) @wl.doc(body=[white_black_list]) @jwt_required def put(self): """ Import Endpoint that imports the whitelist from a file. The file should be structured the same as the /whitelist endpoint, for example: <br> <pre> [ { "id": "cpe:2.3:h:-:wireless_ip_camera_360:-:*:*:*:*:*:*:*", "type": "cpe" }, { "id": "cpe:2.3:a:.bbsoftware:bb_flashback:*:*:*:*:*:*:*:*", "type": "cpe" }, { "comments": [ " test" ], "id": "cpe:2.3:a:.joomclan:com_joomclip:*:*:*:*:*:*:*:*", "type": "cpe" } ] </pre> """ data = request.data if len(data) == 0: wl.abort(400, "No file selected") return {"message": importWhitelist(data)} @wl.route("/whitelist/entry") @wl.response(400, "Error processing request", model=message) @wl.response(401, "Unauthorized or missing token in request", model=message) @wl.response(500, "Server error", model=message) @wl.param( name="Authorization", description="JWT Token", _in="header", required=True, example="Bearer 'extreme long jwt token'", ) class WhitelistEntryClass(Resource): @wl.doc(body=white_black_entry) @wl.marshal_with(message) @jwt_required def post(self): """ Add Puts a single or multiple CPE(s) into the whitelist. Passing a single request body schema adds a single entry into the whitelist. Combining multiple request body schemas into a list adds multiple entries into the whitelist """ if not request.is_json: wl.abort(400, "Missing JSON in request") if isinstance(request.json, list): ret_val = defaultdict(str) for each in request.json: cpe = each.get("cpe", None) t_type = each.get("type", None) comments = each.get("comments", None) if not cpe: wl.abort(400, "Missing cpe parameter in request body") if not t_type: wl.abort(400, "Missing type parameter in request body") ret_val[cpe] = insertWhitelist(cpe, t_type, comments) ret_val = json.dumps(dict(ret_val)) else: cpe = request.json.get("cpe", None) t_type = request.json.get("type", None) comments = request.json.get("comments", None) if not cpe: wl.abort(400, "Missing cpe parameter in request body") if not t_type: wl.abort(400, "Missing type parameter in request body") ret_val = insertWhitelist(cpe, t_type, comments) return {"message": ret_val} @wl.marshal_with(message) @jwt_required def delete(self): """ Remove Deletes a CPE from the whitelist. """ if not request.is_json: wl.abort(400, "Missing JSON in request") if isinstance(request.json, list): ret_val = defaultdict(str) for each in request.json: cpe = each.get("cpe", None) if not cpe: wl.abort(400, "Missing cpe parameter in request body") ret_val[cpe] = removeWhitelist(cpe) ret_val = json.dumps(dict(ret_val)) else: cpe = request.json.get("cpe", None) if not cpe: wl.abort(400, "Missing cpe parameter in request body") ret_val = removeWhitelist(cpe) return {"message": ret_val} @bl.route("/blacklist") @bl.response(400, "Error processing request", model=message) @bl.response(401, "Unauthorized or missing token in request", model=message) @bl.response(500, "Server error", model=message) @bl.param( name="Authorization", description="JWT Token", _in="header", required=True, example="Bearer 'extreme long jwt token'", ) class BlacklistClass(Resource): @bl.marshal_list_with(white_black_list, skip_none=True) @jwt_required def get(self): """ List Returns the content of the blacklist. The blacklist is a list of CPEs that will hide a CVE when all the CPEs a product applies to are blacklisted. It is intended to be used as a way to hide unwanted information. There are three types of CPEs: <ul> <li>cpe - A fully qualified CPE code in CPE2.2 or CPE2.3 format</li> <li>targetsoftware - A software the CPE applies to. Equivalent to cpe:2.3:-:-:-:-:-:-:-:-:&lt;cpe&gt;</li> <li>targethardware - A hardware the CPE applies to. Equivalent to cpe:2.3:-:-:-:-:-:-:-:-:-:&lt;cpe&gt;</li> </ul> Other types are possible, but are not used by the software. """ from lib.DatabaseLayer import getBlacklist return getBlacklist() @bl.marshal_with(message) @jwt_required def delete(self): """ Drop Endpoint that drops the content of the blacklist. """ return {"message": dropBlacklist()} @bl.marshal_with(message) @wl.doc(body=[white_black_list]) @jwt_required def put(self): """ Import Endpoint that imports the blacklist. The file should be structured the same as the /whitelist endpoint, for example: <br> <pre> [ { "id": "cpe:2.3:h:-:wireless_ip_camera_360:-:*:*:*:*:*:*:*", "type": "cpe" }, { "id": "cpe:2.3:a:.bbsoftware:bb_flashback:*:*:*:*:*:*:*:*", "type": "cpe" }, { "comments": [ " test" ], "id": "cpe:2.3:a:.joomclan:com_joomclip:*:*:*:*:*:*:*:*", "type": "cpe" } ] </pre> """ data = request.data if len(data) == 0: wl.abort(400, "No file selected") return {"message": importBlacklist(data)} @bl.route("/blacklist/entry") @bl.response(400, "Error processing request", model=message) @bl.response(401, "Unauthorized or missing token in request", model=message) @bl.response(500, "Server error", model=message) @bl.param( name="Authorization", description="JWT Token", _in="header", required=True, example="Bearer 'extreme long jwt token'", ) class BlacklistEntryClass(Resource): @bl.doc(body=white_black_entry) @bl.marshal_with(message) @jwt_required def post(self): """ Add Puts a single or multiple CPE(s) into the blacklist. Passing a single request body schema adds a single entry into the whitelist. Combining multiple request body schemas into a list adds multiple entries into the whitelist """ if not request.is_json: wl.abort(400, "Missing JSON in request") if isinstance(request.json, list): ret_val = defaultdict(str) for each in request.json: cpe = each.get("cpe", None) t_type = each.get("type", None) comments = each.get("comments", None) if not cpe: wl.abort(400, "Missing cpe parameter in request body") if not t_type: wl.abort(400, "Missing type parameter in request body") ret_val[cpe] = insertBlacklist(cpe, t_type, comments) ret_val = json.dumps(dict(ret_val)) else: cpe = request.json.get("cpe", None) t_type = request.json.get("type", None) comments = request.json.get("comments", None) if not cpe: wl.abort(400, "Missing cpe parameter in request body") if not t_type: wl.abort(400, "Missing type parameter in request body") ret_val = insertBlacklist(cpe, t_type, comments) return {"message": ret_val} @bl.marshal_with(message) @jwt_required def delete(self): """ Remove Deletes a CPE from the blacklist. """ if not request.is_json: wl.abort(400, "Missing JSON in request") if isinstance(request.json, list): ret_val = defaultdict(str) for each in request.json: cpe = each.get("cpe", None) if not cpe: wl.abort(400, "Missing cpe parameter in request body") ret_val[cpe] = removeBlacklist(cpe) ret_val = json.dumps(dict(ret_val)) else: cpe = request.json.get("cpe", None) if not cpe: wl.abort(400, "Missing cpe parameter in request body") ret_val = removeBlacklist(cpe) return {"message": ret_val}
12,521
Python
.py
350
26.728571
118
0.575122
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,241
search_vendor.py
cve-search_cve-search/web/restapi/search_vendor.py
from flask_restx import Resource, Namespace, fields from lib.Query import searchVendors, searchProductsByVendor, searchVersionsByProduct from web.restapi.cpe_convert import message api = Namespace( "search-vendor", description="Endpoints to search vendor information by providing part strings.", path="/", ) search_vendor_model = api.model( "browseList", { "vendor": fields.List( fields.String, description="List with vendor names matching the given part", example=[".bbsoftware", ".joomclan", ".matteoiammarrone", "....."], ) }, ) @api.route("/search-vendor/<vendor_part>") @api.response(400, "Error processing request", model=message) @api.response(500, "Server error", model=message) class SearchVendors(Resource): @api.marshal_with(search_vendor_model) def get(self, vendor_part): """ Search vendors Returns a list of vendors that match the given part-string. """ return searchVendors(vendor_part) search_product_by_vendor_model = api.model( "browseListVendor", { "product": fields.List( fields.String, description="List with product names belonging to the given vendor that match the given part string", example=[".net_core", ".net_core_sdk", ".net_framework", "...."], ), "vendor": fields.String(description="Vendor name", example="microsoft"), }, ) @api.route("/search-vendor/<vendor>/<product_part>") @api.response(400, "Error processing request", model=message) @api.response(500, "Server error", model=message) class SearchProductsByVendor(Resource): @api.marshal_with(search_product_by_vendor_model) def get(self, vendor, product_part): """ Search products by vendor Returns a list of products that match the given vendor and part-string. """ return searchProductsByVendor(vendor, product_part) search_version_by_product_model = api.model( "browseVersions", { "version": fields.List( fields.String, description="List with versions belonging to the given product that match the given part string", example=[ "*:*:*:*:*:*:*:*", "1.0:*:*:*:*:*:*:*", "1.1:*:*:*:*:*:*:*", "2.0:*:*:*:*:*:*:*", "....", ], ), "product": fields.String(description="Product name", example=".net_core"), "vendor": fields.String(description="Vendor name", example=".microsoft"), }, ) @api.route("/search-vendor/<vendor>/<product>/<version_part>") @api.response(400, "Error processing request", model=message) @api.response(500, "Server error", model=message) class SearchVersionsByProduct(Resource): @api.marshal_with(search_version_by_product_model) def get(self, vendor, product, version_part): """ Search CPEs by vendor and product. Returns a list of CPEs that match the given vendor, product and version part-string. """ return searchVersionsByProduct(vendor, product, version_part)
3,151
Python
.py
80
32.3875
113
0.641244
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,242
query.py
cve-search_cve-search/web/restapi/query.py
import json from bson import json_util from dicttoxml import dicttoxml from flask import request, Response from flask_restx import Namespace, fields, Resource from lib.ApiRequests import JSONApiRequest from lib.DatabaseHandler import DatabaseHandler from web.home.utils import filter_logic, parse_headers from web.restapi.cpe_convert import message from web.restapi.cve import cve_last_entries api = Namespace( "query", description="Endpoints for querying the cve search database", path="/" ) query_entries = api.model( "QueryEntries", { "results": fields.List( fields.Nested(cve_last_entries), description="Results from query", example="", ), "total": fields.Integer( description="Total amount of records available for this query", example="150243", ), }, ) PostBodyRequest = api.model( "ApiPostRequest", { "retrieve": fields.String( description="Retrieve data from this collection, allowed options are 'capec', 'cpe', 'cves', 'cwe', 'via4'", example="cves", required=True, ), "dict_filter": fields.Raw( description="filter according to pymongo docs", example={ "vulnerable_configuration": "cpe:2.3:o:microsoft:windows_7:*:sp1:*:*:*:*:*:*" }, required=True, ), "limit": fields.Integer( description="Limit the amount of returned documents", example=10 ), "skip": fields.Integer( description="Skip the first N amount of documents", example=25 ), "sort": fields.String(description="Sort on this field", example="cvss"), "sort_dir": fields.String( description="sorting direction ASC = pymongo.ASCENDING, DESC = pymongo.DESCENDING", example="ASC", ), "query_filter": fields.Raw( description="query filter to exclude certain fields (via a 0) or to limit query to a specific set (via a 1)", example={"access": 0, "cwe": 0}, ), }, ) PostBodyResponse = api.model( "ApiPostResponse", { "data": fields.List( fields.Raw, description="Returned data", example=[ { "modified": "2017-08-15T17:24:00", "published": "2017-08-08T21:29:00", "_id": "5f76228ff3b9be1242eb4fc0", "assigner": "cve@mitre.org", "cvss": 9.3, "impactScore": 3.0, "exploitabilityScore": 3.0, "cvssTime": "2017-08-15T17:24:00", "cvssVector": "AV:N/AC:M/Au:N/C:C/I:C/A:C", "id": "CVE-2017-0250", "impact": { "availability": "COMPLETE", "confidentiality": "COMPLETE", "integrity": "COMPLETE", }, "impact3": { "availability": "HIGH", "confidentiality": "HIGH", "integrity": "HIGH", }, "exploitability3": { "attackvector": "NETWORK", "attackcomplexity": "LOW", "privilegesrequired": "NONE", "userinteraction": "REQUIRED", "scope": "CHANGED", }, "cvss3": 9.6, "impactScore3": 3.0, "exploitabilityScore3": 6.6, "cvss3-vector": "CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H", "lastModified": "2017-08-15T17:24:00", "references": [ "http://www.securityfocus.com/bid/98100", "http://www.securitytracker.com/id/1039090", "https://portal.msrc.microsoft.com/en-US/security-guidance/advisory/CVE-2017-0250", ], "summary": "Microsoft JET Database Engine in Windows Server 2008 SP2 and R2 SP1, Windows 7 SP1, " "Windows 8.1, Windows Server 2012 Gold and R2, Windows RT 8.1, Windows 10 Gold, 1511, " "1607, 1703, and Windows Server 2016 allows a remote code execution vulnerability due " 'to buffer overflow, aka "Microsoft JET Database Engine Remote Code Execution ' 'Vulnerability".', "vulnerable_configuration": [ "cpe:2.3:o:microsoft:windows_10:-:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_10:1511:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_10:1607:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_10:1703:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_7:*:sp1:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_8.1:*:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_rt_8.1:*:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_server_2008:*:sp2:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_server_2008:r2:sp1:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_server_2012:*:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_server_2012:r2:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_server_2016:*:*:*:*:*:*:*:*", ], "vulnerable_configuration_cpe_2_2": [], "vulnerable_product": [ "cpe:2.3:o:microsoft:windows_10:-:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_10:1511:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_10:1607:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_10:1703:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_7:*:sp1:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_8.1:*:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_rt_8.1:*:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_server_2008:*:sp2:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_server_2008:r2:sp1:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_server_2012:*:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_server_2012:r2:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_server_2016:*:*:*:*:*:*:*:*", ], }, { "modified": "2019-10-03T00:03:00", "published": "2017-06-15T01:29:00", "_id": "5f76228f56409e4ec0eb4f57", "assigner": "cve@mitre.org", "cvss": 9.3, "impactScore": 3.0, "exploitabilityScore": 3.0, "cvssTime": "2019-10-03T00:03:00", "cvssVector": "AV:N/AC:M/Au:N/C:C/I:C/A:C", "id": "CVE-2017-0260", "impact": { "availability": "COMPLETE", "confidentiality": "COMPLETE", "integrity": "COMPLETE", }, "impact3": { "availability": "HIGH", "confidentiality": "HIGH", "integrity": "HIGH", }, "exploitability3": { "attackvector": "NETWORK", "attackcomplexity": "LOW", "privilegesrequired": "NONE", "userinteraction": "REQUIRED", "scope": "CHANGED", }, "cvss3": 9.6, "impactScore3": 3.0, "exploitabilityScore3": 6.6, "cvss3-vector": "CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H", "lastModified": "2019-10-03T00:03:00", "references": [ "http://www.securityfocus.com/bid/98810", "http://www.securitytracker.com/id/1038668", "https://portal.msrc.microsoft.com/en-US/security-guidance/advisory/CVE-2017-0260", ], "summary": "A remote code execution vulnerability exists in Microsoft Office when the software " 'fails to properly handle objects in memory, aka "Office Remote Code Execution ' 'Vulnerability". This CVE ID is unique from CVE-2017-8509, CVE-2017-8510, ' "CVE-2017-8511, CVE-2017-8512, and CVE-2017-8506.", "vulnerable_configuration": [ "cpe:2.3:a:microsoft:office:2013:sp1:*:*:*:*:*:*", "cpe:2.3:a:microsoft:office:2016:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_7:*:sp1:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_server_2008:*:sp2:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_server_2008:r2:sp1:*:*:*:*:*:*", ], "vulnerable_configuration_cpe_2_2": [], "vulnerable_product": [ "cpe:2.3:a:microsoft:office:2013:sp1:*:*:*:*:*:*", "cpe:2.3:a:microsoft:office:2016:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_7:*:sp1:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_server_2008:*:sp2:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_server_2008:r2:sp1:*:*:*:*:*:*", ], }, ], ), "total": fields.Integer( description="Total amount of returned documents", example=2 ), }, ) @api.route("/query") @api.response(400, "Error processing request", model=message) @api.response(500, "Server error", model=message) class QueryApi(Resource): @api.param( "rejected", "Hide or show rejected CVEs", example="hide/show", default="show", _in="header", ) @api.param("cvss", "CVSS score", example=6.8, _in="header") @api.param( "cvssSelect", "Select the CVSS score of the CVEs related to cvss_score", example="above/equals/below", _in="header", ) @api.param( "cvssVersion", "Select which version of CVSS needs to be queried", example="V2/V3", default="V3", _in="header", ) @api.param( "startDate", "Earliest time for a CVE", example="dd-mm-yyyy or dd-mm-yy format, using - or /", _in="header", ) @api.param( "endDate", "Latest time for a CVE", example="dd-mm-yyyy or dd-mm-yy format, using - or /", _in="header", ) @api.param( "timeSelect", "Timeframe for the CVEs, related to the start and end time", example="from/until/between/outside", _in="header", ) @api.param( "timeTypeSelect", "Select which time is used for the filter", example="modified/published/lastModified", _in="header", ) @api.param( "skip", "Skip the n latest vulnerabilities", example=50, _in="header", type=int ) @api.param( "limit", "Limit the amount of vulnerabilities to return", example=20, _in="header", type=int, ) @api.marshal_with(query_entries, skip_none=True) def get(self): """ Query for CVE's Returns a list of CVEs matching the criteria of the filters specified in the headers. """ f = { "rejectedSelect": request.headers.get("rejected"), "cvss": request.headers.get("cvss"), "cvssSelect": request.headers.get("cvssSelect"), "cvssVersion": request.headers.get("cvssVersion"), "startDate": request.headers.get("startDate"), "endDate": request.headers.get("endDate"), "timeSelect": request.headers.get("timeSelect"), "timeTypeSelect": request.headers.get("timeTypeSelect"), "skip": request.headers.get("skip"), "limit": request.headers.get("limit"), } try: skip = int(f["skip"]) if f["skip"] else 0 except ValueError: api.abort(400, "Skip variable should be an integer") try: limit = int(f["limit"]) if f["limit"] else 0 except ValueError: api.abort(400, "Limit variable should be an integer") results = filter_logic(f, skip, limit) if len(results) == 0: api.abort(404, "") else: return results @api.doc(body=PostBodyRequest) @api.response(200, "OK", PostBodyResponse) @api.param( "format", "Specify in which format the results must be returned", example="json/xml", default="json", _in="query", ) def post(self, format_output="json"): """ Free query Api endpoint that can be used to freely (within the allowed parameters) query the cve search database. The request sample payload displays a request body for a single query; multiple request can be combined within a comma separated list and send in a single request. In this case the responses will be send back in a list. For each request a separate list entry with the results. """ headers = parse_headers(request.headers) database_connection = DatabaseHandler() output_format = ["json", "xml"] received_format = request.args.get("format", None) if received_format is None: format_output = format_output else: format_output = str(received_format) if format_output not in output_format: api.abort( 400, "Specified output format is not possible; possible options are: {}!".format( output_format ), ) try: body = request.json except Exception: return "Could not parse request body", 400 if isinstance(body, dict): result = database_connection.handle_api_json_query( JSONApiRequest(headers=headers, body=body) ) elif isinstance(body, list): result = [] for each in body: result.append( database_connection.handle_api_json_query( JSONApiRequest(headers=headers, body=each) ) ) if isinstance(result, tuple): # error response; just return it return result else: if format_output == "json": return Response( json.dumps( result, indent=4, sort_keys=True, default=json_util.default ), mimetype="application/json", ) if format_output == "xml": return Response(dicttoxml(result), mimetype="text/xml")
15,496
Python
.py
355
29.287324
121
0.489515
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,243
browse_vendor.py
cve-search_cve-search/web/restapi/browse_vendor.py
from flask_restx import Namespace, Resource, fields from lib.Query import getBrowseList from lib.Query import getVersionsOfProduct from web.restapi.cpe_convert import message api = Namespace("browse", description="Endpoints for vendor information", path="/") browseList = api.model( "browseList", { "vendor": fields.List( fields.String, description="List with vendor names", example=[ ".bbsoftware", ".joomclan", ".matteoiammarrone", "0verkill", "1-script", "10-4_aps", "10-strike", "1000guess", "1024_cms", "1024cms", "1024tools", "10web", "111webcalendar", "11in1", "11xiaoli_project", "1234n", "123flashchat", "129zou", "12net", "12planet", "133", "13enforme", "13thmonkey", "163", "1800contacts", "180solutions", "1crm", "1kxun", "1password", ".....", ], ) }, ) browseListVendor = api.model( "browseListVendor", { "product": fields.List( fields.String, description="List with producet CPE's", example=[ ".net_core", ".net_core_sdk", ".net_framework", ".net_framework_developer_pack", ".net_windows_server", "20007_office_system", "27mhz_wireless_keyboard", "365_apps", "access", "active_directory", "active_directory_application_mode", "active_directory_authentication_library", "active_directory_federation_services", "active_directory_lightweight_directory_service", "active_directory_services", "activesync", "activex", "adam", "all_windows", "....", ], ), "vendor": fields.String(description="Vendor name", example="microsoft"), }, ) browseListProduct = api.model( "browseVersions", { "version": fields.List( fields.String, description="List with product CPEs", example=[ "*:*:*:*:*:*:*:*", "1.0:*:*:*:*:*:*:*", "1.1:*:*:*:*:*:*:*", "2.0:*:*:*:*:*:*:*", "....", ], ), "product": fields.String(description="Product name", example=".net_core"), "vendor": fields.String(description="Vendor name", example=".microsoft"), }, ) @api.route("/browse") @api.response(400, "Error processing request", model=message) @api.response(500, "Server error", model=message) class BrowseAll(Resource): @api.marshal_with(browseList) def get(self): """ List vendors Returns a list of vendors. When the link is called, it will return a list of possible vendors. """ browse_list = getBrowseList(None) return browse_list @api.route("/browse/<vendor>") @api.response(400, "Error processing request", model=message) @api.response(500, "Server error", model=message) class BrowseAll(Resource): @api.marshal_with(browseListVendor) def get(self, vendor): """ List products of vendor Returns a list of products of a specific vendor. When the link is called, it enumerates the products for said vendor. """ browseList = getBrowseList(vendor) return browseList @api.route("/browse/<vendor>/<product>") @api.response(400, "Error processing request", model=message) @api.response(500, "Server error", model=message) class BrowseProductVersions(Resource): @api.marshal_with(browseListProduct) def get(self, vendor, product): """ List CPEs of product Returns a list of CPEs of a specific product. When the link is called, it enumerates the CPEs for said product. """ browse_list = getVersionsOfProduct(product) result = {"vendor": vendor, "product": product, "version": browse_list} return result
4,520
Python
.py
136
22.301471
83
0.520733
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,244
cve.py
cve-search_cve-search/web/restapi/cve.py
from flask import request from flask_restx import Namespace, fields, Resource from lib.CVEs import CveHandler from lib.Config import Configuration from lib.Query import qcvesForCPE from web.restapi.cpe_convert import message config = Configuration() api = Namespace("cve", description="Endpoints for requesting cve information", path="/") access_entry = api.model( "access", { "authentication": fields.String( description="This metric describes the level of privileges an attacker must possess before successfully " "exploiting the vulnerability.", example="SINGLE", ), "complexity": fields.String( description="The Attack Complexity metric describes the conditions beyond the attacker's control that must " "exist in order to exploit the vulnerability. As described below, such conditions may require " "the collection of more information about the target, the presence of certain system " "configuration settings, or computational exceptions.", example="LOW", ), "vector": fields.String( description="This metric reflects the context by which vulnerability exploitation is possible. This metric " "value (and consequently the Base score) will be larger the more remote (logically, " "and physically) an attacker can be in order to exploit the vulnerable component.", example="NETWORK", ), }, ) access_V3_entry = api.model( "access_V3", { "attackvector": fields.String( description="This metric reflects the context by which vulnerability exploitation is possible. This metric " "value (and consequently the Base Score) will be larger the more remote (logically, " "and physically) an attacker can be in order to exploit the vulnerable component. The " "assumption is that the number of potential attackers for a vulnerability that could be " "exploited from across a network is larger than the number of potential attackers that could " "exploit a vulnerability requiring physical access to a device, and therefore warrants a " "greater Base Score.", example="NETWORK", ), "attackcomplexity": fields.String( description="This metric describes the conditions beyond the attacker’s control that must exist in order " "to exploit the vulnerability. As described below, such conditions may require the collection " "of more information about the target, or computational exceptions. Importantly, the " "assessment of this metric excludes any requirements for user interaction in order to exploit " "the vulnerability (such conditions are captured in the User Interaction metric). If a " "specific configuration is required for an attack to succeed, the Base metrics should be " "scored assuming the vulnerable component is in that configuration. The Base Score is greatest " "for the least complex attacks.", example="LOW", ), "privilegesrequired": fields.String( description="This metric describes the level of privileges an attacker must possess before successfully " "exploiting the vulnerability. The Base Score is greatest if no privileges are required.", example="NONE", ), "userinteraction": fields.String( description="This metric captures the requirement for a human user, other than the attacker, to " "participate in the successful compromise of the vulnerable component. This metric determines whether the " "vulnerability can be exploited solely at the will of the attacker, or whether a separate user " "(or user-initiated process) must participate in some manner. The Base Score is greatest when " "no user interaction is required.", example="REQUIRED", ), "scope": fields.String( description="The Scope metric captures whether a vulnerability in one vulnerable component impacts " "resources in components beyond its security scope. Formally, a security authority is a " "mechanism (e.g., an application, an operating system, firmware, a sandbox environment) that " "defines and enforces access control in terms of how certain subjects/actors (e.g., human " "users, processes) can access certain restricted objects/resources (e.g., files, CPU, memory) " "in a controlled manner. All the subjects and objects under the jurisdiction of a single " "security authority are considered to be under one security scope. If a vulnerability in a " "vulnerable component can affect a component which is in a different security scope than the " "vulnerable component, a Scope change occurs. Intuitively, whenever the impact of a " "vulnerability breaches a security/trust boundary and impacts components outside the security " "scope in which vulnerable component resides, a Scope change occurs. The security scope of a " "component encompasses other components that provide functionality solely to that component, " "even if these other components have their own security authority. For example, a database " "used solely by one application is considered part of that application’s security scope even " "if the database has its own security authority, e.g., a mechanism controlling access to " "database records based on database users and associated database privileges. The Base Score " "is greatest when a scope change occurs.", example="CHANGED", ), }, ) impact_entry = api.model( "Impact", { "availability": fields.String( description="This metric measures the impact to the availability of the impacted component resulting " "from a successfully exploited vulnerability. While the Confidentiality and Integrity impact " "metrics apply to the loss of confidentiality or integrity of data (e.g., information, files) " "used by the impacted component, this metric refers to the loss of availability of the " "impacted component itself, such as a networked service (e.g., web, database, email). Since " "availability refers to the accessibility of information resources, attacks that consume " "network bandwidth, processor cycles, or disk space all impact the availability of an impacted " "component.", example="COMPLETE", ), "confidentiality": fields.String( description="This metric measures the impact to the confidentiality of the information resources managed " "by a software component due to a successfully exploited vulnerability. Confidentiality refers " "to limiting information access and disclosure to only authorized users, as well as preventing " "access by, or disclosure to, unauthorized ones.", example="COMPLETE", ), "integrity": fields.String( description="This metric measures the impact to integrity of a successfully exploited vulnerability. " "Integrity refers to the trustworthiness and veracity of information.", example="COMPLETE", ), }, ) impact_V3_entry = api.model( "Impact", { "availability": fields.String( description="This metric measures the impact to the availability of the impacted component resulting " "from a successfully exploited vulnerability. While the Confidentiality and Integrity impact " "metrics apply to the loss of confidentiality or integrity of data (e.g., information, files) " "used by the impacted component, this metric refers to the loss of availability of the " "impacted component itself, such as a networked service (e.g., web, database, email). Since " "availability refers to the accessibility of information resources, attacks that consume " "network bandwidth, processor cycles, or disk space all impact the availability of an impacted " "component.", example="HIGH", ), "confidentiality": fields.String( description="This metric measures the impact to the confidentiality of the information resources managed " "by a software component due to a successfully exploited vulnerability. Confidentiality refers " "to limiting information access and disclosure to only authorized users, as well as preventing " "access by, or disclosure to, unauthorized ones.", example="HIGH", ), "integrity": fields.String( description="This metric measures the impact to integrity of a successfully exploited vulnerability. " "Integrity refers to the trustworthiness and veracity of information.", example="HIGH", ), }, ) tax_inner = api.model( "TaxonomyInner", { "Entry_ID": fields.String(description="Taxonomy entry id", example="1499.001"), "Entry_Name": fields.String( description="Taxonomy name", example="Endpoint Denial of Service:OS Exhaustion Flood", ), "URL": fields.String( description="Taxonomy URL", example="https://attack.mitre.org/techniques/T1499/001", ), }, ) tax_wild = fields.Wildcard( fields.Nested(tax_inner), description="Taxonomy mapping id", skip_none=True ) taxonomy_entry = api.model("documents", {"*": tax_wild}) taxonomy = api.model( "Taxonomy", { "ATTACK": fields.Nested( taxonomy_entry, skip_none=True, description="Mitre Att&ck taxonomy", example={ "1499_001": { "Entry_ID": "1499.001", "Entry_Name": "Endpoint Denial of Service:OS Exhaustion Flood", "URL": "https://attack.mitre.org/techniques/T1499/001", }, "1499_004": { "Entry_ID": "1499.004", "Entry_Name": "Endpoint Denial of Service:Application or System Exploitation", "URL": "https://attack.mitre.org/techniques/T1499/004", }, }, ) }, ) execution_inner = api.model( "ExecutionInner", { "Phase": fields.String(description="Execution phase", example="Explore"), "Description": fields.String( description="Execution phase description", example="[Determine application's/system's password policy] Determine the password policies of the target " "application/system.", ), "Techniques": fields.List( fields.String, description="A list of used techniques during the phase", example=[ "Determine minimum and maximum allowed password lengths.", "Determine format of allowed passwords (whether they are required or allowed to contain numbers, " "special characters, etc.).", "Determine account lockout policy (a strict account lockout policy will prevent brute force attacks).", ], ), }, ) execution_wild = fields.Wildcard( fields.Nested(execution_inner), description="Execution phase mapping id", skip_none=True, ) execution_entry = api.model("documents", {"*": execution_wild}) capec_entry = api.model( "Capec_entry", { "id": fields.String(description="ID number of the CAPEC", example="242"), "name": fields.String( description="Name of the CAPEC", example="Code Injection" ), "prerequisites": fields.String( description="Prerequisites of the CAPEC", example="The target software does not validate user-controlled input such that the execution of a process " "may be altered by sending code in through legitimate data channels, using no other mechanism.", ), "related_weakness": fields.List( fields.String, description="List with related CWE numbers", example=["94", "270", "271"], ), "related_capecs": fields.List( fields.String, description="List with related CAPEC numbers", example=["112", "151", "560", "600", "653"], ), "solutions": fields.String( description="Solutions for mitigating the CAPEC", example="Utilize strict type, character, and encoding enforcement Ensure all input content that is " "delivered to client is sanitized against an acceptable content specification. Perform input " "validation for all content. Enforce regular patching of software.", ), "summary": fields.String( description="Summary of the CAPEC", example="An adversary exploits a weakness in input validation on the target to inject new code into that " "which is currently executing. This differs from code inclusion in that code inclusion involves " "the addition or replacement of a reference to a code file, which is subsequently loaded by the " "target and used as part of the code of some application.", ), "loa": fields.String(description="Likelyhood of attack", example="Medium"), "typical_severity": fields.String( description="Typical severity", example="High" ), "taxonomy": fields.Nested( taxonomy, skip_none=True, description="Taxonomy linked to this CAPEC", example={ "ATTACK": { "1499_001": { "Entry_ID": "1499.001", "Entry_Name": "Endpoint Denial of Service:OS Exhaustion Flood", "URL": "https://attack.mitre.org/techniques/T1499/001", }, "1499_004": { "Entry_ID": "1499.004", "Entry_Name": "Endpoint Denial of Service:Application or System Exploitation", "URL": "https://attack.mitre.org/techniques/T1499/004", }, } }, ), "execution_flow": fields.Nested( execution_entry, skip_none=True, description="Phased description of attack execution flow", example={ "1": { "Phase": "Explore", "Description": "[Determine application's/system's password policy] Determine the password policies " "of the target application/system.", "Techniques": [ "Determine minimum and maximum allowed password lengths.", "Determine format of allowed passwords (whether they are required or allowed to contain " "numbers, special characters, etc.).", "Determine account lockout policy (a strict account lockout policy will prevent brute " "force attacks).", ], }, "2": { "Phase": "Exploit", "Description": "[Brute force password] Given the finite space of possible passwords dictated by " "the password policy determined in the previous step, try all possible passwords " "for a known user ID until application/system grants access.", "Techniques": [ "Manually or automatically enter all possible passwords through the application/system's " "interface. In most systems, start with the shortest and simplest possible passwords, because " "most users tend to select such passwords if allowed to do so.", "Perform an offline dictionary attack or a rainbow table attack against a known password hash.", ], }, }, ), }, ) refmap_inner = fields.List( fields.String, description="Reference mappings", example=["https://pastebin.com/QTev1TjM"], ) refmap_wild = fields.Wildcard(refmap_inner, description="Reference mapping id") refmap = api.model("documents", {"*": refmap_wild}) vuln_conf = api.model( "VulnConf", { "id": fields.String( description="ID of the vulnerable configuration", example="cpe:2.3:o:gemteks:wrtm-127acn_firmware:01.01.02.141:*:*:*:*:*:*:*", ), "title": fields.String( description="Title of the vulnerable configuration", example="cpe:2.3:o:gemteks:wrtm-127acn_firmware:01.01.02.141:*:*:*:*:*:*:*", ), }, ) contributors = api.model( "Contributors", { "name": fields.String(description="Contributor name", example="Dragos Prisaca"), "organization": fields.String( description="Organization name", example="Symantec Corporation" ), }, ) def_extensions = api.model( "DefExtensions", { "comment": fields.String( description="Comment", example="Microsoft Windows Vista (32-bit) Service Pack 1 is installed", ), "oval": fields.String( description="Oval reference", example="oval:org.mitre.oval:def:4873" ), }, ) oval_entry = api.model( "OvalEntry", { "accepted": fields.DateTime( description="Oval Date Time", example="2014-06-16T04:00:06.077-04:00" ), "class": fields.String(description="Oval class", example="vulnerability"), "contributors": fields.List( fields.Nested(contributors), skip_none=True, description="List with contributors", example=[ {"name": "Dragos Prisaca", "organization": "Symantec Corporation"}, {"name": "Chandan S", "organization": "SecPod Technologies"}, {"name": "Maria Kedovskaya", "organization": "ALTX-SOFT"}, {"name": "Maria Mikhno", "organization": "ALTX-SOFT"}, ], ), "definition_extensions": fields.List( fields.Nested(def_extensions), skip_none=True, description="List with Definition extensions", example=[ { "comment": "Microsoft Windows Vista (32-bit) Service Pack 1 is installed", "oval": "oval:org.mitre.oval:def:4873", }, { "comment": "Microsoft Windows Vista x64 Edition Service Pack 1 is installed", "oval": "oval:org.mitre.oval:def:5254", }, { "comment": "Microsoft Windows Vista (32-bit) Service Pack 2 is installed", "oval": "oval:org.mitre.oval:def:6124", }, { "comment": "Microsoft Windows Vista x64 Edition Service Pack 2 is installed", "oval": "oval:org.mitre.oval:def:5594", }, { "comment": "Microsoft Windows 7 (32-bit) is installed", "oval": "oval:org.mitre.oval:def:6165", }, { "comment": "Microsoft Windows 7 x64 Edition is installed", "oval": "oval:org.mitre.oval:def:5950", }, { "comment": "Microsoft Windows 7 (32-bit) Service Pack 1 is installed", "oval": "oval:org.mitre.oval:def:12292", }, { "comment": "Microsoft Windows 7 x64 Service Pack 1 is installed", "oval": "oval:org.mitre.oval:def:12627", }, ], ), "description": fields.String( description="Oval description", example="The Bluetooth Stack 2.1 in Microsoft Windows Vista SP1 and SP2 and Windows 7 Gold and SP1 does " "not prevent access to objects in memory that (1) were not properly initialized or (2) have " "been deleted, which allows remote attackers to execute arbitrary code via crafted Bluetooth " "packets, aka 'Bluetooth Stack Vulnerability'.", ), "family": fields.String(description="Oval family", example="windows"), "id": fields.String( description="Oval id", example="oval:org.mitre.oval:def:12094" ), "status": fields.String(description="Oval status", example="accepted"), "submitted": fields.DateTime( description="Oval submitted", example="2011-07-12T13:00:00" ), "title": fields.String( description="Oval title", example="Bluetooth Stack Vulnerability" ), "version": fields.String(description="Oval version", example="52"), }, ) MsBulletin = api.model( "MsBulletin", { "bulletin_id": fields.String( description="MSBulletin id number", example="MS11-053" ), "bulletin_url": fields.String( description="MSBulletin url", example="https://www.windows.com/some_url_to_ms_bulletin", ), "date": fields.DateTime( description="MSBulletin date", example="2011-07-12T00:00:00" ), "impact": fields.String( description="MSBulletin impact", example="Remote Code Execution" ), "knowledgebase_id": fields.String( description="MSBulletin knowledgebase_id", example="2566220" ), "knowledgebase_url": fields.String( description="MSBulletin knowledgebase_url", example="https://www.windows.com/some_url_to_ms_bulletin_knowledge_base", ), "severity": fields.String( description="MSBulletin severity level", example="Critical" ), "title": fields.String( description="MSBulletin title", example="Vulnerability in Bluetooth Stack Could Allow Remote Code Execution", ), }, ) statements = api.model( "Statements", { "contributor": fields.String( description="Statement contributor", example="Tomas Hoger" ), "lastmodified": fields.Date(description="Statement date", example="2009-09-02"), "organization": fields.String( description="Statement organization", example="Red Hat" ), "statement": fields.String( description="Statement", example="This issue did not affect the versions of Linux kernel as shipped with Red Hat Enterprise Linux " "2.1, 3, 4, and Red Hat Enterprise MRG. This issue was addressed in Red Hat Enterprise Linux 5 " "by https://rhn.redhat.com/errata/RHSA-2009-1243.html", ), }, ) redhat_inner = api.model( "RHInner", { "id": fields.String( description="Red Hat Security Advisory id", example="RHSA-2009:1243" ) }, ) redhat_wild = fields.Wildcard( fields.Nested(redhat_inner), description="Red Hat mapping id", skip_none=True ) redhat = api.model("documents", {"*": redhat_wild}) redhat_entry = api.model( "RedHatEntry", { "rpms": fields.List( fields.String, description="List with affected packages", example=[ "kernel-0:2.6.18-164.el5", "kernel-PAE-0:2.6.18-164.el5", "kernel-PAE-debuginfo-0:2.6.18-164.el5", "kernel-PAE-devel-0:2.6.18-164.el5", "kernel-debug-0:2.6.18-164.el5", "kernel-debug-debuginfo-0:2.6.18-164.el5", "kernel-debug-devel-0:2.6.18-164.el5", "kernel-debuginfo-0:2.6.18-164.el5", "kernel-debuginfo-common-0:2.6.18-164.el5", "kernel-devel-0:2.6.18-164.el5", "kernel-doc-0:2.6.18-164.el5", "kernel-headers-0:2.6.18-164.el5", "kernel-kdump-0:2.6.18-164.el5", "kernel-kdump-debuginfo-0:2.6.18-164.el5", "kernel-kdump-devel-0:2.6.18-164.el5", "kernel-xen-0:2.6.18-164.el5", "kernel-xen-debuginfo-0:2.6.18-164.el5", "kernel-xen-devel-0:2.6.18-164.el5", ], ), "advisories": fields.List( fields.Nested(redhat), skip_none=True, description="List with advisories", example=[{"rhsa": {"id": "RHSA-2009:1243"}}], ), }, ) cve_entry_base = api.model( "CVE_Entry_Base", { "modified": fields.DateTime( description="Modified date time", example="2020-10-07T15:01:00" ), "published": fields.DateTime( description="Published date time", example="2020-09-24T15:15:00" ), "access": fields.Nested( access_entry, skip_none=True, description="Access vectors", example={ "authentication": "SINGLE", "complexity": "LOW", "vector": "NETWORK", }, ), "assigner": fields.String( description="Assigner of the CVE", example="cve@mitre.org" ), "capec": fields.List( fields.Nested(capec_entry), skip_none=True, description="CAPEC's related to the CVE", example=[ { "id": "49", "name": "Password Brute Forcing", "prerequisites": "An adversary needs to know a username to target. The system uses password based " "authentication as the one factor authentication mechanism. An application does " "not have a password throttling mechanism in place. A good password throttling " "mechanism will make it almost impossible computationally to brute force a " "password as it may either lock out the user after a certain number of incorrect " "attempts or introduce time out periods. Both of these would make a brute force " "attack impractical.", "related_weakness": [ "257", "262", "263", "307", "308", "309", "521", "654", ], "related_capecs": ["112", "151", "560", "600", "653"], "solutions": "Implement a password throttling mechanism. This mechanism should take into account " "both the IP address and the log in name of the user. Put together a strong password " "policy and make sure that all user created passwords comply with it. Alternatively " "automatically generate strong passwords for users. Passwords need to be recycled to " "prevent aging, that is every once in a while a new password must be chosen.", "summary": "In this attack, the adversary tries every possible value for a password until they " "succeed. A brute force attack, if feasible computationally, will always be successful " "because it will essentially go through all possible passwords given the alphabet " "used (lower case letters, upper case letters, numbers, symbols, etc.) and the maximum " "length of the password. A system will be particularly vulnerable to this type of an " "attack if it does not have a proper enforcement mechanism in place to ensure that " "passwords selected by users are strong passwords that comply with an adequate password " "policy. In practice a pure brute force attack on passwords is rarely used, unless the " "password is suspected to be weak. Other password cracking methods exist that are far " "more effective (e.g. dictionary attacks, rainbow tables, etc.). Knowing the password " "policy on the system can make a brute force attack more efficient. For instance, if " "the policy states that all passwords must be of a certain level, there is no need to " "check smaller candidates.", "loa": "Medium", "typical_severity": "High", "taxonomy": { "ATTACK": { "1110_001": { "Entry_ID": "1110.001", "Entry_Name": "Brute Force:Password Guessing", "URL": "https://attack.mitre.org/techniques/T1110/001", } } }, "execution_flow": { "2": { "Phase": "Exploit", "Description": "[Brute force password] Given the finite space of possible passwords " "dictated by the password policy determined in the previous step, try all " "possible passwords for a known user ID until application/system grants " "access.", "Techniques": [ "Manually or automatically enter all possible passwords through the " "application/system's interface. In most systems, start with the shortest and simplest " "possible passwords, because most users tend to select such passwords if allowed to " "do so.", "Perform an offline dictionary attack or a rainbow table attack against a known " "password hash.", ], }, "1": { "Phase": "Explore", "Description": "[Determine application's/system's password policy] Determine the password " "policies of the target application/system.", "Techniques": [ "Determine minimum and maximum allowed password lengths.", "Determine format of allowed passwords (whether they are required or allowed to " "contain numbers, special characters, etc.).", "Determine account lockout policy (a strict account lockout policy will prevent brute " "force attacks).", ], }, }, }, { "id": "35", "name": "Leverage Executable Code in Non-Executable Files", "prerequisites": "The attacker must have the ability to modify non-executable files consumed by " "the target software.", "related_weakness": [ "264", "270", "272", "275", "282", "59", "714", "94", "95", "96", "97", ], "related_capecs": ["112", "151", "560", "600", "653"], "solutions": "Design: Enforce principle of least privilege Design: Run server interfaces with a " "non-root account and/or utilize chroot jails or other configuration techniques to " "constrain privileges even if attacker gains some limited access to commands. " "Implementation: Perform testing such as pen-testing and vulnerability scanning to " "identify directories, programs, and interfaces that grant direct access to " "executables. Implementation: Implement host integrity monitoring to detect any " "unwanted altering of configuration files. Implementation: Ensure that files that " "are not required to execute, such as configuration files, are not over-privileged, " "i.e. not allowed to execute.", "summary": "An attack of this type exploits a system's trust in configuration and resource files. " "When the executable loads the resource (such as an image file or configuration file) " "the attacker has modified the file to either execute malicious code directly or " "manipulate the target process (e.g. application server) to execute based on the " "malicious configuration parameters. Since systems are increasingly interrelated " "mashing up resources from local and remote sources the possibility of this attack " "occurring is high.", }, { "id": "77", "name": "Manipulating User-Controlled Variables", "prerequisites": "A variable consumed by the application server is exposed to the client. A " "variable consumed by the application server can be overwritten by the user. " "The application server trusts user supplied data to compute business logic. " "The application server does not perform proper input validation.", "related_weakness": ["15", "285", "302", "473", "94", "96"], "solutions": "If the register_globals option is enabled, PHP will create global variables for " "each GET, POST, and cookie variable included in the HTTP request. This means that a " "malicious user may be able to set variables unexpectedly. For instance make sure " "that the server setting for PHP does not expose global variables. A software system " "should be reluctant to trust variables that have been initialized outside of its " "trust boundary. Ensure adequate checking is performed when relying on input from " "outside a trust boundary. Separate the presentation layer and the business logic " "layer. Variables at the business logic layer should not be exposed at the " "presentation layer. This is to prevent computation of business logic from user " "controlled input data. Use encapsulation when declaring your variables. This is to " "lower the exposure of your variables. Assume all input is malicious. Create a white " "list that defines all valid input to the software system based on the requirements " "specifications. Input that does not match against the white list should be rejected " "by the program.", "summary": "This attack targets user controlled variables (DEBUG=1, PHP Globals, and So Forth). " "An attacker can override environment variables leveraging user-supplied, untrusted " "query variables directly used on the application server without any data sanitization. " "In extreme cases, the attacker can change variables controlling the business logic of " "the application. For instance, in languages like PHP, a number of poorly set default " "configurations may allow the user to override variables.", }, ], ), "cvss": fields.Float(description="CVSS score", example=9.0), "impactScore": fields.Float(description="CVSS impact score", example=9.6), "exploitabilityScore": fields.Float( description="CVSS exploitability score", example=9.6 ), "cvssTime": fields.DateTime( description="Time when the CVSS was established", example="2020-10-07T15:01:00", ), "cvssVector": fields.String( description="CVSS Vector string", example="AV:N/AC:L/Au:S/C:C/I:C/A:C" ), "cwe": fields.String( description="CWE number to which this CVE belongs to", example="CWE-94" ), "id": fields.String( description="ID number of the CVE", example="CVE-2020-24365" ), "impact": fields.Nested( impact_entry, skip_none=True, description="Impact vectors", example={ "availability": "COMPLETE", "confidentiality": "COMPLETE", "integrity": "COMPLETE", }, ), "impact3": fields.Nested( impact_V3_entry, skip_none=True, description="CvssV3 impact vectors", example={ "availability": "HIGH", "confidentiality": "HIGH", "integrity": "HIGH", }, ), "exploitability3": fields.Nested( access_V3_entry, skip_none=True, description="CvssV3 access vectors", example={ "attackvector": "NETWORK", "attackcomplexity": "LOW", "privilegesrequired": "NONE", "userinteraction": "REQUIRED", "scope": "CHANGED", }, ), "cvss3": fields.Float(description="CvssV3 score", example=9.6), "impactScore3": fields.Float(description="CvssV3 impact score", example=9.6), "exploitabilityScore3": fields.Float( description="CvssV3 exploitability score", example=9.6 ), "cvss3-vector": fields.String( description="CvssV3 Vector string", example="CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H", ), "lastModified": fields.DateTime( description="Last modified date time", example="2020-10-07T15:01:00" ), "references": fields.List( fields.String, description="CVE references", example=["https://pastebin.com/QTev1TjM"], ), "summary": fields.String( description="CVE Summary", example="An issue was discovered on Gemtek WRTM-127ACN 01.01.02.141 and WRTM-127x9 01.01.02.127 devices. " "The Monitor Diagnostic network page allows an authenticated attacker to execute a command directly " "on the target machine. Commands are executed as the root user (uid 0). (Even if a login is " "required, most routers are left with default credentials.)", ), }, ) cve_entry = api.inherit( "CVE_Entry_Full", cve_entry_base, { "refmap": fields.Nested( refmap, skip_none=True, description="CVE Reference mapping", example={"misc": ["https://pastebin.com/QTev1TjM"]}, ), "vulnerable_configuration": fields.List( fields.Nested(vuln_conf), skip_none=True, description="Vulnerable configurations CPE's", example=[ { "id": "cpe:2.3:o:gemteks:wrtm-127acn_firmware:01.01.02.141:*:*:*:*:*:*:*", "title": "cpe:2.3:o:gemteks:wrtm-127acn_firmware:01.01.02.141:*:*:*:*:*:*:*", }, { "id": "cpe:2.3:h:gemteks:wrtm-127acn:-:*:*:*:*:*:*:*", "title": "cpe:2.3:h:gemteks:wrtm-127acn:-:*:*:*:*:*:*:*", }, { "id": "cpe:2.3:o:gemteks:wrtm-127x9_firmware:01.01.02.127:*:*:*:*:*:*:*", "title": "cpe:2.3:o:gemteks:wrtm-127x9_firmware:01.01.02.127:*:*:*:*:*:*:*", }, { "id": "cpe:2.3:h:gemteks:wrtm-127x9:-:*:*:*:*:*:*:*", "title": "cpe:2.3:h:gemteks:wrtm-127x9:-:*:*:*:*:*:*:*", }, ], ), "vulnerable_configuration_cpe_2_2": fields.List( fields.Nested(vuln_conf), skip_none=True, description="Vulnerable configurations CPE's", example=[ { "id": "cpe:2.3:o:gemteks:wrtm-127acn_firmware:01.01.02.141:*:*:*:*:*:*:*", "title": "cpe:2.3:o:gemteks:wrtm-127acn_firmware:01.01.02.141:*:*:*:*:*:*:*", }, { "id": "cpe:2.3:h:gemteks:wrtm-127acn:-:*:*:*:*:*:*:*", "title": "cpe:2.3:h:gemteks:wrtm-127acn:-:*:*:*:*:*:*:*", }, { "id": "cpe:2.3:o:gemteks:wrtm-127x9_firmware:01.01.02.127:*:*:*:*:*:*:*", "title": "cpe:2.3:o:gemteks:wrtm-127x9_firmware:01.01.02.127:*:*:*:*:*:*:*", }, { "id": "cpe:2.3:h:gemteks:wrtm-127x9:-:*:*:*:*:*:*:*", "title": "cpe:2.3:h:gemteks:wrtm-127x9:-:*:*:*:*:*:*:*", }, ], ), "vulnerable_product": fields.List( fields.String, description="Vulnerable products CPE's", example=[ "cpe:2.3:o:gemteks:wrtm-127acn_firmware:01.01.02.141:*:*:*:*:*:*:*", "cpe:2.3:o:gemteks:wrtm-127x9_firmware:01.01.02.127:*:*:*:*:*:*:*", ], ), "oval": fields.List( fields.Nested(oval_entry), skip_none=True, description="List with Oval entries", example=[ { "accepted": "2014-06-16T04:00:06.077-04:00", "class": "vulnerability", "contributors": [ { "name": "Dragos Prisaca", "organization": "Symantec Corporation", }, {"name": "Chandan S", "organization": "SecPod Technologies"}, {"name": "Maria Kedovskaya", "organization": "ALTX-SOFT"}, {"name": "Maria Mikhno", "organization": "ALTX-SOFT"}, ], "definition_extensions": [ { "comment": "Microsoft Windows Vista (32-bit) Service Pack 1 is installed", "oval": "oval:org.mitre.oval:def:4873", }, { "comment": "Microsoft Windows Vista x64 Edition Service Pack 1 is installed", "oval": "oval:org.mitre.oval:def:5254", }, { "comment": "Microsoft Windows Vista (32-bit) Service Pack 2 is installed", "oval": "oval:org.mitre.oval:def:6124", }, { "comment": "Microsoft Windows Vista x64 Edition Service Pack 2 is installed", "oval": "oval:org.mitre.oval:def:5594", }, { "comment": "Microsoft Windows 7 (32-bit) is installed", "oval": "oval:org.mitre.oval:def:6165", }, { "comment": "Microsoft Windows 7 x64 Edition is installed", "oval": "oval:org.mitre.oval:def:5950", }, { "comment": "Microsoft Windows 7 (32-bit) Service Pack 1 is installed", "oval": "oval:org.mitre.oval:def:12292", }, { "comment": "Microsoft Windows 7 x64 Service Pack 1 is installed", "oval": "oval:org.mitre.oval:def:12627", }, ], "description": "The Bluetooth Stack 2.1 in Microsoft Windows Vista SP1 and SP2 and Windows 7 Gold " "and SP1 does not prevent access to objects in memory that (1) were not properly " "initialized or (2) have been deleted, which allows remote attackers to execute " 'arbitrary code via crafted Bluetooth packets, aka "Bluetooth Stack Vulnerability."', "family": "windows", "id": "oval:org.mitre.oval:def:12094", "status": "accepted", "submitted": "2011-07-12T13:00:00", "title": "Bluetooth Stack Vulnerability", "version": "52", } ], ), "msbulletin": fields.List( fields.Nested(MsBulletin), skip_none=True, description="List with msbulletins", example=[ { "bulletin_id": "MS11-053", "bulletin_url": "null", "date": "2011-07-12T00:00:00", "impact": "Remote Code Execution", "knowledgebase_id": "2566220", "knowledgebase_url": "null", "severity": "Critical", "title": "Vulnerability in Bluetooth Stack Could Allow Remote Code Execution", } ], ), "statements": fields.List( fields.Nested(statements), skip_none=True, description="List with statements", example=[ { "contributor": "Tomas Hoger", "lastmodified": "2009-09-02", "organization": "Red Hat", "statement": "This issue did not affect the versions of Linux kernel as shipped with Red Hat " "Enterprise Linux 2.1, 3, 4, and Red Hat Enterprise MRG. This issue was addressed " "in Red Hat Enterprise Linux 5 by https://rhn.redhat.com/errata/RHSA-2009-1243.html", } ], ), "redhat": fields.Nested( redhat_entry, skip_none=True, description="Redhat Security advisories", example={ "advisories": [{"rhsa": {"id": "RHSA-2009:1243"}}], "rpms": [ "kernel-0:2.6.18-164.el5", "kernel-PAE-0:2.6.18-164.el5", "kernel-PAE-debuginfo-0:2.6.18-164.el5", "kernel-PAE-devel-0:2.6.18-164.el5", "kernel-debug-0:2.6.18-164.el5", "kernel-debug-debuginfo-0:2.6.18-164.el5", "kernel-debug-devel-0:2.6.18-164.el5", "kernel-debuginfo-0:2.6.18-164.el5", "kernel-debuginfo-common-0:2.6.18-164.el5", "kernel-devel-0:2.6.18-164.el5", "kernel-doc-0:2.6.18-164.el5", "kernel-headers-0:2.6.18-164.el5", "kernel-kdump-0:2.6.18-164.el5", "kernel-kdump-debuginfo-0:2.6.18-164.el5", "kernel-kdump-devel-0:2.6.18-164.el5", "kernel-xen-0:2.6.18-164.el5", "kernel-xen-debuginfo-0:2.6.18-164.el5", "kernel-xen-devel-0:2.6.18-164.el5", ], }, ), }, ) cve_last_entries = api.inherit( "CVE_Entry_last", cve_entry_base, { "vulnerable_configuration": fields.List( fields.String, description="Vulnerable configurations CPE's", example=[ "cpe:2.3:o:gemteks:wrtm-127acn_firmware:01.01.02.141:*:*:*:*:*:*:*", "cpe:2.3:o:gemteks:wrtm-127x9_firmware:01.01.02.127:*:*:*:*:*:*:*", ], ), "vulnerable_configuration_cpe_2_2": fields.List( fields.String, description="Vulnerable configurations CPE's", example=[ "cpe:2.3:o:gemteks:wrtm-127acn_firmware:01.01.02.141:*:*:*:*:*:*:*", "cpe:2.3:o:gemteks:wrtm-127x9_firmware:01.01.02.127:*:*:*:*:*:*:*", ], ), "vulnerable_product": fields.List( fields.String, description="Vulnerable products CPE's", example=[ "cpe:2.3:o:gemteks:wrtm-127acn_firmware:01.01.02.141:*:*:*:*:*:*:*", "cpe:2.3:o:gemteks:wrtm-127x9_firmware:01.01.02.127:*:*:*:*:*:*:*", ], ), }, ) search_entries = api.model( "SearchEntries", { "results": fields.List( fields.Nested(cve_last_entries), description="CVE results", example=[ { "modified": "2018-10-12T21:29:00", "published": "1999-05-07T04:00:00", "access": { "authentication": "NONE", "complexity": "HIGH", "vector": "NETWORK", }, "assigner": "cve@mitre.org", "cvss": 2.6, "impactScore": 3.0, "exploitabilityScore": 3.0, "cvssTime": "2018-10-12T21:29:00", "cvssVector": "AV:N/AC:H/Au:N/C:N/I:P/A:N", "cwe": "NVD-CWE-Other", "id": "CVE-1999-0717", "impact": { "availability": "NONE", "confidentiality": "NONE", "integrity": "PARTIAL", }, "impact3": { "availability": "HIGH", "confidentiality": "HIGH", "integrity": "HIGH", }, "exploitability3": { "attackvector": "NETWORK", "attackcomplexity": "LOW", "privilegesrequired": "NONE", "userinteraction": "REQUIRED", "scope": "CHANGED", }, "cvss3": 9.6, "impactScore3": 3.0, "exploitabilityScore3": 6.6, "cvss3-vector": "CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H", "lastModified": "2018-10-12T21:29:00", "references": [ "http://support.microsoft.com/default.aspx?scid=kb;[LN];Q231304", "https://docs.microsoft.com/en-us/security-updates/securitybulletins/1999/ms99-014", ], "summary": "A remote attacker can disable the virus warning mechanism in Microsoft Excel 97.", "vulnerable_configuration": [ "cpe:2.3:a:microsoft:excel:*:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_2000:*:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_95:*:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_98:*:gold:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_nt:*:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_nt:4.0:*:*:*:*:*:*:*", ], "vulnerable_configuration_cpe_2_2": [], "vulnerable_product": [ "cpe:2.3:a:microsoft:excel:*:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_2000:*:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_95:*:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_98:*:gold:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_nt:*:*:*:*:*:*:*:*", "cpe:2.3:o:microsoft:windows_nt:4.0:*:*:*:*:*:*:*", ], }, { "modified": "2018-10-12T21:29:00", "published": "1999-10-01T04:00:00", "access": { "authentication": "NONE", "complexity": "LOW", "vector": "LOCAL", }, "assigner": "cve@mitre.org", "cvss": 4.6, "impactScore": 3.0, "exploitabilityScore": 3.0, "cvssTime": "2018-10-12T21:29:00", "cvssVector": "AV:L/AC:L/Au:N/C:P/I:P/A:P", "cwe": "CWE-59", "id": "CVE-1999-0794", "impact": { "availability": "PARTIAL", "confidentiality": "PARTIAL", "integrity": "PARTIAL", }, "impact3": { "availability": "HIGH", "confidentiality": "HIGH", "integrity": "HIGH", }, "exploitability3": { "attackvector": "NETWORK", "attackcomplexity": "LOW", "privilegesrequired": "NONE", "userinteraction": "REQUIRED", "scope": "CHANGED", }, "cvss3": 9.6, "impactScore3": 3.0, "exploitabilityScore3": 6.6, "cvss3-vector": "CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H", "lastModified": "2018-10-12T21:29:00", "references": [ "http://support.microsoft.com/default.aspx?scid=kb;[LN];Q241900", "http://support.microsoft.com/default.aspx?scid=kb;[LN];Q241901", "http://support.microsoft.com/default.aspx?scid=kb;[LN];Q241902", "https://docs.microsoft.com/en-us/security-updates/securitybulletins/1999/ms99-044", ], "summary": "Microsoft Excel does not warn a user when a macro is present in a Symbolic Link " "(SYLK) format file.", "vulnerable_configuration": [ "cpe:2.3:a:microsoft:excel:*:*:*:*:*:*:*:*", "cpe:2.3:a:microsoft:office:*:*:*:*:*:*:*:*", ], "vulnerable_configuration_cpe_2_2": [], "vulnerable_product": ["cpe:2.3:a:microsoft:excel:*:*:*:*:*:*:*:*"], }, ], ), "total": fields.Integer( description="Total amount of records matching this search criteria", example="1337", ), }, ) @api.route("/cve/<cveid>") @api.param("cveid", "CVE number", example="CVE-2016-3333", required=True) @api.response(400, "Error processing request", model=message) @api.response(404, "The requested CVE is not found", model=message) @api.response(500, "Server error", model=message) class CveId(Resource): @api.marshal_with(cve_entry, skip_none=True) def get(self, cveid): """ CVE from CVE ID Outputs all available information for the specified CVE (Common Vulnerability and Exposure), in JSON format. This information includes basic CVE information like CVSS (Common Vulnerability Scoring System), related CPE (Common Product Enumeration), CWE (Common Weakness Enumeration), etc as well as additional information (RedHat Advisories etc). """ cvesp = CveHandler( rankinglookup=True, namelookup=True, via4lookup=True, capeclookup=True ) cve = cvesp.getcve(cveid=cveid.upper()) if cve is None: api.abort(404, "The requested CVE is not found") else: return cve @api.route("/cvefor/<path:cpe>") @api.param( "cpe", "CPE code. Accepts both CPE v2.2 URI & CPE v2.3 formatted string", example="cpe:2.3:o:gemteks:wrtm-127acn_firmware:01.01.02.141:\*:\*:\*:\*:\*:\*:\*", required=True, ) @api.param( "limit", "Limit the amount of returned documents. (Regardless the value, the maximum amount of documents comes from configuration parameter API:CVEMaxLimit.)", example=10, default=500, _in="query", ) @api.response(400, "Error processing request", model=message) @api.response(404, "No cves found", model=message) @api.response(500, "Server error", model=message) class CveFor(Resource): @api.marshal_list_with(cve_entry, skip_none=True) def get(self, cpe, set_limit=500): """ CVE's from CPE ID Outputs a list of CVEs related to the product """ limit = request.args.get("limit", None) if limit is None: limit = set_limit elif int(limit) < int(config.getCVEMaxLimit()): limit = int(limit) else: limit = int(config.getCVEMaxLimit()) cves = qcvesForCPE(cpe, int(limit)) if len(cves) == 0: api.abort(404, "No cves found") else: return cves @api.route("/last") @api.param( "limit", "Limit the amount of returned documents. (Regardless the value, the maximum amount of documents comes from configuration parameter API:CVEMaxLimit.)", example=10, default=30, _in="query", ) @api.response(400, "Error processing request", model=message) @api.response(404, "No cves found", model=message) @api.response(500, "Server error", model=message) class CveLast(Resource): @api.marshal_list_with(cve_last_entries, skip_none=True) def get(self, set_limit=30): """ List last CVE's Outputs the last n amount of vulnerabilities. If the limit is not specified, the default of 30 is used. """ limit = request.args.get("limit", None) if limit is None: limit = set_limit elif int(limit) < int(config.getCVEMaxLimit()): limit = int(limit) else: limit = int(config.getCVEMaxLimit()) cvesp = CveHandler( rankinglookup=True, namelookup=True, via4lookup=True, capeclookup=True ) cve = cvesp.get(limit=limit) if len(cve) == 0: api.abort(404, "No cves found") else: return cve @api.route("/search/<vendor>/<path:product>") @api.param("vendor", "Vendor name", example="microsoft", required=True) @api.param("product", "Product name", example="excel", required=True) @api.response(400, "Error processing request", model=message) @api.response(404, "No cves found", model=message) @api.response(500, "Server error", model=message) class SearchCve(Resource): @api.marshal_with(search_entries) def get(self, vendor, product): """ Search CVE by vendor When vendor and product are specified, this API call returns a list of CVEs related to the product. The output of the browse call can be used for this. """ from lib.DatabaseLayer import cvesForCPE search = (vendor, product) return cvesForCPE(search, strict_vendor_product=True)
60,239
Python
.py
1,228
34.543974
154
0.540827
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,245
cpe_convert.py
cve-search_cve-search/web/restapi/cpe_convert.py
from flask_restx import Namespace, Resource, fields from lib.Toolkit import toOldCPE, toStringFormattedCPE api = Namespace( "cpe", description="Endpoints for cpe conversion between different versions", path="/", ) message = api.model( "Message", { "message": fields.String( description="The response message", example="The messages indicating the cause or reason for failure or success.", ) }, ) @api.route("/cpe2.2/<path:cpe>") @api.param( "cpe", "CPE v2.3 formatted string", example="cpe:2.3:o:microsoft:windows_11:-:\*:\*:\*:\*:\*:x64:\*", required=True, ) @api.response( 200, "CPE converted", model=fields.String( description="CPE code converted to CPE v2.2 URI", example="cpe:/o:microsoft:windows_11:-::~~~~x64~", ), ) @api.response(400, "Error processing request", model=message) @api.response(500, "Server error", model=message) class Cpe3To2(Resource): def get(self, cpe): """ convert 3 to 2 Converts a CPE v2.3 formatted string to corresponding CPE v2.2 URI, stripped of appendices. CPE v2.2 is the old standard, and is a lot less uniform than the CPE v2.3 standard. """ cpe = toOldCPE(cpe) if cpe is False: return api.abort( 400, "Conversion failed, the CPE v2.3 formatted string you provided cannot be converted", ) else: return cpe @api.route("/cpe2.3/<path:cpe>") @api.param( "cpe", "CPE code in cpe2.2 format", example="cpe:/o:microsoft:windows_11:-::~~~~x64~", required=True, ) @api.response( 200, "CPE converted", model=fields.String( description="CPE code converted to CPE v2.3 formatted string", example="cpe:2.3:o:microsoft:windows_11:-:*:*:*:*:*:x64:*", ), ) @api.response(400, "Error processing request", model=message) @api.response(500, "Server error", model=message) class Cpe2To3(Resource): def get(self, cpe): """ convert 2 to 3 Converts a CPE v2.2 URI to corresponding CPE v2.3 formatted string. CPE v2.3 is the newer standard, and is a lot more uniform and easier to read than the CPE v2.2 standard. """ cpe = toStringFormattedCPE(cpe) if cpe is False: return api.abort( 400, "Conversion failed, the CPE v2.2 URI you provided cannot be converted", ) else: return cpe
2,536
Python
.py
80
25.1875
112
0.618308
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,246
dbinfo.py
cve-search_cve-search/web/restapi/dbinfo.py
from flask_restx import Namespace, fields, Resource from web.restapi.cpe_convert import message api = Namespace( "dbinfo", description="Endpoints displaying information about the cve search database", path="/", ) database_inner = api.model( "DBInner", { "last_update": fields.DateTime( description="Date time of last update", example="2019-09-30T18:53:48" ), "size": fields.Integer( description="Amount of documents in collection", example="570" ), }, ) database_wild = fields.Wildcard( fields.Nested(database_inner), description="Database collection mapping id", skip_none=True, ) database_entry = api.model("documents", {"*": database_wild}) @api.route("/dbinfo") @api.response(400, "Error processing request", model=message) @api.response(500, "Server error", model=message) class DBInfo(Resource): @api.marshal_with(database_entry) def get(self): """ Get Database info Returns the stats of the database. When the user authenticates, more information is returned. This information includes: <ul> <li> Amount of whitelist and blacklist records </li> <li> Some server settings like the database name </li> <li> Some database information like disk usage </li> </ul> Unauthenticated queries return only collection information. """ from lib.DatabaseLayer import getDBStats return getDBStats()
1,511
Python
.py
43
29.023256
101
0.674211
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,247
flask_authentication.py
cve-search_cve-search/web/helpers/flask_authentication.py
from lib.Authentication import AuthenticationHandler class FlaskAuthHandler(object): def __init__(self, app=None, **kwargs): self.kwargs = kwargs if app is not None: self.init_app(app) def init_app(self, app, **kwargs): self.kwargs.update(kwargs) app.auth_handler = AuthenticationHandler() def __repr__(self): return "<< FlaskAuthHandler >>"
412
Python
.py
11
30.090909
52
0.648101
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,248
flask_database.py
cve-search_cve-search/web/helpers/flask_database.py
from lib.DatabaseHandler import DatabaseHandler class FlaskDatabaseHandler(object): def __init__(self, app=None, **kwargs): self.kwargs = kwargs if app is not None: self.init_app(app) def init_app(self, app, **kwargs): self.kwargs.update(kwargs) app.dbh = DatabaseHandler() def __repr__(self): return "<< FlaskDatabaseHandler >>"
400
Python
.py
11
29
47
0.639687
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,249
app_plugin.py
cve-search_cve-search/web/helpers/app_plugin.py
from flask import current_app from flask_plugins import Plugin class AppPlugin(Plugin): def register_blueprint(self, blueprint, **kwargs): """Registers a blueprint.""" current_app.register_blueprint(blueprint, **kwargs)
242
Python
.py
6
35.666667
59
0.739316
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,250
common.py
cve-search_cve-search/web/helpers/common.py
import calendar from datetime import datetime date_time_formats = [ "%d-%m-%Y", "%Y-%m-%d", "%d-%m-%Y %H:%M", "%Y-%m-%d %H:%M:%S", "%H:%M:%S %d-%m-%Y", "%Y-%m-%dT%H:%M:%S", "%Y-%m-%dT%H:%M:%SZ", "%Y-%m-%dT%H:%M:%S.%f", "%Y-%m-%dT%H:%M:%S,%f", "%Y-%m-%dT%H:%M:%S.%fZ", "%Y-%m-%dT%H:%M:%S,%fZ", ] def timestringTOdatetime(timestring): """ Method to convert a given date time string into a datetime object. Timestring is matched to the date_time_formats 'date time string formats' list. If matched will return a datetime object; will return False otherwise. :param timestring: date time string :type timestring: str :return: Datetime object :rtype: datetime """ match = False # try to match string formats to given string for each in date_time_formats: try: match = datetime.strptime(timestring, each) except ValueError: continue return match def datetimeTOtimestamp(date_time_object): """ Method that will take the provided date time and converts it into a timestamp :param date_time_object: date time object :type date_time_object: datetime :return: unix timestamp :rtype: int """ return calendar.timegm(date_time_object.utctimetuple()) def timestampTOdatetime(timestamp): """ Method that will take the provided timestamp and converts it into a date time object :param timestamp: unix timestamp :type timestamp: int :return: date time object :rtype: datetime """ value = datetime.utcfromtimestamp(timestamp) return value
1,635
Python
.py
51
26.843137
117
0.647546
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,251
server_side_datatables.py
cve-search_cve-search/web/helpers/server_side_datatables.py
""" server_side_datatables.py ========================= """ from collections import namedtuple, defaultdict class ServerSideDataTable(object): """ This class holds all the logic for enabling and handling server side DataTables within the application :param request: The post (or get) parameters send by the client side of DataTables :type request: flask.request :param backend: Handler to the backend :type backend: DatabasePluginBase """ def __init__(self, request, backend, additional_filters=None): self.request_values = request.values self.backend = backend self.additional_filters = additional_filters self.columns, self.ordering, self.results, self.fields, self.data_length = ( None, None, None, None, None, ) self.total, self.total_filtered, self.current_draw = 0, 0, 0 self.filtered = {} self.sort = [] self._pre_fetch_processing() def output_result(self): retdata = { "draw": int(self.current_draw), "recordsTotal": int(self.total), "recordsFiltered": int(self.total_filtered), "data": self.results, } return retdata def _pre_fetch_processing(self): """ Method to provision the necessary variables for the correct retrieval of the results from the MongoDB Database """ self.current_draw = int(self.request_values["draw"]) self.data_length = self.__data_dimension() self.columns, self.ordering = self.backend.datatables_data_columns_ordering( self.request_values ) self.sort = self.backend.datatables_data_order(self.ordering, self.columns) self.fields = defaultdict(int) for each in self.columns: self.fields[self.columns[each]["data"]] = 1 if len(self.sort) == 0: self.sort = None if self.additional_filters is not None: self.total = self.backend.count( self.request_values["retrieve"], self.additional_filters ) else: self.total = self.backend.count(self.request_values["retrieve"]) self.filtered = self.backend.datatables_data_filter( self.request_values, self.columns, self.additional_filters ) self._fetch_results() if len(self.filtered) != 0: self.total_filtered = self.backend.count( self.request_values["retrieve"], self.filtered ) else: self.total_filtered = self.total def _fetch_results(self): """ Method responsible for querying the backend and fetching the results from the database """ self.results = self.backend.query_docs( retrieve=self.request_values["retrieve"], dict_filter=self.filtered, query_filter=self.fields, sort=self.sort, limit=self.data_length.length, skip=self.data_length.start, ) def __data_dimension(self): """ Method responsible for retrieving the requested start and length parameters from the DataTables request values :return: Namedtuple 'data_length' with a start and length attribute :rtype: namedtuple """ data_length = namedtuple("data_length", ["start", "length"]) data_length.start = int(self.request_values["start"]) data_length.length = int(self.request_values["length"]) return data_length
3,610
Python
.py
89
30.977528
118
0.618229
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,252
utils.py
cve-search_cve-search/web/home/utils.py
import re from html import escape from flask import request from flask_login import current_user from lib.Config import Configuration from lib.Toolkit import tk_compile from sbin.db_blacklist import insertBlacklist from sbin.db_whitelist import insertWhitelist from web.helpers.common import timestringTOdatetime config = Configuration() defaultFilters = { "timeSelect": "all", "startDate": "", "endDate": "", "timeTypeSelect": "modified", "cvssSelect": "all", "cvss": "0", "rejectedSelect": "hide", } config_args = { "pageLength": config.getPageLength(), "listLogin": config.listLoginRequired(), "minimal": True, } def addCPEToList(cpe, listType, cpeType=None): def addCPE(cpe, cpeType, funct): return True if funct(cpe, cpeType) else False if not cpeType: cpeType = "cpe" if listType.lower() in ("blacklist", "black", "b", "bl"): return addCPE(cpe, cpeType, insertBlacklist) if listType.lower() in ("whitelist", "white", "w", "wl"): return addCPE(cpe, cpeType, insertWhitelist) def list_mark(listed, cveList): from lib.DatabaseLayer import getRules if listed not in ["white", "black"]: return list(cveList) items = tk_compile(getRules(listed + "list")) # check the cpes (full or partially) in the black/whitelist for i, cve in enumerate( list(cveList) ): # the list() is to ensure we don't have a pymongo cursor object for c in cve["vulnerable_configuration"]: if any(regex.match(c) for regex in items): cveList[i][listed + "listed"] = "yes" return cveList def generate_minimal_query(f): query = [] # retrieving lists if f["rejectedSelect"] == "hide": query.append( { "summary": re.compile( r"^(?!\*\* REJECT \*\*\s+DO NOT USE THIS CANDIDATE NUMBER.*)" ) } ) # cvss / cvss3 logic if "cvssVersion" in f: if f["cvssVersion"] == "V2": cvss_filter_field = "cvss" else: cvss_filter_field = "cvss3" else: cvss_filter_field = "cvss3" if f["cvssSelect"] == "above": query.append({cvss_filter_field: {"$gt": float(f["cvss"])}}) elif f["cvssSelect"] == "equals": query.append({cvss_filter_field: float(f["cvss"])}) elif f["cvssSelect"] == "below": query.append({cvss_filter_field: {"$lt": float(f["cvss"])}}) # date logic if f["timeSelect"] != "all": if f["startDate"]: startDate = timestringTOdatetime(f["startDate"]) if f["endDate"]: endDate = timestringTOdatetime(f["endDate"]) if f["timeSelect"] == "from": query.append({f["timeTypeSelect"]: {"$gt": startDate}}) elif f["timeSelect"] == "until": query.append({f["timeTypeSelect"]: {"$lt": endDate}}) elif f["timeSelect"] == "between": query.append({f["timeTypeSelect"]: {"$gt": startDate, "$lt": endDate}}) elif f["timeSelect"] == "outside": query.append( { "$or": [ {f["timeTypeSelect"]: {"$lt": startDate}}, {f["timeTypeSelect"]: {"$gt": endDate}}, ] } ) return query def generate_full_query(f): from lib.DatabaseLayer import getRules query = generate_minimal_query(f) if current_user.is_authenticated: if f["blacklistSelect"] == "on": regexes = getRules("blacklist") if len(regexes) != 0: exp = "^(?!" + "|".join(regexes) + ")" query.append( { "$or": [ {"vulnerable_configuration": re.compile(exp)}, {"vulnerable_configuration": {"$exists": False}}, {"vulnerable_configuration": []}, ] } ) if f["whitelistSelect"] == "hide": regexes = getRules("whitelist") if len(regexes) != 0: exp = "^(?!" + "|".join(regexes) + ")" query.append( { "$or": [ {"vulnerable_configuration": re.compile(exp)}, {"vulnerable_configuration": {"$exists": False}}, {"vulnerable_configuration": []}, ] } ) if f["unlistedSelect"] == "hide": wlregexes = tk_compile(getRules("whitelist")) blregexes = tk_compile(getRules("blacklist")) query.append( { "$or": [ {"vulnerable_configuration": {"$in": wlregexes}}, {"vulnerable_configuration": {"$in": blregexes}}, ] } ) return query def filter_logic(filters, skip, limit=None): from lib.DatabaseLayer import getCVEs query = generate_full_query(filters) limit = limit if limit else config_args["pageLength"] cve = getCVEs(limit=limit, skip=skip, query=query) # marking relevant records if current_user.is_authenticated: if filters["whitelistSelect"] == "on": cve["results"] = list_mark("white", cve["results"]) if filters["blacklistSelect"] == "mark": cve["results"] = list_mark("black", cve["results"]) return cve def getFilterSettingsFromPost(r): from lib.DatabaseLayer import getCVEs filters = dict(request.form) errors = False # retrieving data try: cve = filter_logic(filters, r) except Exception: cve = getCVEs(limit=config_args["pageLength"], skip=r) errors = True return {"filters": filters, "cve": cve, "errors": errors} def markCPEs(cve): from lib.DatabaseLayer import getRules blacklist = tk_compile(getRules("blacklist")) whitelist = tk_compile(getRules("whitelist")) for conf in cve["vulnerable_configuration"]: conf["list"] = "none" conf["match"] = "none" for w in whitelist: if w.match(conf["id"]): conf["list"] = "white" conf["match"] = w for b in blacklist: if b.match(conf["id"]): conf["list"] = "black" conf["match"] = b return cve def filterUpdateField(data): if not data: return data returnvalue = [] for line in data.split("\n"): if ( not line.startswith("[+]Success to create index") and not line == "Not modified" and not line.startswith("Starting") ): returnvalue.append(line) return "\n".join(returnvalue) def validateFilter(filter_params): # CVSS must be a number betreen 0 and 10. try: cvss = float(filter_params["cvss"]) if cvss > 10: return False if cvss < 0: return False except ValueError: return False # Require valid options for selections. if filter_params["cvssSelect"] not in ["all", "above", "equals", "below"]: return False if filter_params["cvssVersion"] not in ["V2", "V3"]: return False if filter_params["rejectedSelect"] not in ["hide", "show"]: return False if filter_params["timeSelect"] not in [ "all", "from", "until", "between", "outside", ]: return False if filter_params["timeTypeSelect"] not in [ "modified", "published", "lastModified", ]: return False if filter_params["blacklistSelect"] not in ["on", "off", "mark"]: return False if filter_params["whitelistSelect"] not in ["on", "off", "hide"]: return False if filter_params["unlistedSelect"] not in ["hide", "show"]: return False # Validate dates: required values and reasonable ranges. if filter_params["timeSelect"] in ["from", "between", "outside"]: startDate = timestringTOdatetime(filter_params["startDate"]) if not startDate: return False if filter_params["timeSelect"] in ["until", "between", "outside"]: endDate = timestringTOdatetime(filter_params["endDate"]) if not endDate: return False if filter_params["timeSelect"] in ["between", "outside"]: if startDate > endDate: return False # None of the tests failed. return True def SanitizeUserInput(filter_params): """ Method to sanitize user input :param filter_params: Dictionary with filter params :type filter_params: dict :return: Sanitized filter params :rtype: dict """ for each in filter_params: filter_params[each] = escape(filter_params[each]) return filter_params def adminInfo(output=None): from lib.DatabaseLayer import getDBStats return {"stats": getDBStats(True), "updateOutput": filterUpdateField(output)} def parse_headers(headers): ret_dict = {} for key, val in headers.items(): ret_dict[key] = val return ret_dict
9,299
Python
.py
256
26.972656
83
0.563105
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,253
__init__.py
cve-search_cve-search/web/home/__init__.py
from flask import Blueprint home = Blueprint("home", __name__) from . import views
85
Python
.py
3
26.666667
34
0.75
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,254
views.py
cve-search_cve-search/web/home/views.py
import re from collections import defaultdict from flask import render_template, request, make_response, json, jsonify, url_for from flask_breadcrumbs import register_breadcrumb, default_breadcrumb_root from flask_login import current_user from lib.CVEs import CveHandler from . import home from .utils import ( defaultFilters, config_args, markCPEs, generate_full_query, validateFilter, SanitizeUserInput, ) from ..helpers.server_side_datatables import ServerSideDataTable from ..run import app default_breadcrumb_root(home, ".") @home.route("/", methods=["GET"]) @register_breadcrumb(home, ".", "Home") def index(): return render_template("index.html", **config_args) def view_vendor_name(*args, **kwargs): try: return [ {"text": "Vendor-List", "url": "{}browse".format(url_for("home.index"))}, { "text": "{}".format(request.view_args["vendor"]), "url": "{}browse/{}".format( url_for("home.index"), request.view_args["vendor"] ), }, ] except KeyError: return [{"text": "Vendor-List", "url": "browse"}] @home.route("/browse") @home.route("/browse/<vendor>") @register_breadcrumb(home, ".browse", "", dynamic_list_constructor=view_vendor_name) def browse_vendor(vendor=None): if vendor is None: return render_template("browse_vendor.html", **config_args) else: data = { "vendor": vendor, "product": [ x for x in app.dbh.connection.store_cves.distinct( "products", {"vendors": vendor} ) if x is not None ], } return render_template( "browse.html", product=data["product"], vendor=data["vendor"] ) @home.route("/browse/fetch_data", methods=["POST"]) def browse_fetch_data(): retdata = { "data": [ {"vendors": x} for x in app.dbh.connection.store_cves.distinct("vendors") if x is not None ] } return retdata def view_cve_id_name(*args, **kwargs): return [ { "text": request.view_args["cve_id"], "url": "{}cve/{}".format( url_for("home.index"), request.view_args["cve_id"] ), } ] @home.route("/cve/<cve_id>") @register_breadcrumb(home, ".cve", "", dynamic_list_constructor=view_cve_id_name) def cve(cve_id): cvesp = CveHandler( rankinglookup=True, namelookup=True, via4lookup=True, capeclookup=True, subscorelookup=True, ) cve = cvesp.getcve(cveid=cve_id.upper()) if cve is None: return ( render_template( "error.html", status={"except": "cve-not-found", "info": {"cve": cve_id}}, ), 404, ) if app.config["WebInterface"]: cve = markCPEs(cve) return render_template("cve.html", cve=cve) else: return render_template("cve.html", cve=cve) def view_cwe_id_name(*args, **kwargs): try: return [ {"text": "CWE-List", "url": "{}cwe".format(url_for("home.index"))}, { "text": "CWE-{}".format(request.view_args["cwe_id"]), "url": "{}cwe/{}".format( url_for("home.index"), request.view_args["cwe_id"] ), }, ] except KeyError: return [{"text": "CWE-List", "url": "{}cwe".format(url_for("home.index"))}] @home.route("/cwe") @home.route("/cwe/<cwe_id>") @register_breadcrumb(home, ".cwe", "", dynamic_list_constructor=view_cwe_id_name) def get_cwe(cwe_id=None): from lib.DatabaseLayer import ( getCWEs, getCAPECFor, ) data = getCWEs() if cwe_id is None: cwes = [x for x in data if x["weaknessabs"].lower() == "class"] return render_template("cwe.html", cwes=cwes, capec=None) else: cwes = {x["id"]: x["name"] for x in data} return render_template( "cwe.html", cwes=cwes, cwe=cwe_id, capec=getCAPECFor(cwe_id), minimal=True ) def view_capec_id_name(*args, **kwargs): return [ { "text": "CAPEC-{}".format(request.view_args["capec_id"]), "url": "{}capec/{}".format( url_for("home.index"), request.view_args["capec_id"] ), } ] @home.route("/capec/<capec_id>") @register_breadcrumb(home, ".capec", "", dynamic_list_constructor=view_capec_id_name) def capec(capec_id): from lib.DatabaseLayer import ( getCWEs, getCAPEC, ) data = getCWEs() cwes = {x["id"]: x["name"] for x in data} req_capec = getCAPEC(capec_id) if req_capec is None: return render_template( "error.html", status={"except": "capec-not-found", "info": {"capec": capec_id}}, ) rel_capecs = defaultdict(dict) if len(req_capec["related_capecs"]) != 0: for each in req_capec["related_capecs"]: rel_capecs[each] = getCAPEC(each)["summary"] return render_template( "capec.html", cwes=cwes, capecs=dict(rel_capecs), capec=req_capec ) def view_product_name(*args, **kwargs): vendor = request.view_args["vendor"] return [ { "text": "{}".format(request.view_args["product"]), "url": "{}search/{}/{}".format( url_for("home.index"), vendor, request.view_args["product"] ), } ] @home.route("/search/<vendor>/<path:product>") @register_breadcrumb( home, ".browse.vendor", "", dynamic_list_constructor=view_product_name ) def search(vendor=None, product=None): return render_template( "search.html", freetextsearch="", vendor=vendor, product=product, **config_args ) def view_freetext_search(*args, **kwargs): try: return [ { "text": "Search: {}".format(request.view_args["freetextsearch"]), "url": "{}search/{}".format( url_for("home.index"), request.view_args["freetextsearch"] ), } ] except KeyError: return [{"text": "Search", "url": ""}] @home.route("/search/<freetextsearch>") @register_breadcrumb(home, ".search", "", dynamic_list_constructor=view_freetext_search) def freetext_search(freetextsearch=None): return render_template( "search.html", freetextsearch=freetextsearch, vendor="", product="", **config_args ) @home.route("/fetch_search_data", methods=["POST"]) def fetch_freetext_search(): from lib.DatabaseLayer import ( cvesForCPE, getSearchResults, ) search = "" if request.values.get("search"): search = request.values.get("search") vendor = "" if request.values.get("vendor"): vendor = request.values.get("vendor") product = "" if request.values.get("product"): product = request.values.get("product") if search != "": result = getSearchResults(search) cve = {"data": result["data"], "total": len(result["data"])} elif vendor != "" and product != "": search = (vendor, product) result = cvesForCPE(search, strict_vendor_product=True) cve = {"data": result["results"], "total": len(result["results"])} else: return make_response(jsonify(False), 400) # errors = result["errors"] if "errors" in result else [] return make_response(jsonify(cve), 200) def view_linked(*args, **kwargs): key = request.view_args["key"] return [ { "text": "{}".format(request.view_args["value"]), "url": "{}link/{}/{}".format( url_for("home.index"), key, request.view_args["value"] ), } ] @home.route("/link/<key>/<value>") @register_breadcrumb(home, ".linked", "", dynamic_list_constructor=view_linked) def link(key=None, value=None): from lib.DatabaseLayer import ( via4Linked, ) regex = re.compile(re.escape(value), re.I) cve = via4Linked(key, regex) cvssList = [float(x["cvss"]) for x in cve["results"] if x.get("cvss")] if cvssList: stats = { "maxCVSS": max(cvssList), "minCVSS": min(cvssList), "count": int(cve["total"]), } else: stats = {"maxCVSS": 0, "minCVSS": 0, "count": int(cve["total"])} return render_template( "linked.html", via4map=key.split(".")[0], field=".".join(key.split(".")[1:]), value=value, cve=cve, stats=stats, ) @home.route("/set_filter", methods=["POST"]) def set_filter(): try: filter_params = dict(request.json) if not current_user.is_authenticated: # Defaults matching the form defaults for an authenticated user. filter_params["blacklistSelect"] = "on" filter_params["whitelistSelect"] = "on" filter_params["unlistedSelect"] = "show" if validateFilter(filter_params): resp = make_response(jsonify(True), 200) resp.set_cookie("cve_filter", json.dumps(filter_params)) else: resp = make_response(jsonify(False), 400) except TypeError: resp = make_response(jsonify(False), 400) return resp @home.route("/reset_filter") def reset_filter(): resp = make_response(jsonify(defaultFilters), 200) resp.set_cookie("cve_filter", "", expires=0) return resp @home.route("/filter_active") def filter_active(): try: filter_params = dict(json.loads(request.cookies.get("cve_filter"))) if not validateFilter(filter_params): filter_params = defaultFilters except TypeError: filter_params = defaultFilters if filter_params == defaultFilters: resp = make_response(jsonify(False), 200) resp.set_cookie("cve_filter", "", expires=0) else: resp = make_response(jsonify(True), 200) return resp @home.route("/get_filter") def get_filter(): try: filter_params = SanitizeUserInput( dict(json.loads(request.cookies.get("cve_filter"))) ) if not validateFilter(filter_params): filter_params = defaultFilters except TypeError: filter_params = defaultFilters return filter_params @home.route("/fetch_cve_data", methods=["POST"]) def fetch_cvedata(): try: filter_params = dict(json.loads(request.cookies.get("cve_filter"))) if not validateFilter(filter_params): filter_params = defaultFilters except TypeError: filter_params = defaultFilters if filter_params == defaultFilters: ssd = ServerSideDataTable(request=request, backend=app.dbh.connection) else: query_filters = generate_full_query(filter_params) if len(query_filters) != 0: ssd = ServerSideDataTable( request=request, backend=app.dbh.connection, additional_filters=query_filters, ) else: ssd = ServerSideDataTable(request=request, backend=app.dbh.connection) return_data = ssd.output_result() return return_data
11,353
Python
.py
329
26.62614
88
0.585341
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,255
__init__.py
cve-search_cve-search/web/auth/__init__.py
from flask import Blueprint auth = Blueprint("auth", __name__) from . import views
85
Python
.py
3
26.666667
34
0.75
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,256
forms.py
cve-search_cve-search/web/auth/forms.py
import re from flask_wtf import FlaskForm from wtforms import StringField, PasswordField, SubmitField from wtforms.validators import InputRequired, Length, ValidationError class LoginForm(FlaskForm): username = StringField( "username", validators=[InputRequired()], render_kw={"placeholder": "username"} ) password = PasswordField( "password", validators=[InputRequired(), Length(min=5, max=24)], render_kw={"placeholder": "password"}, ) submit = SubmitField("Login") def validate_username(form, field): user = users.query.filter_by(name=field.data).first() if user: raise ValidationError({"Username is already in use": []}) def validate_password(form, field): if field.data != form.confirm_password.data: raise ValidationError({"Passwords do not match": []}) def password_check(form, field): """ Verify the strength of 'password' Returns a dict indicating the wrong criteria A password is considered strong if: 8 characters length or more 1 digit or more 1 symbol or more 1 uppercase letter or more 1 lowercase letter or more """ # calculating the length length_error = len(field.data) < 8 # searching for digits digit_error = re.search(r"\d", field.data) is None # searching for uppercase uppercase_error = re.search(r"[A-Z]", field.data) is None # searching for lowercase lowercase_error = re.search(r"[a-z]", field.data) is None # searching for symbols symbol_error = ( re.search(r"[ !#$%&'()*+,-./[\\\]^_`{|}~" + r'"]', field.data) is None ) # overall result password_ok = not ( length_error or digit_error or uppercase_error or lowercase_error or symbol_error ) if password_ok is False: raise ValidationError( { "The provided password does not meet the following criteria:": [ "8 characters length or more", "1 digit or more", "1 symbol or more", "1 uppercase letter or more", "1 lowercase letter or more", ] } ) class RegistrationForm(FlaskForm): """ Form for users to create new account """ username = StringField( "username", validators=[validate_username], render_kw={"placeholder": "username"}, ) password = PasswordField( "password", validators=[validate_password, password_check], render_kw={"placeholder": "password"}, ) confirm_password = PasswordField( "Confirm password", render_kw={"placeholder": "confirm password"} ) submit = SubmitField("Register")
2,805
Python
.py
82
26.682927
87
0.620562
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,257
views.py
cve-search_cve-search/web/auth/views.py
import json import logging import urllib.parse import requests from flask import redirect, request, render_template, url_for from flask_login import logout_user, login_required, login_user, current_user from requests.adapters import HTTPAdapter from urllib3 import Retry from lib.LogHandler import AppLogger from lib.User import User from . import auth from .forms import LoginForm from ..home.utils import defaultFilters from ..run import oidcClient, config, app logging.setLoggerClass(AppLogger) logger = logging.getLogger(__name__) def get_session( retries=3, backoff_factor=0.3, status_forcelist=(429, 500, 502, 503, 504), session=None, ): """ Method for returning a session object """ # disabling annoying messages from urllib3 requests.packages.urllib3.disable_warnings() proxies = {"http": config.getProxy(), "https": config.getProxy()} session = session or requests.Session() retry = Retry( total=retries, read=retries, connect=retries, backoff_factor=backoff_factor, status_forcelist=status_forcelist, ) session.proxies.update(proxies) adapter = HTTPAdapter(max_retries=retry) session.mount("http://", adapter) session.mount("https://", adapter) return session def get_idp_provider_cfg(): with get_session() as session: data = session.get( config.getIDPDiscoveryUrl(), verify=config.useSSLVerify() ).json() return data @auth.route("/oidc-login/callback", methods=["GET"]) def callback(): # Get authorization code IDP sent back form = LoginForm() try: code = request.args.get("code") idp_provider_cfg = get_idp_provider_cfg() token_endpoint = idp_provider_cfg["token_endpoint"] # Request to get tokens from IDP token_url, headers, body = oidcClient.prepare_token_request( token_endpoint, authorization_response=request.url, redirect_url=request.base_url, code=code, ) with get_session() as session: token_response = session.post( token_url, headers=headers, data=body, auth=(config.getClientID(), config.getClientSecret()), verify=config.useSSLVerify(), ) # Parse the tokens! oidcClient.parse_request_body_response(json.dumps(token_response.json())) # find and hit the userinfo endpoint # from IDP that gives user's profile information, # including their preferred username - userinfo_endpoint = idp_provider_cfg["userinfo_endpoint"] uri, headers, body = oidcClient.add_token(userinfo_endpoint) with get_session() as session: userinfo_response = session.get( uri, headers=headers, data=body, verify=config.useSSLVerify() ) # Login the user preferred_username = userinfo_response.json()["preferred_username"] if preferred_username: person = User.get(preferred_username, app.auth_handler) defaultFilters.update( { "blacklistSelect": "on", "whitelistSelect": "on", "unlistedSelect": "show", } ) login_user(person) return redirect(url_for("admin.admin_home")) else: return render_template( "login.html", form=form, status="auth_again", show_oidc=config.useOIDC() ) except Exception as err: logger.error(f"****OIDC callback exception***** --> {err}") return render_template( "login.html", form=form, status="auth_again", show_oidc=config.useOIDC() ) @auth.route("/oidc-login", methods=["GET"]) def oidcLogin(): # display OIDC only when in conf if config.useOIDC(): # Find out what URL to hit for IDP login idp_provider_cfg = get_idp_provider_cfg() authorization_endpoint = idp_provider_cfg["authorization_endpoint"] # construct the request for IDP login and provide # scopes to retrieve user's profile from IDP request_uri = oidcClient.prepare_request_uri( authorization_endpoint, redirect_uri=request.base_url + "/callback", scope=["openid", "email", "profile"], ) return request_uri @auth.route("/login", methods=["GET", "POST"]) def login(): form = LoginForm() if current_user.is_authenticated: return redirect(url_for("home.index")) if not config.loginRequired(): person = User.get("_dummy_", app.auth_handler) defaultFilters.update( {"blacklistSelect": "on", "whitelistSelect": "on", "unlistedSelect": "show"} ) login_user(person) return redirect(url_for("admin.admin_home")) if form.validate_on_submit(): # validate username and password username = request.form.get("username") password = request.form.get("password") person = User.get(username, app.auth_handler) if person and person.authenticate(password): defaultFilters.update( { "blacklistSelect": "on", "whitelistSelect": "on", "unlistedSelect": "show", } ) login_user(person) return redirect(url_for("admin.admin_home")) else: return render_template( "login.html", form=form, status="wrong_user_pass", show_oidc=config.useOIDC(), ) else: return render_template("login.html", form=form, show_oidc=config.useOIDC()) # @auth.route("/register", methods=["GET", "POST"]) # def register(): # # form = RegistrationForm() # if form.validate_on_submit(): # # pass # # else: # return render_template("register.html", form=form) @auth.route("/logout") @login_required def logout(): redirect_url = "/" logout_user() if config.useOIDC(): idp_provider_cfg = get_idp_provider_cfg() end_session_endpoint = idp_provider_cfg["end_session_endpoint"] redirect_url = "{end_session_endpoint}?redirect_uri={redirect_uri}".format( end_session_endpoint=end_session_endpoint, redirect_uri=urllib.parse.quote(request.base_url, safe="/:?&="), ) return redirect(urllib.parse.quote(redirect_url, safe="/:?&="))
6,587
Python
.py
177
28.80226
88
0.617435
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,258
__init__.py
cve-search_cve-search/web/admin/__init__.py
from flask import Blueprint admin = Blueprint("admin", __name__) from . import views
87
Python
.py
3
27.333333
36
0.756098
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,259
views.py
cve-search_cve-search/web/admin/views.py
import os import re import subprocess import sys import urllib from io import BytesIO from flask import render_template, request, jsonify, send_file, url_for from flask_breadcrumbs import default_breadcrumb_root, register_breadcrumb from flask_login import current_user, login_required from flask_plugins import ( get_plugin, get_plugin_from_all, get_all_plugins, get_enabled_plugins, ) from redis import exceptions as redisExceptions from lib.Config import Configuration from lib.Query import getVersionsOfProduct from sbin.db_blacklist import ( countBlacklist, dropBlacklist, importBlacklist, exportBlacklist, removeBlacklist, updateBlacklist, ) from sbin.db_whitelist import ( countWhitelist, dropWhitelist, importWhitelist, exportWhitelist, removeWhitelist, updateWhitelist, ) from web.home.utils import adminInfo, addCPEToList from . import admin from ..run import app, plugins config = Configuration() default_breadcrumb_root(admin, ".Admin") @admin.route("/") @register_breadcrumb(admin, ".", "Admin") @login_required def admin_home(): enabled_plugins = [x.identifier for x in list(get_enabled_plugins())] return render_template( "admin.html", status="default", **adminInfo(), plugins=get_all_plugins(), enabled_plugins=enabled_plugins, disable_pwd_section=config.useOIDC() ) @admin.route("/change_pass", methods=["GET", "POST"]) @login_required def change_pass(): post_data = dict(request.json) current_pass = post_data["current_pass"] new_pass = post_data["new_pass"] if current_user.authenticate(current_pass): if new_pass: app.dbh.connection.changePassword(current_user.id, new_pass) return jsonify({"status": "password_changed"}) return jsonify({"status": "no_password"}) else: return jsonify({"status": "wrong_user_pass"}) @admin.route("/updatedb") @login_required def updatedb(): subprocess.Popen( [ sys.executable, os.path.join(app.config["run_path"], "../sbin/db_updater.py"), "-civ", ], stdout=subprocess.PIPE, stderr=subprocess.PIPE, ) return jsonify({"status": "db_updated"}) def view_WorB(*args, **kwargs): worb = request.url_rule.rule.split("/")[-1] return [ {"text": worb.title(), "url": "{}{}".format(url_for("admin.admin_home"), worb)} ] @admin.route("/whitelist") @admin.route("/blacklist") @register_breadcrumb(admin, ".W-B_list", "", dynamic_list_constructor=view_WorB) @login_required def listView(): from lib.DatabaseLayer import getWhitelist, getBlacklist if request.url_rule.rule.split("/")[-1].lower() == "whitelist": return render_template("list.html", rules=getWhitelist(), listType="Whitelist") else: return render_template("list.html", rules=getBlacklist(), listType="Blacklist") @admin.route("/whitelist/import", methods=["GET", "POST"]) @admin.route("/blacklist/import", methods=["GET", "POST"]) @login_required def listImport(): _list = request.url_rule.rule.split("/")[2] file = request.files["file"] force = request.form.get("force") count = countWhitelist() if _list.lower() == "whitelist" else countBlacklist() if (count == 0) | (not count) | (force == "f"): if _list.lower() == "whitelist": dropWhitelist() importWhitelist(file.stream) else: dropBlacklist() importBlacklist(file.stream) status = _list[0] + "l_imported" else: status = _list[0] + "l_already_filled" return render_template("admin.html", status=status, **adminInfo()) @admin.route("/whitelist/export") @admin.route("/blacklist/export") @login_required def listExport(): _list = request.url_rule.rule.split("/")[2] if _list.lower() == "whitelist": data = exportWhitelist() else: data = exportBlacklist() bytIO = BytesIO() bytIO.write(bytes(data, "utf-8")) bytIO.seek(0) return send_file(bytIO, as_attachment=True, attachment_filename=_list + ".txt") @admin.route("/whitelist/drop") @admin.route("/blacklist/drop") @login_required def listDrop(): _list = request.url_rule.rule.split("/")[2].lower() if _list == "whitelist": dropWhitelist() else: dropBlacklist() return jsonify({"status": _list[0] + "l_dropped"}) @admin.route("/addToList") @login_required def listAdd(): from lib.DatabaseLayer import getWhitelist, getBlacklist cpe = request.args.get("cpe") cpeType = request.args.get("type") lst = request.args.get("list") if cpe and cpeType and lst: status = ( "added_to_list" if addCPEToList(cpe, lst, cpeType) else "already_exists_in_list" ) returnList = getWhitelist() if lst.lower() == "whitelist" else getBlacklist() return jsonify({"status": status, "rules": returnList, "listType": lst.title()}) else: return jsonify({"status": "could_not_add_to_list"}) @admin.route("/removeFromList") @login_required def listRemove(): from lib.DatabaseLayer import getWhitelist, getBlacklist cpe = request.args.get("cpe", type=str) cpe = urllib.parse.quote_plus(cpe).lower() cpe = cpe.replace("%3a", ":") cpe = cpe.replace("%2f", "/") cpe = cpe.replace("%2a", "*") lst = request.args.get("list", type=str) if cpe and lst: result = ( removeWhitelist(cpe) if lst.lower() == "whitelist" else removeBlacklist(cpe) ) status = "removed_from_list" if (result > 0) else "already_removed_from_list" else: status = "invalid_cpe" returnList = getWhitelist() if lst.lower() == "whitelist" else getBlacklist() return jsonify({"status": status, "rules": returnList, "listType": lst.title()}) @admin.route("/editInList") @login_required def listEdit(): from lib.DatabaseLayer import getWhitelist, getBlacklist old = request.args.get("oldCPE") new = request.args.get("cpe") lst = request.args.get("list") CPEType = request.args.get("type") if old and new: result = ( updateWhitelist(old, new, CPEType) if lst == "whitelist" else updateBlacklist(old, new, CPEType) ) status = "cpelist_updated" if (result) else "cpelist_update_failed" else: status = "invalid_cpe" returnList = ( list(getWhitelist()) if lst.lower() == "whitelist" else list(getBlacklist()) ) return jsonify({"rules": returnList, "status": status, "listType": lst}) def view_listmanagement(*args, **kwargs): try: product = request.view_args["product"] except KeyError: product = None try: if product is None: return [ { "text": "List-Management", "url": "{}listmanagement".format(url_for("admin.admin_home")), }, { "text": "{}".format(request.view_args["vendor"]), "url": "{}listmanagement/{}".format( url_for("admin.admin_home"), request.view_args["vendor"] ), }, ] else: return [ { "text": "List-Management", "url": "{}listmanagement".format(url_for("admin.admin_home")), }, { "text": "{}".format(request.view_args["vendor"]), "url": "{}listmanagement/{}".format( url_for("admin.admin_home"), request.view_args["vendor"] ), }, { "text": "{}".format(request.view_args["product"]), "url": "{}listmanagement/{}/{}".format( url_for("admin.admin_home"), request.view_args["vendor"], request.view_args["product"], ), }, ] except KeyError: return [{"text": "List-Management", "url": "/admin/listmanagement"}] @admin.route("/listmanagement") @admin.route("/listmanagement/<vendor>") @admin.route("/listmanagement/<vendor>/<product>") @register_breadcrumb( admin, ".listmanagement_spec", "", dynamic_list_constructor=view_listmanagement ) @login_required def listManagement(vendor=None, product=None): try: if product is None and vendor is None: # no product selected yet, so same function as /browse can be used vendor = [ x for x in app.dbh.connection.store_cves.distinct("vendors") if x is not None ] product = None version = None elif product is None: vendor = vendor product = [ x for x in app.dbh.connection.store_cves.distinct( "products", {"vendors": vendor} ) if x is not None ] version = None else: # product selected, product versions required version = getVersionsOfProduct(urllib.parse.quote_plus(product).lower()) return render_template( "listmanagement.html", vendor=vendor, product=product, version=version ) except redisExceptions.ConnectionError: return render_template( "error.html", status={ "except": "redis-connection", "info": {"host": config.getRedisHost(), "port": config.getRedisPort()}, }, ) @admin.route("/listmanagement/add", methods=["GET", "POST"]) @login_required def listManagementAdd(): from lib.DatabaseLayer import getCVEs # this functionality is broken; needs further investigation.... post_data = dict(request.json) redisdb = config.getRedisVendorConnection() # retrieve the separate item parts item = post_data["item"] listType = post_data["list"] pattern = re.compile("^[a-z:/0-9.~_%-]+$") if pattern.match(item): item = item.split(":") added = False if len(item) == 1: # only vendor, so a check on cpe type is needed if redisdb.sismember("t:/o", item[0]): if addCPEToList("cpe:/o:" + item[0], listType): added = True if redisdb.sismember("t:/a", item[0]): if addCPEToList("cpe:/a:" + item[0], listType): added = True if redisdb.sismember("t:/h", item[0]): if addCPEToList("cpe:/h:" + item[0], listType): added = True elif 4 > len(item) > 1: # cpe type can be found with a mongo regex query result = getCVEs(query={"cpeName": {"$regex": item[1]}})["results"] if len(result) != 0: prefix = ((result[0])["cpeName"])[:7] if len(item) == 2: if addCPEToList(prefix + item[0] + ":" + item[1], listType): added = True if len(item) == 3: if addCPEToList( prefix + item[0] + ":" + item[1] + ":" + item[2], listType ): added = True status = "added_to_list" if added else "could_not_add_to_list" else: status = "invalid_cpe" j = {"status": status, "listType": listType} return jsonify(j) @admin.route("/disable/<plugin>") @login_required def disable(plugin): plugin = get_plugin(plugin) plugins.disable_plugins([plugin]) j = {"status": "plugin_action_disabled"} return jsonify(j) @admin.route("/enable/<plugin>") @login_required def enable(plugin): plugin = get_plugin_from_all(plugin) plugins.enable_plugins([plugin]) j = {"status": "plugin_action_enabled"} return jsonify(j)
12,060
Python
.py
333
27.96997
88
0.591026
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,260
__init__.py
cve-search_cve-search/web/plugins/hello_world/__init__.py
from flask import Blueprint, render_template, render_template_string from flask_plugins import connect_event from web.helpers.app_plugin import AppPlugin __plugin__ = "HelloWorld" __version__ = "1.0.0" def inject_navigation_link(): return render_template_string( """ <a class="nav-item nav-link" href="{{ url_for('hello.index') }}">Hello World</a> """ ) def inject_dropdown_navigation_link(): return render_template_string( """ <a class="dropdown-item" href="{{ url_for('hello.index') }}">Hello World</a> """ ) def inject_tab_header(): return render_template_string( """ <ul class="nav nav-pills"> <li class="nav-item"><a class="nav-link active" href="#hello" data-toggle="tab">Hello World</a></li> </ul> """ ) def inject_tab_content(): return render_template_string( """ <div class="tab-content"> <div class="active tab-pane" id="hello"> <div class="card"> <div class="card-body"> Hello world in tab </div> </div> </div> </div> """ ) hello = Blueprint("hello", __name__, template_folder="templates") @hello.route("/") def index(): return render_template("hello.html") class HelloWorld(AppPlugin): def setup(self): self.register_blueprint(hello, url_prefix="/hello") connect_event("footer_tab_header", inject_tab_header) connect_event("footer_tab_content", inject_tab_content) connect_event("tmpl_navigation_last", inject_navigation_link) connect_event("tmpl_navigation_dropdown", inject_dropdown_navigation_link)
1,736
Python
.py
50
27.28
110
0.603717
cve-search/cve-search
2,271
587
2
AGPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,261
__version__.py
huhamhire_huhamhire-hosts/__version__.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # __version__.py : Version info for Hosts Setup Tool. # # Copyleft (C) 2014 - huhamhire hosts team <hosts@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # # This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE. # ===================================================================== __version__ = "1.9.8-SE" __release__ = "beta" __revision__ = "$Id$"
735
Python
.py
18
39.833333
71
0.574616
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,262
hoststool.py
huhamhire_huhamhire-hosts/hoststool.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # hoststool.py : Launch the utility. # # Copyleft (C) 2014 - huhamhire hosts team <hosts@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # # This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import os from optparse import OptionParser import gui import tui from __version__ import __version__ import sys sys.path.append("..") from util import CommonUtil class UtilLauncher(object): """ HostsUtil class is the entrance to launch `Hosts Setup Utility`. This class contains methods for user to decide whether to start a session in Graphical User Interface (GUI) mode or in Text-based User Interface (TUI) mode. Usage can be printed to screen via terminal by using ``-h`` or ``--help`` argument. The help message would be like this:: Usage: hoststool.py [-g] [-t] [-h] [--version] Options: --version show program's version number and exit -h, --help show this help message and exit -g, --graphicui launch in GUI(QT) mode -t, --textui launch in TUI(Curses) mode .. seealso:: :ref:`Get Started <intro-get-started>`. .. note:: All methods from this class are declared as `classmethod`. """ @classmethod def launch(cls): """ Launch `Hosts Setup Utility`. .. note:: This is a `classmethod`. """ options, args = cls.set_commands() if options.tui: cls.launch_tui() elif options.gui: cls.launch_gui() @classmethod def set_commands(cls): """ Set the command options and arguments to launch `Hosts Setup Utility`. .. note:: This is a `classmethod`. :return: :meth:`hoststool.UtilLauncher.set_commands` returns two values: (:attr:`options`, :attr:`args`) * options(`optparse.Values`): An instance of :class:`optparse.Values` containing values for all of your options—e.g. if --file takes a single string argument, then options.file will be the filename supplied by the user, or None if the user did not supply that option args, the list of positional arguments leftover after parsing options. * args(`list`): Positional arguments leftover after parsing options. .. seealso:: `OptionParser <http://docs.python.org/2/library/optparse.html>`_. :rtype: :class:`optparse.Values`, list """ usage = "usage: %prog [-g] [-t] [-h] [--version]" version = "Hosts Setup Utility v" + __version__ parser = OptionParser(usage=usage, version=version) parser.add_option("-g", "--graphicui", dest="gui", default=True, action="store_true", help="launch in GUI(QT) mode") parser.add_option("-t", "--textui", dest="tui", default=False, action="store_true", help="launch in TUI(Curses) mode ") return parser.parse_args() @classmethod def get_custom_conf_path(cls): if not CommonUtil.check_platform()[0] == "Windows": path = os.path.expanduser('~/.custom.hosts') if not os.path.isfile(path): path = os.path.expanduser('~/custom.hosts') if os.path.isfile(path): return path return None @classmethod def launch_gui(cls): """ Start a Graphical User Interface (GUI) session of `Hosts Setup Utility`. .. note:: This is a `classmethod`. """ main = gui.HostsUtil() path = UtilLauncher.get_custom_conf_path() if path is not None: main.custom = path main.start() @classmethod def launch_tui(cls): """ Start a Text-based User Interface (TUI) session of `Hosts Setup Utility`. .. note:: This is a `classmethod`. """ # Set code page for Windows system = CommonUtil.check_platform()[0] cp = "437" if system == "Windows": chcp = os.popen("chcp") cp = chcp.read().split()[-1] chcp.close() os.popen("chcp 437") main = tui.HostsUtil() main.custom = UtilLauncher.get_custom_conf_path() main.start() # Restore the default code page for Windows if system == "Windows": os.popen("chcp " + cp) if __name__ == "__main__": UtilLauncher.launch()
5,056
Python
.py
126
31.579365
78
0.578485
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,263
_build.py
huhamhire_huhamhire-hosts/_build.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # _build.py : Tools to make packages for different platforms # # Copyleft (C) 2014 - huhamhire hosts team <hosts@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # # This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import os import sys import shutil from __version__ import __version__ SCRIPT = "hoststool.py" SCRIPT_DIR = os.getcwd() + '/' RELEASE_DIR = "../release/" # Shared package settings and metadata NAME = "HostsUtl" VERSION = __version__ DESCRIPTION = "HostsUtl - Hosts Setup Utility" AUTHOR = "Hamhire Hu" AUTHOR_EMAIL = "hosts@huhamhire.com", LICENSE = "Public Domain, Python, BSD, GPLv3 (see LICENSE)", URL = "https://hosts.huhamhire.com", CLASSIFIERS = [ "Development Status :: 4 - Beta", "Environment :: MacOS X", "Environment :: Win32 (MS Windows)", "Environment :: X11 Applications :: Qt", "Intended Audience :: Developers", "Intended Audience :: End Users/Desktop", "Intended Audience :: Other Audience", "Intended Audience :: System Administrators", "License :: OSI Approved :: Python Software Foundation License", "License :: OSI Approved :: BSD License", "License :: OSI Approved :: GNU General Public License v3", "License :: Public Domain", "Natural Language :: English", "Natural Language :: Chinese (Simplified)", "Operating System :: OS Independent", "Programming Language :: Python :: 2.7", "Topic :: Communications", "Topic :: Database", "Topic :: Desktop Environment", "Topic :: Documentation", "Topic :: Internet :: Name Service (DNS)", "Topic :: System :: Networking", "Topic :: Software Development :: Documentation", "Topic :: Text Processing", "Topic :: CommonUtil", ] DATA_FILES = [ ("gui/lang", [ "gui/lang/en_US.qm", "gui/lang/zh_CN.qm", "gui/lang/zh_TW.qm", ]), ("gui/theme", [ "gui/theme/default.qss", ]), (".", [ "LICENSE", "README.rst", "network.conf", ]), ] if sys.argv > 1: tar_flag = 0 includes = [] excludes = [] file_path = lambda rel_path: SCRIPT_DIR + rel_path if sys.argv[1] == "py2tar": # Pack up script package for Linux users includes = [ "*.py", "gui/lang/*.qm", "gui/theme/*.qss", "*/*.py", "LICENSE", "README.rst", "network.conf", ] excludes = [ "_build.py", "_pylupdate4.py", "_pyuic4.py", ".gitattributes", ".gitignore", ] ex_files = [] prefix = "HostsTool-x11-gpl-" tar_flag = 1 elif sys.argv[1] == "py2source": # Pack up source package for Linux users includes = ["*"] excludes = [ ".gitattributes", ".gitignore", "hostslist.data", ] ex_files = [] prefix = "HostsTool-source-gpl-" tar_flag = 1 else: prefix = "Error" ex_files = [] if tar_flag: import glob import tarfile TAR_NAME = prefix + VERSION + ".tar.gz" RELEASE_PATH = RELEASE_DIR + TAR_NAME if not os.path.exists(RELEASE_DIR): os.mkdir(RELEASE_DIR) if os.path.isfile(RELEASE_PATH): os.remove(RELEASE_PATH) rel_len = len(SCRIPT_DIR) tar = tarfile.open(RELEASE_PATH, "w|gz") for name_format in excludes: ex_files.extend(glob.glob(file_path(name_format))) for name_format in includes: files = glob.glob(file_path(name_format)) for src_file in files: if src_file not in ex_files: tar_path = os.path.join(prefix + VERSION, src_file[rel_len:]) tar.add(src_file, tar_path) print "compressing: %s" % src_file tar.close() exit(1) from util import CommonUtil system = CommonUtil.check_platform()[0] if system == "Windows": # Build binary executables for Windows import struct import zipfile from distutils.core import setup import py2exe # Set working directories WORK_DIR = SCRIPT_DIR + "work/" DIR_NAME = "HostsTool" DIST_DIR = WORK_DIR + DIR_NAME + '/' WIN_OPTIONS = { "includes": ["sip"], "excludes": ["_scproxy", "_sysconfigdata"], "dll_excludes": ["MSVCP90.dll"], "dist_dir": DIST_DIR, "compressed": 1, "optimize": 2, } # Clean work space before build if os.path.exists(DIST_DIR): shutil.rmtree(DIST_DIR) # Build Executable print " Building Executable ".center(78, '=') EXE_NAME = SCRIPT.split(".")[0] setup( name=NAME, version=VERSION, options={"py2exe": WIN_OPTIONS}, console=[ {"script": SCRIPT, "dest_base": "hoststool_tui", "uac_info": "highestAvailable", }, ], windows=[ {"script": SCRIPT, "icon_resources": [(1, "res/img/icons/hosts_utl.ico")], "dest_base": EXE_NAME, "uac_info": "highestAvailable", }, ], description=DESCRIPTION, author=AUTHOR, author_email=AUTHOR_EMAIL, license=LICENSE, url=URL, zipfile="lib/shared.lib", data_files=DATA_FILES, classifiers=CLASSIFIERS, ) # Clean work directory after build shutil.rmtree(SCRIPT_DIR + "build/") # Pack up executable to ZIP file print " Compressing to ZIP ".center(78, '=') if struct.calcsize("P") * 8 == 64: PLAT = "x64" elif struct.calcsize("P") * 8 == 32: PLAT = "x86" else: PLAT = "unknown" DIR_NAME = DIR_NAME + '-win-gpl-' + VERSION + '-' + PLAT ZIP_NAME = DIR_NAME + ".zip" ZIP_FILE = WORK_DIR + ZIP_NAME compressed = zipfile.ZipFile(ZIP_FILE, 'w', zipfile.ZIP_DEFLATED) for root, dirs, files in os.walk(DIST_DIR): rel_path = os.path.relpath(root, os.path.dirname(DIST_DIR)) for name in files: print "compressing: %s" % os.path.join(root, name) compressed.write( os.path.join(root, name), os.path.join(DIR_NAME, rel_path, name)) compressed.close() # Move ZIP file to release directory RELEASE_PATH = RELEASE_DIR + ZIP_NAME if not os.path.exists(RELEASE_DIR): os.mkdir(RELEASE_DIR) if os.path.isfile(RELEASE_PATH): os.remove(RELEASE_PATH) shutil.move(ZIP_FILE, RELEASE_PATH) shutil.rmtree(WORK_DIR) print "Done!" elif system == "OS X": # Build binary executables for Mac OS X from setuptools import setup # Set working directories WORK_DIR = SCRIPT_DIR + "work/" RES_DIR = SCRIPT_DIR + "res/mac/" APP_NAME = "HostsTool.app" APP_PATH = WORK_DIR + APP_NAME DIST_DIR = APP_PATH + "/Contents/" # Set build configuration MAC_OPTIONS = { "iconfile": "res/img/icons/hosts_utl.icns", "includes": ["sip", "PyQt4.QtCore", "PyQt4.QtGui"], "excludes": [ "PyQt4.QtDBus", "PyQt4.QtDeclarative", "PyQt4.QtDesigner", "PyQt4.QtHelp", "PyQt4.QtMultimedia", "PyQt4.QtNetwork", "PyQt4.QtOpenGL", "PyQt4.QtScript", "PyQt4.QtScriptTools", "PyQt4.QtSql", "PyQt4.QtSvg", "PyQt4.QtTest", "PyQt4.QtWebKit", "PyQt4.QtXml", "PyQt4.QtXmlPatterns", "PyQt4.phonon"], "compressed": 1, "dist_dir": DIST_DIR, "optimize": 2, "plist": { "CFBundleAllowMixedLocalizations": True, "CFBundleSignature": "hamh", "CFBundleIdentifier": "org.pythonmac.huhamhire.HostsTool", "NSHumanReadableCopyright": "(C) 2014, huhamhire hosts Team"} } # Clean work space before build if os.path.exists(APP_PATH): shutil.rmtree(APP_PATH) if not os.path.exists(WORK_DIR): os.mkdir(WORK_DIR) # Make daemon APP OSAC_CMD = "osacompile -o %s %sHostsUtl.scpt" % (APP_PATH, RES_DIR) os.system(OSAC_CMD) # Build APP print " Building Application ".center(78, '=') setup( app=[SCRIPT], name=NAME, version=VERSION, options={"py2app": MAC_OPTIONS}, setup_requires=["py2app"], description=DESCRIPTION, author=AUTHOR, author_email=AUTHOR_EMAIL, license=LICENSE, url=URL, data_files=DATA_FILES, classifiers=CLASSIFIERS, ) # Clean work directory after build os.remove(DIST_DIR + "Resources/applet.icns") shutil.copy2( SCRIPT_DIR + "res/img/icons/hosts_utl.icns", DIST_DIR + "Resources/applet.icns") shutil.copy2(RES_DIR + "Info.plist", DIST_DIR + "Info.plist") shutil.rmtree(SCRIPT_DIR + "build/") # Pack APP to DMG file VDMG_DIR = WORK_DIR + "package_vdmg/" DMG_TMP = WORK_DIR + "pack_tmp.dmg" DMG_RES_DIR = RES_DIR + "dmg/" VOL_NAME = "HostsTool" DMG_NAME = VOL_NAME + "-mac-gpl-" + VERSION + ".dmg" DMG_PATH = WORK_DIR + DMG_NAME # Clean work space before pack up if os.path.exists(VDMG_DIR): shutil.rmtree(VDMG_DIR) if os.path.isfile(DMG_TMP): os.remove(DMG_TMP) if os.path.isfile(DMG_PATH): os.remove(DMG_PATH) # Prepare files in DMG package os.mkdir(VDMG_DIR) shutil.move(APP_PATH, VDMG_DIR) os.symlink("/Applications", VDMG_DIR + " ") shutil.copy2(DMG_RES_DIR + "background.png", VDMG_DIR + ".background.png") shutil.copy2(DMG_RES_DIR + "DS_Store_dmg", VDMG_DIR + ".DS_Store") # Make DMG file print " Making DMG Package ".center(78, '=') MK_CMD = ( "hdiutil makehybrid -hfs -hfs-volume-name %s " "-hfs-openfolder %s %s -o %s" % ( VOL_NAME, VDMG_DIR, VDMG_DIR, DMG_TMP)) PACK_CMD = "hdiutil convert -format UDZO %s -o %s" % (DMG_TMP, DMG_PATH) os.system(MK_CMD) os.system(PACK_CMD) # Clean work directory after make DMG package shutil.rmtree(VDMG_DIR) os.remove(DMG_TMP) # Move DMG file to release directory RELEASE_PATH = RELEASE_DIR + DMG_NAME if not os.path.exists(RELEASE_DIR): os.mkdir(RELEASE_DIR) if os.path.isfile(RELEASE_PATH): os.remove(RELEASE_PATH) print "moving DMG file to: %s" % RELEASE_PATH shutil.move(DMG_PATH, RELEASE_PATH) shutil.rmtree(WORK_DIR) print "Done!"
11,102
Python
.py
331
26.166163
78
0.576873
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,264
_update.py
huhamhire_huhamhire-hosts/gui/_update.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # _update.py: Fetch the latest data file. # # Copyleft (C) 2014 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import os import socket import urllib from PyQt4 import QtCore from util_ui import _translate import sys sys.path.append("..") from util import CommonUtil class QSubFetchUpdate(QtCore.QThread): """ QSubFetchUpdate is a subclass of :class:`PyQt4.QtCore.QThread`. This class contains methods to retrieve the latest hosts data file from a server. .. inheritance-diagram:: gui._update.QSubFetchUpdate :parts: 1 .. note:: The instance of this class should be created in an individual thread. And an instance of class should be set as :attr:`parent` here. :ivar PyQt4.QtCore.pyqtSignal prog_trigger: An instance of :class:`PyQt4.QtCore.pyqtSignal` to emit signal to the main dialog which indicates current downloading progress. .. note:: The signal :attr:`prog_trigger` should be a tuple of (`progress`, message`): * progress(`int`): An number between `0` and `100` which indicates current download progress. * message(`str`): Message to be displayed to users on the progress bar. :ivar PyQt4.QtCore.pyqtSignal finish_trigger: An instance of :class:`PyQt4.QtCore.pyqtSignal` to emit signal to the main dialog which notifies if current operation is finished. .. note:: The signal :attr:`finish_trigger` should be a tuple of (`refresh_flag`, error_flag`): * refresh_flag(`int`): An flag indicating whether to refresh function list in the main dialog or not. ============ ============== refresh_flag Operation ============ ============== 1 Refresh 0 Do not refresh ============ ============== * error_flag(`int`): An flag indicating whether the downloading progress is successfully finished or not. ========== ======= error_flag Status ========== ======= 1 Error 0 Success ========== ======= .. seealso:: Method :meth:`~gui.qdialog_d.QDialogDaemon.finish_fetch` in :class:`~gui.qdialog_d.QDialogDaemon` class. """ prog_trigger = QtCore.pyqtSignal(int, str) finish_trigger = QtCore.pyqtSignal(int, int) def __init__(self, parent): """ Initialize a new instance of this class. Fetch download settings from the main dialog to retrieve new hosts data file. :param parent: An instance of :class:`~gui.qdialog_d.QDialogDaemon` class to fetch settings from. :type parent: :class:`~gui.qdialog_d.QDialogDaemon` .. warning:: :attr:`parent` MUST NOT be set as `None`. """ super(QSubFetchUpdate, self).__init__(parent) self.url = parent.mirrors[parent.mirror_id]["update"] + \ parent.filename self.path = "./" + parent.filename self.tmp_path = self.path + ".download" self.filesize = parent._update["size"] def run(self): """ Start operations to retrieve the new hosts data file. """ self.prog_trigger.emit(0, unicode(_translate( "Util", "Connecting...", None))) self.fetch_file() def fetch_file(self): """ Retrieve the latest data file to a specified local path with a url. """ socket.setdefaulttimeout(10) try: urllib.urlretrieve(self.url, self.tmp_path, self.set_progress) self.replace_old() self.finish_trigger.emit(1, 0) except: self.finish_trigger.emit(1, 1) def set_progress(self, done, block, total): """ Send message to the main dialog to set the progress bar. :param done: Block count of packaged retrieved. :type done: int :param block: Block size of the data pack retrieved. :type block: int :param total: Total size of the hosts data file. :type total: int """ done = done * block if total <= 0: total = self.filesize prog = 100 * done / total done = CommonUtil.convert_size(done) total = CommonUtil.convert_size(total) text = unicode(_translate( "Util", "Downloading: %s / %s", None)) % (done, total) self.prog_trigger.emit(prog, text) def replace_old(self): """ Replace the old hosts data file with the new one. """ if os.path.isfile(self.path): os.remove(self.path) os.rename(self.tmp_path, self.path)
5,255
Python
.py
124
33.532258
78
0.573051
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,265
util_ui.py
huhamhire_huhamhire-hosts/gui/util_ui.py
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file '../pyqt\util_ui.ui' # # Created: Wed Jan 22 13:03:09 2014 # by: PyQt4 UI code generator 4.10.3 # # WARNING! All changes made in this file will be lost! from PyQt4 import QtCore, QtGui try: _fromUtf8 = QtCore.QString.fromUtf8 except AttributeError: def _fromUtf8(s): return s try: _encoding = QtGui.QApplication.UnicodeUTF8 def _translate(context, text, disambig): return QtGui.QApplication.translate(context, text, disambig, _encoding) except AttributeError: def _translate(context, text, disambig): return QtGui.QApplication.translate(context, text, disambig) class Ui_Util(object): def setupUi(self, Util): Util.setObjectName(_fromUtf8("Util")) Util.setEnabled(True) Util.resize(640, 420) sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Fixed, QtGui.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth(Util.sizePolicy().hasHeightForWidth()) Util.setSizePolicy(sizePolicy) Util.setMinimumSize(QtCore.QSize(640, 420)) Util.setMaximumSize(QtCore.QSize(640, 420)) Util.setContextMenuPolicy(QtCore.Qt.DefaultContextMenu) icon = QtGui.QIcon() icon.addPixmap(QtGui.QPixmap(_fromUtf8(":/icon/res/img/icons/utl_icon@256x256.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off) Util.setWindowIcon(icon) Util.setLocale(QtCore.QLocale(QtCore.QLocale.English, QtCore.QLocale.UnitedStates)) Util.setSizeGripEnabled(False) Util.setModal(False) self.mainFrame = QtGui.QFrame(Util) self.mainFrame.setGeometry(QtCore.QRect(0, 40, 640, 351)) self.mainFrame.setFrameShape(QtGui.QFrame.StyledPanel) self.mainFrame.setFrameShadow(QtGui.QFrame.Raised) self.mainFrame.setObjectName(_fromUtf8("mainFrame")) self.ConfigBox = QtGui.QGroupBox(self.mainFrame) self.ConfigBox.setGeometry(QtCore.QRect(10, 20, 240, 90)) sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Fixed, QtGui.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth(self.ConfigBox.sizePolicy().hasHeightForWidth()) self.ConfigBox.setSizePolicy(sizePolicy) self.ConfigBox.setObjectName(_fromUtf8("ConfigBox")) self.layoutWidget = QtGui.QWidget(self.ConfigBox) self.layoutWidget.setGeometry(QtCore.QRect(10, 25, 221, 50)) self.layoutWidget.setObjectName(_fromUtf8("layoutWidget")) self.configLayout = QtGui.QGridLayout(self.layoutWidget) self.configLayout.setMargin(0) self.configLayout.setObjectName(_fromUtf8("configLayout")) self.labelIP = QtGui.QLabel(self.layoutWidget) self.labelIP.setObjectName(_fromUtf8("labelIP")) self.configLayout.addWidget(self.labelIP, 0, 0, 1, 1) self.SelectMirror = QtGui.QComboBox(self.layoutWidget) self.SelectMirror.setObjectName(_fromUtf8("SelectMirror")) self.configLayout.addWidget(self.SelectMirror, 0, 1, 1, 1) self.labelMirror = QtGui.QLabel(self.layoutWidget) self.labelMirror.setObjectName(_fromUtf8("labelMirror")) self.configLayout.addWidget(self.labelMirror, 1, 0, 1, 1) self.SelectIP = QtGui.QComboBox(self.layoutWidget) self.SelectIP.setObjectName(_fromUtf8("SelectIP")) self.SelectIP.addItem(_fromUtf8("")) self.SelectIP.setItemText(0, _fromUtf8("IPv4")) self.SelectIP.addItem(_fromUtf8("")) self.SelectIP.setItemText(1, _fromUtf8("IPv6")) self.configLayout.addWidget(self.SelectIP, 1, 1, 1, 1) self.StatusBox = QtGui.QGroupBox(self.mainFrame) self.StatusBox.setGeometry(QtCore.QRect(10, 120, 240, 90)) sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Fixed, QtGui.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth(self.StatusBox.sizePolicy().hasHeightForWidth()) self.StatusBox.setSizePolicy(sizePolicy) self.StatusBox.setObjectName(_fromUtf8("StatusBox")) self.layoutWidget1 = QtGui.QWidget(self.StatusBox) self.layoutWidget1.setGeometry(QtCore.QRect(10, 30, 221, 40)) self.layoutWidget1.setObjectName(_fromUtf8("layoutWidget1")) self.StatusLayout = QtGui.QGridLayout(self.layoutWidget1) self.StatusLayout.setMargin(0) self.StatusLayout.setObjectName(_fromUtf8("StatusLayout")) self.labelConn = QtGui.QLabel(self.layoutWidget1) self.labelConn.setObjectName(_fromUtf8("labelConn")) self.StatusLayout.addWidget(self.labelConn, 0, 0, 1, 1) self.labelConnStat = QtGui.QLabel(self.layoutWidget1) font = QtGui.QFont() font.setBold(True) font.setWeight(75) self.labelConnStat.setFont(font) self.labelConnStat.setObjectName(_fromUtf8("labelConnStat")) self.StatusLayout.addWidget(self.labelConnStat, 0, 1, 1, 1) self.labelOS = QtGui.QLabel(self.layoutWidget1) self.labelOS.setObjectName(_fromUtf8("labelOS")) self.StatusLayout.addWidget(self.labelOS, 1, 0, 1, 1) self.labelOSStat = QtGui.QLabel(self.layoutWidget1) font = QtGui.QFont() font.setBold(True) font.setWeight(75) self.labelOSStat.setFont(font) self.labelOSStat.setObjectName(_fromUtf8("labelOSStat")) self.StatusLayout.addWidget(self.labelOSStat, 1, 1, 1, 1) self.InfoBox = QtGui.QGroupBox(self.mainFrame) self.InfoBox.setGeometry(QtCore.QRect(10, 220, 240, 90)) sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Fixed, QtGui.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth(self.InfoBox.sizePolicy().hasHeightForWidth()) self.InfoBox.setSizePolicy(sizePolicy) self.InfoBox.setObjectName(_fromUtf8("InfoBox")) self.layoutWidget2 = QtGui.QWidget(self.InfoBox) self.layoutWidget2.setGeometry(QtCore.QRect(10, 20, 221, 59)) self.layoutWidget2.setObjectName(_fromUtf8("layoutWidget2")) self.InfoLayout = QtGui.QGridLayout(self.layoutWidget2) self.InfoLayout.setMargin(0) self.InfoLayout.setObjectName(_fromUtf8("InfoLayout")) self.labelVersion = QtGui.QLabel(self.layoutWidget2) self.labelVersion.setObjectName(_fromUtf8("labelVersion")) self.InfoLayout.addWidget(self.labelVersion, 0, 0, 1, 1) self.labelVersionData = QtGui.QLabel(self.layoutWidget2) self.labelVersionData.setObjectName(_fromUtf8("labelVersionData")) self.InfoLayout.addWidget(self.labelVersionData, 0, 1, 1, 1) self.labelRelease = QtGui.QLabel(self.layoutWidget2) self.labelRelease.setObjectName(_fromUtf8("labelRelease")) self.InfoLayout.addWidget(self.labelRelease, 1, 0, 1, 1) self.labelReleaseData = QtGui.QLabel(self.layoutWidget2) self.labelReleaseData.setObjectName(_fromUtf8("labelReleaseData")) self.InfoLayout.addWidget(self.labelReleaseData, 1, 1, 1, 1) self.labelLatest = QtGui.QLabel(self.layoutWidget2) self.labelLatest.setObjectName(_fromUtf8("labelLatest")) self.InfoLayout.addWidget(self.labelLatest, 2, 0, 1, 1) self.labelLatestData = QtGui.QLabel(self.layoutWidget2) self.labelLatestData.setObjectName(_fromUtf8("labelLatestData")) self.InfoLayout.addWidget(self.labelLatestData, 2, 1, 1, 1) self.FunctionsBox = QtGui.QGroupBox(self.mainFrame) self.FunctionsBox.setGeometry(QtCore.QRect(260, 20, 250, 290)) self.FunctionsBox.setObjectName(_fromUtf8("FunctionsBox")) self.Functionlist = QtGui.QListWidget(self.FunctionsBox) self.Functionlist.setGeometry(QtCore.QRect(10, 20, 230, 260)) sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Expanding) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth(self.Functionlist.sizePolicy().hasHeightForWidth()) self.Functionlist.setSizePolicy(sizePolicy) self.Functionlist.setObjectName(_fromUtf8("Functionlist")) self.frame = QtGui.QFrame(self.mainFrame) self.frame.setGeometry(QtCore.QRect(520, 30, 110, 280)) self.frame.setFrameShape(QtGui.QFrame.NoFrame) self.frame.setFrameShadow(QtGui.QFrame.Raised) self.frame.setLineWidth(0) self.frame.setObjectName(_fromUtf8("frame")) self.ButtonBackup = QtGui.QPushButton(self.frame) self.ButtonBackup.setGeometry(QtCore.QRect(0, 10, 48, 48)) self.ButtonBackup.setText(_fromUtf8("")) icon1 = QtGui.QIcon() icon1.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_backup.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off) icon1.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_backup_disabled.png")), QtGui.QIcon.Disabled, QtGui.QIcon.Off) self.ButtonBackup.setIcon(icon1) self.ButtonBackup.setIconSize(QtCore.QSize(32, 32)) self.ButtonBackup.setObjectName(_fromUtf8("ButtonBackup")) self.ButtonUpdate = QtGui.QPushButton(self.frame) self.ButtonUpdate.setGeometry(QtCore.QRect(60, 70, 48, 48)) self.ButtonUpdate.setText(_fromUtf8("")) icon2 = QtGui.QIcon() icon2.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_download.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off) icon2.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_download_disabled.png")), QtGui.QIcon.Disabled, QtGui.QIcon.Off) self.ButtonUpdate.setIcon(icon2) self.ButtonUpdate.setIconSize(QtCore.QSize(32, 32)) self.ButtonUpdate.setObjectName(_fromUtf8("ButtonUpdate")) self.ButtonRestore = QtGui.QPushButton(self.frame) self.ButtonRestore.setGeometry(QtCore.QRect(60, 10, 48, 48)) self.ButtonRestore.setText(_fromUtf8("")) icon3 = QtGui.QIcon() icon3.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_restore.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off) icon3.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_restore_disabled.png")), QtGui.QIcon.Disabled, QtGui.QIcon.Off) self.ButtonRestore.setIcon(icon3) self.ButtonRestore.setIconSize(QtCore.QSize(32, 32)) self.ButtonRestore.setObjectName(_fromUtf8("ButtonRestore")) self.ButtonApply = QtGui.QPushButton(self.frame) self.ButtonApply.setGeometry(QtCore.QRect(0, 220, 48, 48)) self.ButtonApply.setText(_fromUtf8("")) icon4 = QtGui.QIcon() icon4.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_apply.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off) icon4.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_apply_disabled.png")), QtGui.QIcon.Disabled, QtGui.QIcon.Off) self.ButtonApply.setIcon(icon4) self.ButtonApply.setIconSize(QtCore.QSize(32, 32)) self.ButtonApply.setObjectName(_fromUtf8("ButtonApply")) self.ButtonExit = QtGui.QPushButton(self.frame) self.ButtonExit.setGeometry(QtCore.QRect(60, 220, 48, 48)) self.ButtonExit.setText(_fromUtf8("")) icon5 = QtGui.QIcon() icon5.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_exit.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off) icon5.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_exit_disabled.png")), QtGui.QIcon.Disabled, QtGui.QIcon.Off) self.ButtonExit.setIcon(icon5) self.ButtonExit.setIconSize(QtCore.QSize(32, 32)) self.ButtonExit.setObjectName(_fromUtf8("ButtonExit")) self.ButtonCheck = QtGui.QPushButton(self.frame) self.ButtonCheck.setGeometry(QtCore.QRect(0, 70, 48, 48)) self.ButtonCheck.setText(_fromUtf8("")) icon6 = QtGui.QIcon() icon6.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_update.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off) icon6.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_update_disabled.png")), QtGui.QIcon.Disabled, QtGui.QIcon.Off) self.ButtonCheck.setIcon(icon6) self.ButtonCheck.setIconSize(QtCore.QSize(32, 32)) self.ButtonCheck.setObjectName(_fromUtf8("ButtonCheck")) self.ButtonANSI = QtGui.QPushButton(self.frame) self.ButtonANSI.setGeometry(QtCore.QRect(0, 160, 48, 48)) self.ButtonANSI.setText(_fromUtf8("")) icon7 = QtGui.QIcon() icon7.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_ansi.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off) icon7.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_ansi_disabled.png")), QtGui.QIcon.Disabled, QtGui.QIcon.Off) self.ButtonANSI.setIcon(icon7) self.ButtonANSI.setIconSize(QtCore.QSize(32, 32)) self.ButtonANSI.setObjectName(_fromUtf8("ButtonANSI")) self.ButtonUTF = QtGui.QPushButton(self.frame) self.ButtonUTF.setGeometry(QtCore.QRect(60, 160, 48, 48)) self.ButtonUTF.setText(_fromUtf8("")) icon8 = QtGui.QIcon() icon8.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_utf8.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off) icon8.addPixmap(QtGui.QPixmap(_fromUtf8(":/buttons/res/img/buttons/button_utf8_disabled.png")), QtGui.QIcon.Disabled, QtGui.QIcon.Off) self.ButtonUTF.setIcon(icon8) self.ButtonUTF.setIconSize(QtCore.QSize(32, 32)) self.ButtonUTF.setObjectName(_fromUtf8("ButtonUTF")) self.SelectLang = QtGui.QComboBox(self.mainFrame) self.SelectLang.setGeometry(QtCore.QRect(520, 320, 108, 25)) self.SelectLang.setObjectName(_fromUtf8("SelectLang")) self.Prog = QtGui.QProgressBar(self.mainFrame) self.Prog.setGeometry(QtCore.QRect(10, 320, 500, 25)) self.Prog.setAlignment(QtCore.Qt.AlignCenter) self.Prog.setTextVisible(True) self.Prog.setInvertedAppearance(False) self.Prog.setObjectName(_fromUtf8("Prog")) self.TitleLabel = QtGui.QLabel(Util) self.TitleLabel.setGeometry(QtCore.QRect(20, 20, 250, 25)) self.TitleLabel.setObjectName(_fromUtf8("TitleLabel")) self.Copyright = QtGui.QLabel(Util) self.Copyright.setGeometry(QtCore.QRect(330, 390, 300, 16)) self.Copyright.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter) self.Copyright.setObjectName(_fromUtf8("Copyright")) self.label = QtGui.QLabel(Util) self.label.setGeometry(QtCore.QRect(10, 390, 150, 16)) self.label.setObjectName(_fromUtf8("label")) self.VersionLabel = QtGui.QLabel(Util) self.VersionLabel.setGeometry(QtCore.QRect(380, 20, 250, 25)) self.VersionLabel.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter) self.VersionLabel.setObjectName(_fromUtf8("VersionLabel")) self.labelIP.setBuddy(self.SelectMirror) self.labelMirror.setBuddy(self.SelectIP) self.retranslateUi(Util) QtCore.QObject.connect(self.ButtonExit, QtCore.SIGNAL(_fromUtf8("clicked()")), Util.close) QtCore.QObject.connect(self.SelectIP, QtCore.SIGNAL(_fromUtf8("currentIndexChanged(int)")), Util.on_IPVersion_changed) QtCore.QObject.connect(self.SelectMirror, QtCore.SIGNAL(_fromUtf8("currentIndexChanged(int)")), Util.on_Mirror_changed) QtCore.QObject.connect(self.Functionlist, QtCore.SIGNAL(_fromUtf8("itemChanged(QListWidgetItem*)")), Util.on_Selection_changed) QtCore.QObject.connect(self.ButtonApply, QtCore.SIGNAL(_fromUtf8("clicked()")), Util.on_MakeHosts_clicked) QtCore.QObject.connect(self.ButtonBackup, QtCore.SIGNAL(_fromUtf8("clicked()")), Util.on_Backup_clicked) QtCore.QObject.connect(self.ButtonRestore, QtCore.SIGNAL(_fromUtf8("clicked()")), Util.on_Restore_clicked) QtCore.QObject.connect(self.ButtonCheck, QtCore.SIGNAL(_fromUtf8("clicked()")), Util.on_CheckUpdate_clicked) QtCore.QObject.connect(self.ButtonUpdate, QtCore.SIGNAL(_fromUtf8("clicked()")), Util.on_FetchUpdate_clicked) QtCore.QObject.connect(self.SelectLang, QtCore.SIGNAL(_fromUtf8("currentIndexChanged(QString)")), Util.on_Lang_changed) QtCore.QObject.connect(self.ButtonANSI, QtCore.SIGNAL(_fromUtf8("clicked()")), Util.on_MakeANSI_clicked) QtCore.QObject.connect(self.ButtonUTF, QtCore.SIGNAL(_fromUtf8("clicked()")), Util.on_MakeUTF8_clicked) QtCore.QObject.connect(self.Copyright, QtCore.SIGNAL(_fromUtf8("linkActivated(QString)")), Util.on_LinkActivated) QtCore.QMetaObject.connectSlotsByName(Util) Util.setTabOrder(self.SelectMirror, self.SelectIP) Util.setTabOrder(self.SelectIP, self.Functionlist) Util.setTabOrder(self.Functionlist, self.ButtonApply) Util.setTabOrder(self.ButtonApply, self.ButtonExit) Util.setTabOrder(self.ButtonExit, self.ButtonCheck) Util.setTabOrder(self.ButtonCheck, self.ButtonUpdate) Util.setTabOrder(self.ButtonUpdate, self.ButtonBackup) Util.setTabOrder(self.ButtonBackup, self.ButtonRestore) Util.setTabOrder(self.ButtonRestore, self.ButtonANSI) Util.setTabOrder(self.ButtonANSI, self.ButtonUTF) Util.setTabOrder(self.ButtonUTF, self.SelectLang) def retranslateUi(self, Util): Util.setWindowTitle(_translate("Util", "Hosts Setup Utility", None)) self.ConfigBox.setTitle(_translate("Util", "Config", None)) self.labelIP.setText(_translate("Util", "Server", None)) self.labelMirror.setText(_translate("Util", "IP Version", None)) self.StatusBox.setTitle(_translate("Util", "Status", None)) self.labelConn.setText(_translate("Util", "Connection", None)) self.labelConnStat.setText(_translate("Util", "N/A", None)) self.labelOS.setText(_translate("Util", "OS", None)) self.labelOSStat.setText(_translate("Util", "N/A", None)) self.InfoBox.setTitle(_translate("Util", "Hosts Info", None)) self.labelVersion.setText(_translate("Util", "Version", None)) self.labelVersionData.setText(_translate("Util", "N/A", None)) self.labelRelease.setText(_translate("Util", "Release", None)) self.labelReleaseData.setText(_translate("Util", "N/A", None)) self.labelLatest.setText(_translate("Util", "Latest", None)) self.labelLatestData.setText(_translate("Util", "N/A", None)) self.FunctionsBox.setTitle(_translate("Util", "Functions", None)) self.ButtonBackup.setToolTip(_translate("Util", "Backup hosts", None)) self.ButtonBackup.setWhatsThis(_translate("Util", "Backup the hosts file of current system.", None)) self.ButtonUpdate.setToolTip(_translate("Util", "Download data file", None)) self.ButtonUpdate.setWhatsThis(_translate("Util", "Download the latest data file.", None)) self.ButtonRestore.setToolTip(_translate("Util", "Restore backup", None)) self.ButtonRestore.setWhatsThis(_translate("Util", "Restore a previous backup of hosts file.", None)) self.ButtonApply.setToolTip(_translate("Util", "Apply hosts", None)) self.ButtonApply.setWhatsThis(_translate("Util", "Apply changes to the hosts file.", None)) self.ButtonExit.setToolTip(_translate("Util", "Exit", None)) self.ButtonExit.setWhatsThis(_translate("Util", "Close this tool.", None)) self.ButtonCheck.setToolTip(_translate("Util", "Check update / Refresh", None)) self.ButtonCheck.setWhatsThis(_translate("Util", "Check the latest version of hosts data file.", None)) self.ButtonANSI.setToolTip(_translate("Util", "Save with ANSI", None)) self.ButtonANSI.setWhatsThis(_translate("Util", "Export to hosts file encoding by ANSI.", None)) self.ButtonUTF.setToolTip(_translate("Util", "Save with UTF-8", None)) self.ButtonUTF.setWhatsThis(_translate("Util", "Export to hosts file encoding by UTF-8.", None)) self.TitleLabel.setText(_translate("Util", "Hosts Setup Utility", None)) self.Copyright.setText(_translate("Util", "Copyleft (C) 2011-2014 <a href=\"https://hosts.huhamhire.com/\"><span style=\"text-decoration: none;color: #b1b1b1;\">huhamhire-hosts</span></a>", None)) self.label.setText(_translate("Util", "Powered by PyQT", None)) import util_rc import style_rc if __name__ == "__main__": import sys app = QtGui.QApplication(sys.argv) Util = QtGui.QDialog() ui = Ui_Util() ui.setupUi(Util) Util.show() sys.exit(app.exec_())
20,892
Python
.py
327
55.422018
204
0.711603
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,266
style_rc.py
huhamhire_huhamhire-hosts/gui/style_rc.py
# -*- coding: utf-8 -*- # Resource object code # # Created: 周三 1月 22 13:03:07 2014 # by: The Resource Compiler for PyQt (Qt v4.8.5) # # WARNING! All changes made in this file will be lost! from PyQt4 import QtCore qt_resource_data = "\ \x00\x00\x01\x57\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x09\x00\x00\x00\x09\x08\x06\x00\x00\x00\xe0\x91\x06\x10\ \x00\x00\x00\x09\x70\x48\x59\x73\x00\x00\x0e\xc4\x00\x00\x0e\xc4\ \x01\x95\x2b\x0e\x1b\x00\x00\x00\x20\x63\x48\x52\x4d\x00\x00\x7a\ \x25\x00\x00\x80\x83\x00\x00\xf9\xff\x00\x00\x80\xe9\x00\x00\x75\ \x30\x00\x00\xea\x60\x00\x00\x3a\x98\x00\x00\x17\x6f\x92\x5f\xc5\ \x46\x00\x00\x00\xdd\x49\x44\x41\x54\x78\xda\x5c\x8e\xb1\x4e\x84\ \x40\x18\x84\x67\xef\x4c\x2c\xc8\xd9\x2c\x0d\x58\x50\x1b\x0b\xc3\ \xfa\x24\x77\xbd\x0d\x85\x4f\x40\x0b\xbb\xcb\x3b\xd0\x68\x41\x72\ \xc5\xd2\x28\x4f\x02\xcf\xb1\x97\x40\x61\xd4\xc2\xc4\x62\x2c\xbc\ \x4d\xd0\x49\xfe\xbf\xf8\x32\xff\x3f\x23\x48\xc2\x5a\x3b\x00\x80\ \xd6\xfa\x80\xb3\xac\xb5\x03\x49\x18\x63\x0e\x5b\x21\xc4\x90\xe7\ \xf9\x3e\x49\x92\x9b\xbe\xef\xef\xca\xb2\x7c\xf5\xde\xbf\x04\xe6\ \x9c\xbb\xbd\x20\xf9\x19\xae\x95\x52\xfb\x2c\xcb\xbe\xa5\x94\x01\ \x81\xe4\x9b\x38\xbf\x3c\x2a\xa5\x1e\xf0\x4f\xe3\x38\x3e\x37\x4d\ \xf3\x28\x48\x02\x00\xba\xae\x7b\x97\x52\xee\x82\x61\x59\x96\x8f\ \xa2\x28\xae\x00\x60\x03\x00\xc6\x98\xe3\xda\x00\x00\x71\x1c\xef\ \xb4\xd6\x4f\x00\xb0\x05\xf0\x27\x6a\x9e\x67\x44\x51\x04\x00\x48\ \xd3\xf4\xde\x39\x77\xbd\x21\xf9\xb5\xea\x70\x6a\xdb\xf6\x72\x9a\ \xa6\xd3\xaa\xf8\xef\xaa\xeb\xda\x57\x55\xe5\x49\x22\xcc\x9a\xfd\ \x0c\x00\x24\xab\x6e\xfa\x96\x21\xfc\xb8\x00\x00\x00\x00\x49\x45\ \x4e\x44\xae\x42\x60\x82\ \x00\x00\x03\xf0\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x07\x00\x00\x00\x05\x08\x04\x00\x00\x00\x23\x93\x3e\x53\ \x00\x00\x00\x09\x70\x48\x59\x73\x00\x00\x0b\x13\x00\x00\x0b\x13\ \x01\x00\x9a\x9c\x18\x00\x00\x03\x18\x69\x43\x43\x50\x50\x68\x6f\ \x74\x6f\x73\x68\x6f\x70\x20\x49\x43\x43\x20\x70\x72\x6f\x66\x69\ \x6c\x65\x00\x00\x78\xda\x63\x60\x60\x9e\xe0\xe8\xe2\xe4\xca\x24\ \xc0\xc0\x50\x50\x54\x52\xe4\x1e\xe4\x18\x19\x11\x19\xa5\xc0\x7e\ \x9e\x81\x8d\x81\x99\x81\x81\x81\x81\x81\x21\x31\xb9\xb8\xc0\x31\ \x20\xc0\x87\x81\x81\x81\x21\x2f\x3f\x2f\x95\x01\x15\x30\x32\x30\ \x7c\xbb\xc6\xc0\xc8\xc0\xc0\xc0\x70\x59\xd7\xd1\xc5\xc9\x95\x81\ \x34\xc0\x9a\x5c\x50\x54\xc2\xc0\xc0\x70\x80\x81\x81\xc1\x28\x25\ \xb5\x38\x99\x81\x81\xe1\x0b\x03\x03\x43\x7a\x79\x49\x41\x09\x03\ \x03\x63\x0c\x03\x03\x83\x48\x52\x76\x41\x09\x03\x03\x63\x01\x03\ \x03\x83\x48\x76\x48\x90\x33\x03\x03\x63\x0b\x03\x03\x13\x4f\x49\ \x6a\x45\x09\x03\x03\x03\x83\x73\x7e\x41\x65\x51\x66\x7a\x46\x89\ \x82\xa1\xa5\xa5\xa5\x82\x63\x4a\x7e\x52\xaa\x42\x70\x65\x71\x49\ \x6a\x6e\xb1\x82\x67\x5e\x72\x7e\x51\x41\x7e\x51\x62\x49\x6a\x0a\ \x03\x03\x03\xd4\x0e\x06\x06\x06\x06\x5e\x97\xfc\x12\x05\xf7\xc4\ \xcc\x3c\x05\x23\x03\x55\x06\x2a\x83\x88\xc8\x28\x05\x08\x0b\x11\ \x3e\x08\x31\x04\x48\x2e\x2d\x2a\x83\x07\x25\x03\x83\x00\x83\x02\ \x83\x01\x83\x03\x43\x00\x43\x22\x43\x3d\xc3\x02\x86\xa3\x0c\x6f\ \x18\xc5\x19\x5d\x18\x4b\x19\x57\x30\xde\x63\x12\x63\x0a\x62\x9a\ \xc0\x74\x81\x59\x98\x39\x92\x79\x21\xf3\x1b\x16\x4b\x96\x0e\x96\ \x5b\xac\x7a\xac\xad\xac\xf7\xd8\x2c\xd9\xa6\xb1\x7d\x63\x0f\x67\ \xdf\xcd\xa1\xc4\xd1\xc5\xf1\x85\x33\x91\xf3\x02\x97\x23\xd7\x16\ \x6e\x4d\xee\x05\x3c\x52\x3c\x53\x79\x85\x78\x27\xf1\x09\xf3\x4d\ \xe3\x97\xe1\x5f\x2c\xa0\x23\xb0\x43\xd0\x55\xf0\x8a\x50\xaa\xd0\ \x0f\xe1\x5e\x11\x15\x91\xbd\xa2\xe1\xa2\x5f\xc4\x26\x89\x1b\x89\ \x5f\x91\xa8\x90\x94\x93\x3c\x26\x95\x2f\x2d\x2d\x7d\x42\xa6\x4c\ \x56\x5d\xf6\x96\x5c\x9f\xbc\x8b\xfc\x1f\x85\xad\x8a\x85\x4a\x7a\ \x4a\x6f\x95\xd7\xaa\x14\xa8\x9a\xa8\xfe\x54\x3b\xa8\xde\xa5\x11\ \xaa\xa9\xa4\xf9\x41\xeb\x80\xf6\x24\x9d\x54\x5d\x2b\x3d\x41\xbd\ \x57\xfa\x47\x0c\x16\x18\xd6\x1a\xc5\x18\xdb\x9a\xc8\x9b\x32\x9b\ \xbe\x34\xbb\x60\xbe\xd3\x62\x89\xe5\x04\xab\x3a\xeb\x5c\x9b\x38\ \xdb\x40\x3b\x57\x7b\x6b\x07\x63\x47\x1d\x27\x35\x67\x25\x17\x05\ \x57\x79\x37\x05\x77\x65\x0f\x75\x4f\x5d\x2f\x13\x6f\x1b\x1f\x77\ \xdf\x60\xbf\x04\xff\xfc\x80\xfa\xc0\x89\x41\x4b\x83\x77\x85\x5c\ \x0c\x7d\x19\xce\x14\x21\x17\x69\x15\x15\x11\x5d\x11\x33\x33\x76\ \x4f\xdc\x83\x04\xb6\x44\xdd\xa4\xb0\xe4\x86\x94\x35\xa9\x37\xd3\ \x39\x32\x2c\x32\x33\xb3\xe6\x66\x5f\xcc\x65\xcf\xb3\xcf\xaf\x28\ \xd8\x54\xf8\xae\x58\xbb\x24\xab\x74\x55\xd9\x9b\x0a\xfd\xca\x92\ \xaa\x5d\x35\x8c\xb5\x5e\x75\x53\xeb\x1f\x36\xea\x35\xd5\x34\x9f\ \x6d\x95\x6b\x2b\x6c\x3f\xda\x29\xdd\x55\xd4\x7d\xba\x57\xb5\xaf\ \xb1\xff\xee\x44\x9b\x49\xb3\x27\xff\x9d\x1a\x3f\xed\xf0\x0c\x8d\ \x99\xfd\xb3\xbe\xcf\x49\x98\x7b\x7a\xbe\xf9\x82\xa5\x8b\x44\x16\ \xb7\x2e\xf9\xb6\x2c\x73\xf9\xbd\x95\x21\xab\x4e\xaf\x71\x59\xbb\ \x6f\xbd\xe5\x86\x6d\x9b\x4c\x36\x6f\xd9\x6a\xb2\x6d\xfb\x0e\xab\ \x9d\xfb\x77\xbb\xee\x39\xbb\x2f\x6c\xff\x83\x83\x39\x87\x7e\x1e\ \x69\x3f\x26\x7e\x7c\xc5\x49\xeb\x53\xe7\xce\x24\x9f\xfd\x75\x7e\ \xd2\x45\xed\x4b\x47\xaf\x24\x5e\xfd\x77\x7d\xce\x4d\x9b\x5b\x77\ \xef\xd4\xdf\x53\xbe\x7f\xe2\x61\xde\x63\xb1\x27\xfb\x9f\x65\xbe\ \x10\x79\x79\xf0\x75\xfe\x5b\xf9\x77\x17\x3e\x34\x7d\x32\xfd\xfc\ \xea\xeb\x82\xef\xe1\x3f\x05\x7e\x9d\xfa\xd3\xfa\xcf\xf1\xff\x7f\ \x00\x0d\x00\x0f\x34\xfa\x96\xf1\x5d\x00\x00\x00\x20\x63\x48\x52\ \x4d\x00\x00\x7a\x25\x00\x00\x80\x83\x00\x00\xf9\xff\x00\x00\x80\ \xe9\x00\x00\x75\x30\x00\x00\xea\x60\x00\x00\x3a\x98\x00\x00\x17\ \x6f\x92\x5f\xc5\x46\x00\x00\x00\x52\x49\x44\x41\x54\x78\xda\x62\ \x58\xf5\xe9\xca\x3f\x18\x5c\xfe\x9e\x21\xd3\xff\xc4\x8f\xab\xbf\ \xaf\xfe\xbe\xfa\xfb\xd0\x97\x68\x63\x86\xff\x0c\x85\x6b\xf7\x7e\ \xdc\xfb\x71\xf3\x87\xcc\xbc\xff\x0c\x0c\xff\x19\x18\x98\x73\xce\ \xce\xbd\x1f\x39\xff\x3f\xc3\x7f\x06\x86\xff\x0c\xff\x19\x14\xdd\ \x2c\xb6\xfe\x67\xf8\xcf\xf0\x9f\x01\x30\x00\x6a\x5f\x2c\x67\x74\ \xda\xec\xfb\x00\x00\x00\x00\x49\x45\x4e\x44\xae\x42\x60\x82\ " qt_resource_name = "\ \x00\x03\ \x00\x00\x78\xa3\ \x00\x71\ \x00\x73\x00\x73\ \x00\x03\ \x00\x00\x78\xc3\ \x00\x72\ \x00\x65\x00\x73\ \x00\x03\ \x00\x00\x70\x37\ \x00\x69\ \x00\x6d\x00\x67\ \x00\x05\ \x00\x7a\xc0\x25\ \x00\x73\ \x00\x74\x00\x79\x00\x6c\x00\x65\ \x00\x0c\ \x04\x56\x23\x67\ \x00\x63\ \x00\x68\x00\x65\x00\x63\x00\x6b\x00\x62\x00\x6f\x00\x78\x00\x2e\x00\x70\x00\x6e\x00\x67\ \x00\x0e\ \x04\xa2\xfc\xa7\ \x00\x64\ \x00\x6f\x00\x77\x00\x6e\x00\x5f\x00\x61\x00\x72\x00\x72\x00\x6f\x00\x77\x00\x2e\x00\x70\x00\x6e\x00\x67\ " qt_resource_struct = "\ \x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x01\ \x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x02\ \x00\x00\x00\x0c\x00\x02\x00\x00\x00\x01\x00\x00\x00\x03\ \x00\x00\x00\x18\x00\x02\x00\x00\x00\x01\x00\x00\x00\x04\ \x00\x00\x00\x24\x00\x02\x00\x00\x00\x02\x00\x00\x00\x05\ \x00\x00\x00\x34\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\ \x00\x00\x00\x52\x00\x00\x00\x00\x00\x01\x00\x00\x01\x5b\ " def qInitResources(): QtCore.qRegisterResourceData(0x01, qt_resource_struct, qt_resource_name, qt_resource_data) def qCleanupResources(): QtCore.qUnregisterResourceData(0x01, qt_resource_struct, qt_resource_name, qt_resource_data) qInitResources()
7,095
Python
.py
139
49.884892
105
0.736531
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,267
__doc__.py
huhamhire_huhamhire-hosts/gui/__doc__.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # __doc__.py : Document in reST format of gui module. # # Copyleft (C) 2014 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== """ .. _gui-module: Graphical User Interface (GUI) ============================== The following sections describe the objects and methods from the Graphical User Interface (GUI) module of huhamhire-hosts HostsUtil. The methods to make GUI here are based on `PyQT4 <http://pyqt.sourceforge.net/Docs/PyQt4/>`_. HostsUtil(GUI) -------------- .. autoclass:: gui.hostsutil.HostsUtil :members: .. automethod:: gui.hostsutil.HostsUtil.__del__ QDialogSlots ------------ .. autoclass:: gui.qdialog_slots.QDialogSlots :members: .. automethod:: gui.qdialog_slots.QDialogSlots.__init__ LangUtil -------- .. autoclass:: gui.language.LangUtil :members: QDialogDaemon ------------- .. autoclass:: gui.qdialog_d.QDialogDaemon :members: QDialogUI --------- .. autoclass:: gui.qdialog_ui.QDialogUI :members: .. automethod:: gui.qdialog_ui.QDialogUI.__init__ QSubChkConnection ----------------- .. autoclass:: gui._checkconn.QSubChkConnection :members: .. automethod:: gui._checkconn.QSubChkConnection.__init__ QSubChkUpdate ------------- .. autoclass:: gui._checkupdate.QSubChkUpdate :members: .. automethod:: gui._checkupdate.QSubChkUpdate.__init__ QSubFetchUpdate --------------- .. autoclass:: gui._update.QSubFetchUpdate :members: .. automethod:: gui._update.QSubFetchUpdate.__init__ QSubMakeHosts ------------- .. autoclass:: gui._make.QSubMakeHosts :members: .. automethod:: gui._make.QSubMakeHosts.__init__ .. _qt-resource-modules: Resource Modules ---------------- All Qt Project files and resource files are convented into python Resource Modules in order to be used by `Hosts Setup Utility`. Including: * util_ui.py: :class:`~gui.util_ui.Ui_Util` class organizing layout of the main dialog for `Hosts Setup Utility`. This file is translated from the UI project file `util_ui.ui`. .. seealso:: `util_ui.ui` in :ref:`QT Project Files <qt-project-files>`. * util_rc.py: Images resources used by the main dialog. * style_rc.py: Images resources used by the default `Qt Stylesheet`. .. seealso:: :ref:`QT Stylesheet <qt-stylesheet>`. .. seealso:: `_pyuic4.py` in :ref:`QT Project Scripts <qt-project-scripts>`. .. _qt-project-files: QT Project Files ---------------- Qt Project Files and Qt resources files used to design the Qt user interface are provided in the "`gui/pyqt/`" directory, including: * util.pro: QT Project file containing configuration of current project. * util.qrc: Resource file for main dialog generated by `Qt Designer`. * style.qrc: Resource file for the default `Qt Style Sheet` generated by `Qt Designer`. .. seealso:: :ref:`QT Stylesheet <qt-stylesheet>`. * util_ui.ui: UI project file for the main dialog designed with `Qt designer`. .. seealso:: `Qt Designer <http://qt-project.org/doc/qt-4.8/designer-manual.html>`_. .. _qt-project-scripts: QT Project Scripts ------------------ Scripts to help managing the Qt project are also provided in the "`gui/pyqt/`" directory: * _pylupdate4.py: Contains tools to update the language files for UI. .. note:: This script would parse files declared as `SOURCES` in the Qt project file (`gui/pyqt/util.pro`), and generate/update language files declared as `TRANSLATIONS` in the Qt project file. .. seealso:: :ref:`Language Files <qt-language-files>`. * _pyuic4.py: Tools used to update the `UI module` and `Resource Modules` from `UI file` and `Resources Files` designed with `Qt designer`. .. seealso:: :ref:`Resource Modules <qt-resource-modules>`. .. _qt-language-files: Language Files -------------- Since this GUI module of `Hosts Setup Utility` is based on :mod:`PyQt4`, it is very easy to internationalization this utility with the ways Qt provided. The `Qt Language Files` are stored in "`gui/lang/`" directory with file suffixes "`.qm`" and "`.ts`". .. note:: **File Types** `Hosts Setup Utility` makes use of two kinds of files: * TS: `translation source files` are human-readable XML files containing source phrases and their translations. These files are usually created and updated by `lupdate` and are specific to an application. * QM: `Qt message files` are binary files that contain translations used by an application at run-time. These files are generated by lrelease, but can also be generated by `Qt Linguist`. .. note:: You can use `_pylupdate4.py` provided in "`gui/pyqt/`" directory to generate/update `TS` files with the Qt project file. And then use `Qt Linguist` to make a `QM` file. .. seealso:: `_pylupdate4.py` in :ref:`QT Project Scripts<qt-project-scripts>`. .. seealso:: `Qt Linguist <http://qt-project.org/doc/qt-4.8/linguist-translators.html>`_. .. _qt-stylesheet: QT Stylesheet ------------- With the GUI module of `Hosts Setup Utility` is based on :mod:`PyQt4`, Qt style sheets are also supported to customize the appearance of GUI widgets. The `Qt Style Sheets` are stored in "`gui/theme/`" directory with file suffix "`.qss`". You can create yourown Qt style sheet and use it in method :meth:`~gui.qdialog_ui.QDialogUI.set_stylesheet` to customize new appearance of GUI widgets. .. seealso:: Method :meth:`~gui.qdialog_ui.QDialogUI.set_stylesheet` in :class:`~gui.qdialog_ui.QDialogUI` class. .. note:: Qt Style Sheets are a powerful mechanism that allows you to customize the appearance of widgets, in addition to what is already possible by subclassing QStyle. The concepts, terminology, and syntax of Qt Style Sheets are heavily inspired by HTML Cascading Style Sheets (CSS) but adapted to the world of widgets. .. seealso:: `QT Stylesheet <http://qt-project.org/doc/qt-4.8/stylesheet.html>`_. """
6,277
Python
.py
146
40.041096
78
0.692574
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,268
util_rc.py
huhamhire_huhamhire-hosts/gui/util_rc.py
# -*- coding: utf-8 -*- # Resource object code # # Created: 周三 1月 22 13:03:07 2014 # by: The Resource Compiler for PyQt (Qt v4.8.5) # # WARNING! All changes made in this file will be lost! from PyQt4 import QtCore qt_resource_data = "\ \x00\x00\x04\xf8\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x38\x34\x39\ \x36\x35\x45\x39\x33\x35\x39\x38\x35\x31\x31\x45\x33\x42\x38\x30\ \x33\x45\x39\x42\x31\x37\x42\x32\x36\x32\x41\x35\x41\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x38\x34\x39\x36\x35\x45\x39\ \x32\x35\x39\x38\x35\x31\x31\x45\x33\x42\x38\x30\x33\x45\x39\x42\ \x31\x37\x42\x32\x36\x32\x41\x35\x41\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x63\x31\x65\x61\x38\x31\x32\x35\ \x2d\x65\x62\x64\x64\x2d\x63\x38\x34\x62\x2d\x39\x66\x37\x61\x2d\ \x30\x36\x39\x39\x32\x39\x38\x64\x62\x39\x33\x63\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\xcf\x3d\ \xf2\xba\x00\x00\x01\x1d\x49\x44\x41\x54\x78\xda\x62\xcc\xcb\xcb\ \x3b\xc7\xc0\xc0\x60\xc8\x80\x1d\xfc\x05\xe2\xb0\x49\x93\x26\xad\ \x03\x71\x80\x6a\x13\x80\xd4\x3c\x20\x66\x64\xa0\x0e\x38\xcf\x84\ \xc7\x72\x10\x60\x06\x62\x3d\x24\xbe\x03\x15\x2d\x07\x01\x43\x26\ \x86\x01\x06\xa3\x0e\x18\x75\x00\xc8\x01\x9f\x08\xa8\xf9\x88\xc4\ \x7e\x4e\x65\xfb\x3f\xb1\x00\x09\x63\x20\xd6\xc1\xa1\xe0\x07\x10\ \xef\x41\xe2\x37\x00\xf1\x61\x20\x66\xa3\x92\x03\xae\x30\x8c\x78\ \xc0\x08\x2d\x5e\x1d\x70\xc8\x7f\x01\xe2\x0e\x60\x51\xfc\x04\x5a\ \x14\xab\x01\xa9\x62\x20\x66\xa7\x92\xfd\x07\x58\x88\x28\xdb\x5f\ \x01\x71\x13\x94\x5d\x08\xc4\x69\x54\x0c\x80\x38\x26\x22\xca\x76\ \xe4\xac\xca\x49\xed\x18\x18\x2d\x88\x46\x1d\x00\x72\xc0\x7f\x02\ \x6a\xfe\x21\xb1\xbf\x53\xd9\xfe\xff\xa0\x6c\x98\x44\xa0\x1c\x98\ \x87\xc4\xef\x87\x3a\x9a\x6a\xe5\xc0\x68\x51\x0c\x2a\x8a\x55\xf0\ \xd4\x86\xa0\x38\xdf\x0b\x2c\x8a\xff\x40\x8b\x62\x50\xd0\x3b\x53\ \xb3\x36\x04\xa5\x81\xb3\x40\xcc\x87\x47\x51\x11\x34\xee\x61\xd5\ \x71\x05\x35\xdb\x03\x4c\x04\x2c\x07\x01\x7e\x24\xb6\x24\x95\x63\ \x80\x6f\xb4\x20\x1a\x75\xc0\xa0\x70\xc0\x39\x3c\xf2\xa0\xfc\x7f\ \x09\xad\xe8\xfc\x4f\x45\xfb\xcf\x31\xfe\xff\xff\x7f\x40\x43\x00\ \x20\xc0\x00\xcb\x8e\x3a\x29\x41\x01\xac\xc1\x00\x00\x00\x00\x49\ \x45\x4e\x44\xae\x42\x60\x82\ \x00\x00\x05\xa0\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x31\x35\x41\ \x39\x46\x35\x46\x42\x35\x39\x38\x35\x31\x31\x45\x33\x38\x30\x36\ \x39\x39\x35\x43\x31\x38\x46\x35\x39\x35\x39\x46\x42\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x31\x35\x41\x39\x46\x35\x46\ \x41\x35\x39\x38\x35\x31\x31\x45\x33\x38\x30\x36\x39\x39\x35\x43\ \x31\x38\x46\x35\x39\x35\x39\x46\x42\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x63\x31\x65\x61\x38\x31\x32\x35\ \x2d\x65\x62\x64\x64\x2d\x63\x38\x34\x62\x2d\x39\x66\x37\x61\x2d\ \x30\x36\x39\x39\x32\x39\x38\x64\x62\x39\x33\x63\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\xec\xd9\ \x4e\x52\x00\x00\x01\xc5\x49\x44\x41\x54\x78\xda\x62\xfc\xff\xff\ \x3f\x03\x23\x23\x23\x03\x3e\xb0\x77\x5a\xd2\x04\x20\x95\xcf\x40\ \x1a\x98\xe8\x9c\x35\xaf\x00\x9f\x02\x90\xdd\x4c\x0c\x03\x0c\x58\ \x88\x54\x77\x0a\x88\x17\x92\x68\xf6\x29\x6a\x3a\x60\x07\x10\x1f\ \x23\xd1\x01\x9f\xa8\xe9\x80\x3a\x72\xd2\x00\x10\x17\x10\x52\x34\ \xe0\x69\x60\xc8\x24\xc2\x26\x20\x9e\x30\x90\x69\x20\x10\x88\x7d\ \x49\x74\xc0\x66\x20\x9e\x4b\x2d\x07\xe8\x02\xb1\x3f\x89\x0e\x78\ \x30\x24\xd2\xc0\xa8\x03\x58\xa0\x95\x4d\x22\x90\x92\xc7\xa3\xce\ \x82\x0c\xb3\x2d\x80\xe6\x36\xe0\x91\x7f\x08\xc4\xf3\x61\x89\x70\ \x1b\x10\xaf\x07\x62\x4b\x2a\x7a\xce\x1c\x8a\xb1\x81\xe3\xd0\x9c\ \x05\x89\x02\x60\xb5\xf9\x12\x48\x39\x92\x51\xe1\x90\x03\x40\x76\ \x38\x42\xed\x64\x60\x44\x6f\x0f\x00\x83\xad\x0c\x48\xb5\xd3\x20\ \x7d\xfc\x03\xe2\x4a\xa0\xc5\x5d\xc8\xed\x01\x46\x6c\x0d\x12\xa0\ \x23\xbc\x81\xd4\x72\x20\xe6\xa5\x92\xe5\x9f\x81\x38\x12\x68\xf9\ \x56\xf4\x06\x09\x23\xae\x16\x11\xd0\x11\xda\x40\x6a\x13\x10\x2b\ \x51\x68\xf9\x3d\x20\xf6\x03\x5a\x7e\x95\xa4\x16\x11\x54\x83\x19\ \x10\x1f\xa4\xc0\x72\x90\x5e\x33\x6c\x96\x13\x55\x0e\x00\x35\xbe\ \x05\x52\xae\x40\x3c\x93\x0c\xcb\x41\x7a\x5c\xa1\x66\xe0\x04\x8c\ \xc4\x34\x4a\xa1\x51\x92\x0b\xa4\xfa\x81\x98\x99\x80\xd2\xbf\x40\ \x5c\x08\xb4\x78\x32\x21\x33\xf1\xa6\x01\x1c\x8e\x70\x01\x52\xab\ \x81\x58\x00\x87\x92\x0f\x40\x1c\x0a\xb4\x7c\x0f\x31\xe6\x91\xec\ \x00\xa8\x23\xd4\xa0\x89\x53\x1d\x4d\xea\x26\x34\xb1\xdd\x22\xd6\ \x2c\xb2\x9a\xe5\x50\x0b\x40\x45\xf3\x2e\x24\xe1\xdd\x20\x31\x52\ \x2c\x27\x39\x0d\x60\x09\x09\x50\x5a\xe8\x85\x72\x8b\x81\x96\xff\ \x25\xd5\x0c\x78\x14\xec\x9b\x9e\x0c\x0a\x09\x4d\x20\x66\xa5\x53\ \x25\xf8\x1b\x88\x6f\x38\x65\xce\xfd\x0b\xab\x8c\xd6\x91\xd1\xe2\ \xa1\x14\x6c\x07\x62\x2f\x58\x1a\xf0\x1b\x80\xa6\x80\x27\x72\x41\ \xc4\xc8\x30\x40\x00\xe6\x80\x3f\x03\x60\xf7\x3f\x64\x07\x4c\x81\ \x09\xd0\xd1\xf2\xa9\x20\x06\x40\x80\x01\x00\x51\x94\x9c\xf8\x84\ \x67\x5d\xdc\x00\x00\x00\x00\x49\x45\x4e\x44\xae\x42\x60\x82\ \x00\x00\x07\x88\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x43\x42\x44\ \x44\x46\x43\x41\x38\x35\x39\x38\x44\x31\x31\x45\x33\x38\x45\x43\ \x31\x45\x30\x35\x34\x36\x33\x33\x31\x39\x46\x38\x34\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x43\x42\x44\x44\x46\x43\x41\ \x37\x35\x39\x38\x44\x31\x31\x45\x33\x38\x45\x43\x31\x45\x30\x35\ \x34\x36\x33\x33\x31\x39\x46\x38\x34\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x37\x31\x65\x61\x35\x61\x61\x61\ \x2d\x63\x33\x30\x31\x2d\x30\x61\x34\x35\x2d\x62\x36\x30\x35\x2d\ \x38\x64\x36\x65\x63\x37\x33\x34\x65\x37\x62\x66\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\xf7\xcb\ \xb3\xc5\x00\x00\x03\xad\x49\x44\x41\x54\x78\xda\xbc\x97\x69\x48\ \x55\x41\x14\xc7\xef\xd3\xd7\x26\x2d\x96\x18\x25\xb6\x88\x49\x54\ \x52\x7e\x50\xd3\xca\x28\x69\xa7\x3d\xa9\x84\xac\x8c\xa2\x5d\x92\ \x16\x22\x41\xcb\x16\xcb\x82\x20\x89\x8a\x84\x6c\x21\x22\xac\x88\ \x56\xbf\xd8\xf2\x21\xa5\x04\x97\x28\x08\x6c\xd1\x24\x22\x42\x4d\ \xc5\x35\xad\xff\x81\xff\xc4\x74\xbb\xbd\xad\x67\x07\x7e\xcc\xdc\ \x99\x37\x67\xce\xcc\x9c\x39\x73\x9e\x6d\xf7\xe5\x22\x9b\x61\x18\ \x29\x60\x23\x08\x32\x3c\x93\x47\x20\xe1\x78\x52\x6c\xa7\xbb\x03\ \x6d\x30\x60\x2f\xca\x2c\xd0\x0a\xf2\x40\x39\xeb\xae\x88\x1f\x38\ \xcd\xfa\x25\xb0\x16\x46\xfc\x70\xc7\x00\x3b\xd8\x09\x9a\xc0\x54\ \x0c\x2e\x75\x67\x30\x8c\xf7\xa7\x01\x55\x60\x35\xa8\x05\xa9\xee\ \xee\x80\x58\x7c\x0c\x1c\x01\x83\x40\x3d\x77\x60\x88\xe9\xb7\x9f\ \x41\x6f\xe0\xcf\xef\x56\x52\x07\x56\x80\x24\x30\x1f\xa4\x63\x21\ \x07\x5d\x35\xc0\x87\x65\x09\x58\x07\xde\x83\x1d\x20\x86\x75\x9d\ \x18\xf6\xa9\xef\x6b\x9a\x9e\x76\x1a\x21\xbe\x90\x89\x45\x6d\x75\ \xd7\x80\xef\xa0\x18\x1c\x00\x1f\xb8\x4a\xa9\x6f\x07\x33\x59\xf7\ \x67\xdf\x02\xb0\x81\xfe\xf2\x4b\xb0\xea\x66\x14\x8b\xc1\x73\x70\ \x0a\x46\x24\xba\x63\x80\xc1\x15\x66\x80\x0b\xe0\x16\xeb\x33\xb8\ \x3b\x19\x6c\x93\xbe\x1a\x10\x2e\x0e\x67\xf2\x25\x31\xa2\x01\xc5\ \x1c\xf0\x1a\x5c\x84\x11\xf3\xdc\x31\xe0\x09\x1d\x28\x95\xc7\x11\ \x02\xee\x73\xe5\x21\x1a\xa2\x3c\x13\xac\x04\xea\xda\x45\x68\x3b\ \x21\x3e\x11\x0f\xaa\x41\x3e\x8c\x98\xec\x8a\x13\x2e\x01\x23\xc1\ \x49\xb6\x97\x43\x51\x04\xfb\x92\x51\xcf\x73\x70\x13\xc4\xf3\x7d\ \xc1\x24\xfc\xee\x95\xd6\x1e\x8c\xa2\x08\xf4\x07\x71\xe8\xab\x70\ \x66\xc0\x03\xd0\xc7\xe2\x37\xcd\x18\xdc\xee\xc0\x80\x74\xfa\x48\ \x23\xc8\x05\x2f\x81\x8a\x05\xa3\x40\x1a\xf8\x02\x22\xa1\xe7\xa3\ \x55\x1c\x50\x22\xce\xb5\xcd\x62\x8e\xa3\x98\xa4\xaf\xd6\x57\x09\ \x45\xeb\xb5\xfe\x43\xa0\x03\x6c\xe2\x2d\xb1\x59\xe8\x18\x0c\x42\ \x81\x43\x03\x1a\xe8\xe5\x66\xe9\xe2\x04\xaa\xef\x93\xc9\xfb\xbb\ \x18\x49\xb3\x1c\x04\xab\x3a\x57\x9c\x30\x90\xce\x24\xec\xa3\x13\ \x49\x3d\x9b\x5b\x1c\x8a\xc9\xc4\xf3\x23\xa1\xb4\x0c\xe4\x1a\x5e\ \x10\x7d\x07\xe4\x7a\x15\x72\x27\x02\xf8\xfd\x58\xeb\x6f\x61\x59\ \xcc\x88\x59\xe9\x6d\x03\xc6\xca\xbd\xc7\x2a\xc7\x63\x75\x12\xdb\ \x07\xb0\x7d\x0b\xda\xae\x6a\x5b\x9e\x69\x78\x51\x74\x03\x64\x65\ \x6d\xca\xf1\x40\x2f\xd6\xcb\x8c\x6e\x14\xbb\xb6\x32\x79\x09\x4b\ \x59\x3f\x63\xfc\x27\xb1\xbb\xf0\xe4\x46\x32\x59\x09\xf4\x70\x8e\ \x1e\xea\xba\x42\xd7\x57\xd6\xa5\xcc\xc5\x42\x8b\xed\x4e\x26\x9f\ \x8d\xe2\x8e\xa6\xe4\x5f\xc4\x1c\x92\x93\xa1\x7f\xa9\x8f\x93\x41\ \xd9\x5e\x9a\xfc\x6f\x21\xe0\x84\x33\x03\xc6\xb1\xbc\x02\xce\xea\ \xd6\x83\x7b\x60\x3a\x58\xc8\x50\x2e\x0f\x50\x01\x5f\x50\xf9\x96\ \xdd\x7b\xab\x8d\xb9\xc1\xf6\x04\xf0\x46\x85\x6a\x67\x06\xf8\xb2\ \xac\x60\x60\x52\x72\x1b\x84\x31\x01\x09\xe0\x64\x85\xcc\x90\x3a\ \xf9\x74\x17\x30\xfc\x2a\x49\xe1\x42\xe6\x82\xf3\x2e\x3b\x21\xa5\ \x91\xaf\xa5\x92\x26\x2d\x4e\x7c\xd3\x1e\xb1\x76\x06\x28\x79\xd2\ \x83\x99\x6f\x2a\x59\xce\x1c\xa2\x8a\x8f\xd6\x1f\xa1\xd8\x99\x01\ \x3d\x59\xaf\x85\xf7\x76\x68\xb9\x61\x8b\x66\x4c\x33\x03\x9a\x3c\ \x4a\xab\x24\x29\xe1\xa4\x37\xc1\x43\x39\x73\xb0\xc8\x93\x1d\x88\ \xe6\xa0\x7e\x92\xb8\xc0\x7b\xe3\xb5\x40\xd5\xa0\xbd\x80\x52\x1f\ \x0a\x46\xf0\x7b\x0d\xa9\x66\xb2\xfb\x82\x69\x7f\xb4\xab\x06\xc8\ \x2b\x36\x90\xe7\x17\xcb\x6c\x28\x91\x79\xa2\x92\xc3\x4c\xd1\x44\ \x66\x81\x29\x16\x7a\x86\x83\xa7\x4c\x50\x24\xcf\x8c\x63\x7b\x9b\ \x33\x03\xae\x33\x08\x89\x44\x11\xb3\x4c\xd3\xea\xa3\x1d\xe8\x0a\ \x23\xbf\xe9\xf7\x31\x79\xbb\x59\x76\xf1\xfc\xba\x43\xee\xca\x6e\ \xa8\x1d\x08\xe7\x3d\x35\x4c\xc9\x86\x78\xfb\x32\x9c\x79\x10\xb3\ \x1a\x4f\x44\x8e\x24\x87\xa9\x7c\x89\x0a\xc5\xd0\x5d\xa3\x72\xc2\ \x7a\xde\xdd\x28\x34\xbe\xf3\xe6\x12\xa1\xdb\x8f\xf1\x61\x22\x98\ \x60\x95\x98\xca\x0e\x9c\x03\x7b\xe4\x0f\x05\x06\xe4\x30\xa9\xec\ \xf2\xc2\xfc\xc3\xc0\x66\x30\x06\x3c\xa3\x5e\xcb\xd7\x30\x8d\x59\ \xac\x24\x95\xfb\xbd\x7c\xce\x12\x2f\xf2\x99\xd4\x58\xfe\x6b\xfe\ \x29\xc0\x00\x12\x09\x26\xe1\x36\xa9\x6f\xb1\x00\x00\x00\x00\x49\ \x45\x4e\x44\xae\x42\x60\x82\ \x00\x00\x06\xbf\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x42\x43\x39\ \x35\x36\x46\x31\x41\x35\x39\x38\x34\x31\x31\x45\x33\x38\x45\x35\ \x31\x43\x44\x35\x41\x43\x39\x34\x42\x36\x39\x45\x41\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x42\x43\x39\x35\x36\x46\x31\ \x39\x35\x39\x38\x34\x31\x31\x45\x33\x38\x45\x35\x31\x43\x44\x35\ \x41\x43\x39\x34\x42\x36\x39\x45\x41\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x63\x31\x65\x61\x38\x31\x32\x35\ \x2d\x65\x62\x64\x64\x2d\x63\x38\x34\x62\x2d\x39\x66\x37\x61\x2d\ \x30\x36\x39\x39\x32\x39\x38\x64\x62\x39\x33\x63\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\x5a\x6c\ \x96\x67\x00\x00\x02\xe4\x49\x44\x41\x54\x78\xda\xc4\x57\xbd\x6b\ \x14\x41\x14\xdf\xdd\x9c\x88\xa0\xb1\xb1\x12\xab\xa0\x9c\x26\xa8\ \x8d\x70\x82\xf8\x41\x8a\xa0\x8d\x45\xf0\x0f\x30\x9c\x28\x24\x70\ \x20\x39\xa3\x85\xa4\x38\xd3\xa8\x88\x72\x45\x2a\xb5\x4e\x95\x42\ \x2d\xd6\x14\x21\x0a\x16\x57\x08\x7e\x25\xb9\xcb\xa9\x58\x04\x0b\ \x89\x85\xa7\x9d\x90\xf3\xf7\xe0\xb7\x30\x8c\xfb\x76\x76\x97\x9c\ \x3e\xf8\x31\xc3\xbc\x79\x1f\xf3\xe6\xcd\x9b\x19\xdf\xcb\x41\x95\ \x4a\xa5\x8a\x66\x1a\xd8\xc5\xa1\x0e\x50\xab\xd7\xeb\xf7\xb2\xea\ \xf2\x73\x18\xdf\x8b\x66\x3d\x46\xb6\x0b\xec\x83\x13\x5f\xb3\xe8\ \x0b\x72\x04\xe0\x80\xe2\xb8\x4f\x5e\x26\x2a\x28\xab\x1c\x43\x33\ \x0e\x6c\x00\x55\xac\x6a\x39\x65\xd4\x7c\x4b\xcf\x29\xd9\x1a\xda\ \x99\x81\x9e\xd0\x19\x01\x08\xdd\x40\xf3\x18\x38\x06\x9c\x05\x96\ \x30\x76\x98\x3c\x31\x30\x90\xe0\xc0\x00\xe7\xc8\xdc\x61\x34\x62\ \xf0\x34\x70\x02\x78\x82\xb1\xf3\x2e\x8f\xc7\x68\xdc\x26\x89\xc4\ \x5d\xe0\x52\x8a\x30\x7f\x04\xe6\x80\x49\x60\x87\xc5\xfb\x2d\x8b\ \x42\x24\x16\xb5\x08\x8c\x2b\x4a\xf7\x00\xb7\x53\xee\xf1\x7e\xe0\ \x66\x8c\x71\xa1\x6d\xc0\x95\xa4\x2d\xd8\xf0\x7a\x4f\xdf\x93\x1c\ \xa8\xf6\xd8\x89\x4f\xc0\xad\xc4\x3a\xc0\x84\x5b\x64\xd8\x93\xa8\ \x05\xac\xb2\x7f\x08\x28\xa6\x30\x7e\x06\xfb\xbf\xee\x2c\x44\x70\ \x62\x8a\x7b\x1e\x47\xcf\x81\x29\x28\x7a\x67\xc9\x1c\x61\xa2\x8e\ \x28\x72\x13\x90\x99\x75\x56\x42\x1e\xa3\x96\x92\x70\xf7\x25\xbb\ \xa1\xa8\xab\x38\x2e\xb2\x52\x8e\xaf\xc6\xb0\xd7\x80\x83\xb6\xac\ \x6f\x94\xd7\xa8\xc2\xc9\x39\x7f\xa4\xac\xfc\x5c\xa4\x00\x32\x92\ \x3f\x83\xe4\xad\x60\x7c\xd3\x70\x22\x54\x22\x51\x06\x3e\xb3\x6c\ \xb7\xa5\x6c\xfb\x10\x98\x64\xe8\x5c\xf7\xc2\xd1\x28\xec\x90\x91\ \x3d\x9f\x97\x15\x91\xd7\x04\x46\xc1\x5f\x35\xb6\xe3\xad\x43\x9f\ \x38\x71\x2d\xe0\xad\xe6\x32\xde\x32\x8c\x07\x96\x71\x8f\xfd\x79\ \xf2\x3c\xce\x6d\xa5\xb8\x08\xa7\x45\xa0\x3f\xc5\xf1\x69\x1a\xfd\ \x21\xcb\xb8\xe9\xc4\xa0\x22\xa3\x51\x7f\xe0\xfd\x67\x0a\xf8\x98\ \x70\x91\xb9\xe2\x65\x65\x75\x32\xb6\xa2\xc8\x68\xd4\x09\x78\x5d\ \x76\x1d\x13\x8b\x4c\x2c\x8f\xd9\x3e\x6a\x39\x11\x25\xe1\xa6\x91\ \x84\xc5\x14\x49\x58\xcb\x72\x0c\x17\x78\x93\x99\xc7\x70\x28\x8a\ \x4a\xee\x63\xa8\x14\x93\x35\xde\x6a\x5b\x59\x88\xda\x12\x15\x5b\ \xf6\xaf\x24\xe4\x84\x39\x25\x6c\xa2\x38\x8c\xb6\x23\xa6\x14\x87\ \x8a\x71\xa1\x87\x71\x8e\xc7\x45\x40\x5e\x32\xcf\x94\xfb\xdc\xbe\ \x8c\x9a\x46\xc2\xb9\xf6\x5c\x6e\xd9\x61\x38\xf1\xde\xf5\x86\x0b\ \x53\x18\xcf\x4b\xe2\xc4\x49\x38\xd1\xd4\xb6\xa0\xd6\x43\xe3\xd1\ \xcb\xea\x7a\x52\x0e\x14\xfe\x41\xed\x29\x24\x39\x30\xc3\x87\x63\ \xdc\x63\x62\x82\xa7\xc3\x45\x6d\xae\x32\xee\x65\xd5\xe1\x29\x89\ \x77\x80\xef\xf6\x0b\x96\x13\xd1\x4b\x66\x96\xc9\x56\x4e\x30\x5e\ \xe6\x51\xbb\x23\x09\x67\x39\x21\xc6\x47\xc0\x7b\x63\x0a\xf4\xd9\ \x1a\x1a\x8d\x46\xab\x54\x2a\xbd\x62\x2e\xbc\x04\x2e\x46\xdf\x2d\ \xf0\x3c\xf0\x76\xcb\x98\xe2\xc0\x03\xcc\xfd\xc2\xb9\xdf\x30\xf7\ \x29\xba\x3b\x81\x0f\xc0\x65\xf0\x5e\x6f\xc5\xdf\x50\x3e\x1a\x4b\ \x0a\x5b\x22\xf5\xa2\xd7\x7f\xc3\xb6\x72\x77\x74\xc9\xcb\x44\x7d\ \x59\x05\x10\xda\x9f\x08\xed\x2f\x74\x8f\x03\xdb\x39\xfc\x43\x3e\ \x23\x58\xfd\x42\x56\x7d\x7f\x04\x18\x00\xe5\xb8\x12\x0b\xa0\x46\ \x15\xe4\x00\x00\x00\x00\x49\x45\x4e\x44\xae\x42\x60\x82\ \x00\x00\x05\xa0\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x31\x45\x45\ \x31\x42\x33\x30\x45\x35\x39\x38\x35\x31\x31\x45\x33\x38\x46\x34\ \x31\x43\x38\x46\x38\x31\x43\x33\x30\x33\x39\x39\x45\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x31\x45\x45\x31\x42\x33\x30\ \x44\x35\x39\x38\x35\x31\x31\x45\x33\x38\x46\x34\x31\x43\x38\x46\ \x38\x31\x43\x33\x30\x33\x39\x39\x45\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x63\x31\x65\x61\x38\x31\x32\x35\ \x2d\x65\x62\x64\x64\x2d\x63\x38\x34\x62\x2d\x39\x66\x37\x61\x2d\ \x30\x36\x39\x39\x32\x39\x38\x64\x62\x39\x33\x63\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\x68\x12\ \x49\xb3\x00\x00\x01\xc5\x49\x44\x41\x54\x78\xda\x62\xfc\xff\xff\ \x3f\x03\x23\x23\x23\x03\x3e\x90\x97\x97\x37\x01\x48\xe5\x33\x90\ \x06\x26\x4e\x9a\x34\xa9\x00\x9f\x02\x90\xdd\x4c\x0c\x03\x0c\x58\ \x88\x54\x77\x0a\x88\x17\x92\x68\xf6\x29\x6a\x3a\x60\x07\x10\x1f\ \x23\xd1\x01\x9f\xa8\xe9\x80\x3a\x72\xd2\x00\x10\x17\x10\x52\x34\ \xe0\x69\x60\xc8\x24\xc2\x26\x20\x9e\x30\x90\x69\x20\x10\x88\x7d\ \x49\x74\xc0\x66\x20\x9e\x4b\x2d\x07\xe8\x02\xb1\x3f\x89\x0e\x78\ \x30\x24\xd2\xc0\xa8\x03\x58\xa0\x95\x4d\x22\x90\x92\xc7\xa3\xce\ \x82\x0c\xb3\x2d\x80\xe6\x36\xe0\x91\x7f\x08\xc4\xf3\x61\x89\x70\ \x1b\x10\xaf\x07\x62\x4b\x2a\x7a\xce\x1c\x8a\xb1\x81\xe3\xd0\x9c\ \x05\x89\x02\x60\xb5\xf9\x12\x48\x39\x92\x51\xe1\x90\x03\x40\x76\ \x38\x42\xed\x64\x60\x44\x6f\x0f\x00\x83\xad\x0c\x48\xb5\xd3\x20\ \x7d\xfc\x03\xe2\x4a\xa0\xc5\x5d\xc8\xed\x01\x46\x6c\x0d\x12\xa0\ \x23\xbc\x81\xd4\x72\x20\xe6\xa5\x92\xe5\x9f\x81\x38\x12\x68\xf9\ \x56\xf4\x06\x09\x23\xae\x16\x11\xd0\x11\xda\x40\x6a\x13\x10\x2b\ \x51\x68\xf9\x3d\x20\xf6\x03\x5a\x7e\x95\xa4\x16\x11\x54\x83\x19\ \x10\x1f\xa4\xc0\x72\x90\x5e\x33\x6c\x96\x13\x55\x0e\x00\x35\xbe\ \x05\x52\xae\x40\x3c\x93\x0c\xcb\x41\x7a\x5c\xa1\x66\xe0\x04\x8c\ \xc4\x34\x4a\xa1\x51\x92\x0b\xa4\xfa\x81\x98\x99\x80\xd2\xbf\x40\ \x5c\x08\xb4\x78\x32\x21\x33\xf1\xa6\x01\x1c\x8e\x70\x01\x52\xab\ \x81\x58\x00\x87\x92\x0f\x40\x1c\x0a\xb4\x7c\x0f\x31\xe6\x91\xec\ \x00\xa8\x23\xd4\xa0\x89\x53\x1d\x4d\xea\x26\x34\xb1\xdd\x22\xd6\ \x2c\xb2\x9a\xe5\x50\x0b\x40\x45\xf3\x2e\x24\xe1\xdd\x20\x31\x52\ \x2c\x27\x39\x0d\x60\x09\x09\x50\x5a\xe8\x85\x72\x8b\x81\x96\xff\ \x25\xd5\x0c\x78\x14\xe4\xe7\xe7\x83\x42\x42\x13\x88\x59\xe9\x54\ \x09\xfe\x06\xe2\x1b\x13\x27\x4e\xfc\x0b\xab\x8c\xd6\x91\xd1\xe2\ \xa1\x14\x6c\x07\x62\x2f\x58\x1a\xf0\x1b\x80\xa6\x80\x27\x72\x41\ \xc4\xc8\x30\x40\x00\xe6\x80\x3f\x03\x60\xf7\x3f\x64\x07\x4c\x81\ \x09\xd0\xd1\xf2\xa9\x20\x06\x40\x80\x01\x00\xc6\x51\x9f\x7a\x83\ \x78\x67\xeb\x00\x00\x00\x00\x49\x45\x4e\x44\xae\x42\x60\x82\ \x00\x00\x06\xbd\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x41\x41\x42\ \x31\x33\x44\x37\x30\x35\x39\x38\x34\x31\x31\x45\x33\x41\x44\x39\ \x31\x44\x46\x46\x41\x36\x32\x34\x34\x38\x41\x34\x46\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x41\x41\x42\x31\x33\x44\x36\ \x46\x35\x39\x38\x34\x31\x31\x45\x33\x41\x44\x39\x31\x44\x46\x46\ \x41\x36\x32\x34\x34\x38\x41\x34\x46\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x63\x31\x65\x61\x38\x31\x32\x35\ \x2d\x65\x62\x64\x64\x2d\x63\x38\x34\x62\x2d\x39\x66\x37\x61\x2d\ \x30\x36\x39\x39\x32\x39\x38\x64\x62\x39\x33\x63\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\x74\x3f\ \x67\x43\x00\x00\x02\xe2\x49\x44\x41\x54\x78\xda\xbc\x97\x5d\x88\ \xcc\x51\x14\xc0\x67\xd6\x60\xdb\x98\x15\xa5\x79\xf0\x15\x4b\x48\ \xbe\x8a\x44\xc8\xee\x4a\x11\xf2\x64\x1f\x58\x91\x42\x69\xac\xf2\ \x91\xb2\xa5\x15\x25\xe5\x61\x3c\xd9\x97\x8d\x37\x1e\xb0\x51\xe4\ \xa3\x59\xad\x94\x07\xab\xb4\xb2\x59\xb2\x25\xd2\x96\xb0\xd8\xf5\ \xd1\x18\xbf\x53\x67\x74\xfb\x37\xf7\xce\xfd\x9b\x7f\x7b\xea\xd7\ \xbd\x73\x3f\xfe\xf7\x9c\x73\xcf\x3d\xf7\x4e\x3c\x16\xa1\xa4\xd3\ \xe9\x75\x14\x19\x98\x05\xcf\x61\x5f\x26\x93\xe9\xb4\x8d\xcf\xe7\ \xf3\xb1\x78\x84\x8b\x4f\xa3\xe8\x81\xd1\x46\xf3\x57\xa8\x41\x89\ \x7e\x9b\x02\x15\x11\x3a\x60\x7d\x60\x71\x91\xb1\x50\xe7\x9a\x14\ \xa5\x02\xdf\x2d\xed\x83\xae\x49\x89\x08\x5c\x5f\x25\x6e\x86\x6b\ \x70\x12\x26\x1b\xdd\xb2\x25\xb7\x23\x55\x80\x05\x47\x50\x2c\x55\ \xd7\xd6\xc3\x72\x18\x09\xbd\xd0\x0e\x93\x60\x1c\x3c\x83\x53\xec\ \xff\xcf\xb2\x15\x60\x51\x09\xd6\x46\xd8\x02\x6b\x20\x59\x64\xd8\ \x4c\xe5\x0f\xdc\x82\x07\xf0\xb1\xd4\xb7\x7d\x3d\xb0\x1b\x5a\x3d\ \xc7\x4a\x5c\x6d\x50\x36\xc1\x8d\xb2\x82\x10\xeb\x47\x51\x34\x07\ \x9a\xdf\xc0\x7b\x0f\x65\xea\xa3\xf0\xc0\x4e\x23\xb0\xde\xc2\x2a\ \xf8\x0c\x7d\x1e\x73\xd7\x16\x09\xd8\xd5\x30\x1b\xae\x8b\x21\x89\ \x12\xd6\x4b\xff\x61\xa3\xe9\x34\x41\xd5\x47\xbb\x78\xa4\xda\x96\ \xe0\x20\xa7\xc6\xcd\x61\xac\x6c\xc3\x02\x0d\xda\x42\xc0\x8a\x34\ \xc1\xd4\x52\x1e\xd8\x06\x33\xb4\xfe\x01\xda\xf8\xe0\x18\xca\x03\ \x8e\x39\x57\xf4\x24\xac\xd0\xdf\xed\x96\x71\x55\xce\x18\x50\xeb\ \x8f\x1b\x4d\x67\xf4\x48\xed\x87\x09\x0e\xeb\x5b\xe0\x9e\x43\xc1\ \x77\x70\x51\x33\xa7\xfd\x2e\x40\x81\x46\x1d\x58\xb0\x7e\xba\xd6\ \x65\xef\x27\x5a\xa6\x5d\x46\xc9\x06\xe6\xca\x71\xec\x02\xf1\xd6\ \x00\x64\x55\xa9\xfb\xf4\xbf\x30\xef\x02\xd7\x16\xec\x30\xea\xe7\ \x98\x38\xc4\x87\x9b\x1c\x8b\x17\xac\x8f\x31\xb6\x97\xb1\x53\xa8\ \xa6\xe0\x25\xbf\x73\xb6\x45\x5c\x1e\x38\x4b\x71\x08\x5e\xc3\x42\ \xf8\xad\xd6\xa7\x2c\x53\x9e\xc2\x32\x16\xfb\xe5\x9b\x55\x4b\xdd\ \x86\x47\x60\x2e\xcc\xe7\xa3\xdf\xf4\x38\xa6\x1c\xe3\x17\x41\xb7\ \x46\xbd\xb7\xc4\x3d\x53\xb1\x24\xa3\x57\x81\x8b\xc6\x25\xb2\xdf\ \x07\x51\xbc\xbb\x1c\x0f\x98\xb2\x3d\xc4\xe2\x85\x0c\xd8\x85\xe2\ \x4b\x7c\xf2\x76\xcc\x23\x19\x1d\x2b\xd2\xb5\x07\x2e\x68\xd2\x29\ \x26\x92\x70\x76\x95\xad\x40\x20\x19\x15\xe4\x31\xee\x6d\x85\xbd\ \xd4\xe7\xc1\x4d\xcb\xdc\xea\xb2\x14\xc0\xfa\x0a\x0d\xc6\xa0\x9c\ \x28\x54\x50\xa2\x07\x36\xea\x35\xfd\xa4\x58\xb6\x0b\x15\x84\x2c\ \x3a\x9e\xa2\xd6\x78\x70\xd4\x04\x86\x3c\x64\xc1\x95\x16\x85\xe5\ \x21\xf2\xc9\x68\xca\x32\xb6\xd6\x15\x84\x09\xb5\xb2\x4e\x6f\xae\ \x3a\x3d\x4e\xae\xd3\xd1\xec\xe8\x0b\xbe\xff\x2a\x7d\xb6\xe0\x12\ \xdc\xd1\x5b\x6f\x71\x89\xc5\xcf\x63\x51\x87\xad\x53\x93\x50\x3e\ \xcc\x16\x48\x84\x37\x38\xfa\xe5\x83\x8f\xf4\x5c\x5f\x35\xf3\xb8\ \x43\x06\x8c\xe0\x4b\xfa\x28\x90\x0d\xbc\x5c\xe4\x31\x79\x57\xe9\ \x64\xd1\xc1\x90\xef\xd6\x21\x43\x81\x4a\x1f\x05\x36\xc3\x56\x7d\ \xd7\x77\xd8\xfe\xc5\x84\x90\x1f\xa1\xb6\x40\x2d\x6c\x8b\xf0\x0f\ \xca\x17\xa3\x9e\x8c\x22\x11\xc5\xfe\x63\x0b\xfe\x1d\x73\xbd\x47\ \x86\x55\x81\xfe\xc0\x76\xe4\x86\x5b\x81\x16\x7d\x37\x88\x27\x8e\ \xba\x1e\x23\x22\x7f\x05\x18\x00\x68\x1f\xde\x97\xa8\x2b\x9f\x11\ \x00\x00\x00\x00\x49\x45\x4e\x44\xae\x42\x60\x82\ \x00\x00\x06\xbd\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x39\x46\x38\ \x32\x32\x30\x43\x30\x35\x39\x38\x34\x31\x31\x45\x33\x42\x35\x45\ \x42\x44\x32\x39\x33\x41\x33\x42\x36\x34\x41\x32\x38\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x39\x46\x38\x32\x32\x30\x42\ \x46\x35\x39\x38\x34\x31\x31\x45\x33\x42\x35\x45\x42\x44\x32\x39\ \x33\x41\x33\x42\x36\x34\x41\x32\x38\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x63\x31\x65\x61\x38\x31\x32\x35\ \x2d\x65\x62\x64\x64\x2d\x63\x38\x34\x62\x2d\x39\x66\x37\x61\x2d\ \x30\x36\x39\x39\x32\x39\x38\x64\x62\x39\x33\x63\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\x7d\x29\ \xa2\x1a\x00\x00\x02\xe2\x49\x44\x41\x54\x78\xda\xbc\x97\x5d\x88\ \xcc\x51\x14\xc0\x67\xd6\x60\xdb\x98\x15\xa5\x79\xf0\xb1\xb1\x84\ \xe4\xab\x48\x84\xec\xac\x14\x21\x4f\xf6\x81\x15\x6d\xa1\x94\x55\ \x8b\x94\x2d\xad\x28\x91\x07\x9e\x6c\x6a\xe3\x8d\x07\x6c\x14\xf9\ \x68\x6c\x2b\xe5\xc1\x2a\xad\x6c\x96\x6c\x89\xb4\x25\x2c\x76\x7d\ \x34\xc6\xef\xd4\xf9\xeb\xf6\x6f\xee\x9d\x3b\xe6\xdf\x9e\xfa\x75\ \xef\xdc\x8f\xff\x3d\xe7\xdc\x73\xcf\xbd\x13\x8f\x45\x28\x7d\x4d\ \x0d\x6b\x29\xce\xc2\x4c\x78\x0e\x7b\xaa\x4e\x5f\xe8\xb4\x8d\xcf\ \xe5\x72\xb1\x78\x84\x8b\x57\x51\xf4\xc0\x68\xa3\xf9\x2b\x54\xa3\ \x44\xbf\x4d\x81\xb2\x08\x1d\xb0\x2e\xb4\xb8\xc8\x58\x48\xbb\x26\ \x45\xa9\xc0\x77\x4b\xfb\xa0\x6b\x52\x22\x02\xd7\x57\x88\x9b\xe1\ \x1a\x1c\x83\xc9\x46\xb7\x6c\xc9\xed\x48\x15\x60\xc1\x11\x14\x4b\ \xd4\xb5\xb5\xb0\x0c\x46\x42\x2f\xb4\xc3\x24\x18\x07\xcf\xe0\x38\ \xfb\xff\xb3\x64\x05\x58\x54\x82\xb5\x1e\x36\xc3\x6a\x48\xe6\x19\ \x36\x43\xf9\x03\xb7\xa0\x03\x3e\x16\xfa\xb6\xaf\x07\x1a\xa0\xd5\ \x73\xac\xc4\xd5\x7a\x65\x23\xdc\x28\x29\x08\xb1\x7e\x14\x45\x73\ \xa8\xf9\x0d\xbc\xf7\x50\xa6\x36\x0a\x0f\xec\x30\x02\xeb\x2d\xac\ \x84\xcf\xa2\x9b\xc7\xdc\x35\x79\x02\x76\x15\xcc\x82\xeb\x62\x48\ \xa2\x80\xf5\xd2\x7f\xc0\x68\x3a\x41\x50\xf5\xd1\x2e\x1e\xa9\xb4\ \x25\x38\xc8\xaa\x71\xb3\x19\x2b\xdb\x30\x5f\x83\x36\x08\x58\x91\ \x46\x98\x5a\xc8\x03\x5b\x61\xba\xd6\x3f\x40\x1b\x1f\x1c\x43\xb9\ \xcf\x31\xe7\x8a\x9e\x84\xe5\xfa\xbb\xdd\x32\xae\xc2\x19\x03\x6a\ \xfd\x11\xa3\xe9\xa4\x1e\xa9\xbd\x30\xc1\x61\x7d\x0b\xdc\x73\x28\ \xf8\x0e\x2e\x6a\xe6\xb4\xdf\x05\x28\x50\xaf\x03\x03\xeb\xa7\x05\ \x5d\x30\xd1\x32\xed\x32\x4a\xd6\x31\x57\x8e\x63\x17\x88\xb7\x06\ \x20\xa3\x4a\xdd\xa7\xff\x85\x79\x17\xb8\xb6\x60\xbb\x51\x3f\xc3\ \xc4\x21\x3e\xdc\xe8\x58\x3c\xb0\x3e\xc6\xd8\x5e\xc6\x4e\xa1\x9a\ \x82\x97\xfc\xce\xda\x16\x71\x79\xe0\x14\x45\x13\xbc\x86\x05\xf0\ \x5b\xad\x4f\x59\xa6\x3c\x85\xa5\x2c\xf6\xcb\x37\xab\x16\xba\x0d\ \x0f\xc2\x1c\x98\xc7\x47\xbf\xe9\x71\x4c\x39\xc6\x2f\x84\x6e\x8d\ \x7a\x6f\x89\x7b\xa6\x62\x49\x46\xaf\x42\x17\x8d\x4b\x64\xbf\xf7\ \xa3\x78\x77\x29\x1e\x30\x65\x5b\x11\x8b\x07\x19\xb0\x0b\xc5\x17\ \xfb\xe4\xed\x98\x47\x32\x3a\x9c\xa7\x6b\x17\x9c\xd7\xa4\x93\x4f\ \x24\xe1\xec\x2c\x59\x81\x50\x32\x0a\xe4\x31\xee\x6d\x85\xdd\xd4\ \xe7\xc2\x4d\xcb\xdc\xca\x92\x14\xc0\xfa\x32\x0d\xc6\xb0\x1c\x0d\ \x2a\x28\xd1\x03\x1b\xf4\x9a\x7e\x92\x2f\xdb\x15\x15\x84\x2c\x3a\ \x9e\xa2\xc6\x78\x70\x54\x87\x86\x3c\x64\xc1\x15\x16\x85\xe5\x21\ \xf2\xc9\x68\xca\x30\xb6\xc6\x15\x84\x09\xb5\x32\xad\x37\x57\x5a\ \x8f\x93\xeb\x74\x34\x3b\xfa\xc2\xef\xbf\x72\x9f\x2d\xb8\x04\x77\ \xf4\xd6\x5b\x54\x60\xf1\x73\x58\xf4\xc0\xd6\xa9\x49\x28\x57\xcc\ \x16\x48\x84\xd7\x39\xfa\xe5\x83\x8f\xf4\x5c\x5f\x35\xf3\xb8\x43\ \x06\x8c\xe0\x4b\xfa\x28\x90\x09\xbd\x5c\xe4\x31\x79\x57\xe9\x64\ \xd1\xc1\x22\xdf\xad\x43\x86\x02\xe5\x3e\x0a\x6c\x82\x2d\x20\xe9\ \xb6\xc3\xf6\x2f\xa6\x08\xf9\x51\xd4\x16\xa8\x85\x6d\x11\xfe\x41\ \xf9\x62\xd4\x93\x51\x24\xa2\xd8\x7f\x6c\xc1\xbf\x63\xae\xf7\xc8\ \xb0\x2a\xd0\x1f\xda\x8e\xec\x70\x2b\xd0\xa2\xef\x06\xf1\xc4\x21\ \xd7\x63\x44\xe4\xaf\x00\x03\x00\x67\x30\xde\x97\xf5\x5f\xa5\xbd\ \x00\x00\x00\x00\x49\x45\x4e\x44\xae\x42\x60\x82\ \x00\x00\x07\x85\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x45\x45\x35\ \x37\x44\x41\x37\x43\x35\x39\x38\x34\x31\x31\x45\x33\x39\x44\x32\ \x38\x41\x32\x46\x31\x34\x37\x35\x33\x41\x36\x39\x46\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x45\x45\x35\x37\x44\x41\x37\ \x42\x35\x39\x38\x34\x31\x31\x45\x33\x39\x44\x32\x38\x41\x32\x46\ \x31\x34\x37\x35\x33\x41\x36\x39\x46\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x63\x31\x65\x61\x38\x31\x32\x35\ \x2d\x65\x62\x64\x64\x2d\x63\x38\x34\x62\x2d\x39\x66\x37\x61\x2d\ \x30\x36\x39\x39\x32\x39\x38\x64\x62\x39\x33\x63\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\x33\xcd\ \x50\xb2\x00\x00\x03\xaa\x49\x44\x41\x54\x78\xda\xbc\x97\x79\x48\ \x55\x41\x14\xc6\xef\xb3\x97\x95\x59\xbd\x0a\x23\xa4\xc0\x25\xa2\ \x3d\x21\x25\x69\x83\xc8\x32\x5b\xa0\x7d\xfb\xa3\x32\x5a\x6c\x7b\ \x24\x45\x44\x86\x96\x45\x96\x08\x91\x11\x51\x08\x69\x54\x58\x58\ \xfd\x51\x54\x44\xb6\x40\x94\x94\xa4\x66\x46\x84\x6d\x26\x11\x91\ \xf9\xd0\x32\xb5\xb4\xbe\x13\xdf\x95\xe1\x72\xdf\x72\x5f\xcf\x0e\ \xfc\x98\xb9\x33\xf7\xce\x7c\x33\xef\xcc\x99\xf3\x6c\x4e\xa7\xd3\ \xa6\x69\x9a\x13\x6c\x00\xe1\x9a\x7f\x76\x17\x2c\xca\xcd\xcd\x6d\ \xb3\xfa\xa1\x0d\x02\x76\xa1\xcc\x02\xcd\x20\x1f\x54\xb0\xee\x8b\ \x85\x80\xe3\xac\x17\x80\x64\x88\xf8\x6d\x45\x80\x1d\x6c\x07\xdf\ \xc0\x14\x7c\x5c\x66\xe5\x63\x88\x77\x50\xc0\x7b\xb0\x0a\xd4\x83\ \x54\xab\x3b\x20\x8a\x0f\x83\x83\xa0\x1f\x70\x71\x07\x06\x1a\xde\ \xfd\x04\xba\x03\x07\x9f\x9b\x89\x4c\xba\x14\xac\x04\xb3\x41\x3a\ \x16\xb2\xdf\x57\x01\x41\x2c\x4b\xc1\x1a\xf0\x16\x6c\x03\xf1\xac\ \xab\xc4\xb3\x4f\x7f\x2e\x54\xc6\x69\x05\x4b\xe8\x0b\x99\x58\xd4\ \x66\xab\x02\x7e\x81\x12\xb0\x0f\xbc\xe3\x2a\xa5\xbe\x15\x4c\x67\ \xdd\xc1\xbe\xb9\x60\x1d\xfd\xa5\xc3\xb0\xea\x26\x14\xf3\xc0\x63\ \x79\x84\x88\xe5\x56\x04\x68\x5c\x61\x06\x38\x0d\xae\xb0\x9e\xc0\ \xdd\xc9\x60\x9b\xf4\xd5\x82\x51\x60\xb5\xc1\x97\x44\x44\x03\x8a\ \x99\xe0\x85\x38\x25\x44\xcc\xb2\x22\xe0\x3e\x1d\x28\x95\x3f\x47\ \x24\xb8\xce\x95\x47\x2a\xc8\xe0\x99\x60\x19\xd0\x8f\x5d\x8c\xb2\ \x13\xe2\x13\xd3\x40\x0d\x28\x82\x88\x89\xbe\x38\xe1\x7c\x10\x01\ \x8e\xb0\xbd\x02\x03\xc5\xb0\x4f\x8e\x56\xbe\x87\x93\x50\xc7\x1d\ \x98\x80\xf7\xaa\x94\xf6\x41\x28\x1e\x81\xde\x60\x32\xfa\x9e\x79\ \x13\x70\x03\xf4\x30\x79\xa7\x09\x1f\xb7\x7a\x10\x90\x4e\x1f\x69\ \x04\x79\xa0\x12\xe8\xb1\x60\x08\x48\x03\x9f\x41\x2c\xc6\xf9\x60\ \x16\x07\x74\x13\xe7\xda\x62\x32\xc7\x21\x4c\x12\xaa\xf4\x55\x63\ \xa0\xb5\x4a\xff\x01\xf0\x13\xa4\xf0\x94\xd8\x4c\xc6\x18\x00\xa2\ \x81\x47\x01\x0d\xf4\x72\xa3\xb5\x73\x02\xbd\xef\xa3\xc1\xfb\xdb\ \x19\x49\xb3\x3c\x04\xab\x7a\x5f\x9c\x30\x8c\xce\x24\xec\xa6\x13\ \x49\x3d\x9b\x5b\x1c\x8d\xc9\xc4\xf3\x63\x31\x68\x39\xc8\xd3\x02\ \x60\xea\x0e\xc8\xf1\xba\xc3\x9d\xe8\xcf\xe7\x7b\x4a\xff\x0f\x96\ \x25\x8c\x98\xd5\x81\x16\x30\x42\xce\x3d\x56\x39\x06\xab\x93\xd8\ \xde\x87\xed\x9b\xd0\x76\x5e\xd9\xf2\x4c\x2d\x80\xa6\x0a\x90\x95\ \xb5\xe8\x8e\x07\xba\xb1\x5e\xae\x75\xa2\xd9\x95\x95\xc9\x4d\x58\ \xc6\xfa\x09\xed\x3f\x99\xdd\x87\x2b\x37\x96\xc9\x4a\x98\x9f\x73\ \x74\xd5\x8f\x2b\xc6\xfa\xc2\xba\x94\x79\x58\x68\x89\xdd\xcb\xe4\ \x89\x28\xae\x2a\x83\xfc\x8b\x19\x43\x72\x32\xc6\x5f\x10\xe4\xe5\ \xa3\xec\x00\x4d\xee\x2e\x04\xe4\x78\x13\x30\xd2\xa4\x4d\x76\x24\ \x09\x3c\xe7\xf3\x6b\x20\xb7\x5e\x31\x9f\x9f\x32\x3a\x36\x32\x4b\ \x4a\x60\x88\xae\x30\xdc\xa0\x7f\x43\xb5\x37\x01\x5d\x0c\xcf\x12\ \xe3\x25\xf6\x8f\x05\x67\xd9\xf6\x15\x54\x31\x14\xb7\x30\xdc\xbe\ \x02\x37\xc1\x4b\x70\x9b\x42\x5c\xbc\x9c\xdc\x46\x42\x5f\xac\x90\ \xce\x28\xd7\xed\x39\x0a\x92\x44\x24\x0e\x4c\x65\x38\x6e\xe2\x0d\ \x38\x07\x04\x83\xbd\xfc\x19\xbf\x33\x89\xf5\x5b\x40\x1b\x13\x93\ \x71\xe0\x21\x6f\xce\x62\x46\xce\x5e\xf4\x97\x02\xfe\x34\xa1\xec\ \xbf\xc5\xf8\x92\x43\x61\x3d\x2d\x1f\x43\xc5\x4e\x81\x61\xca\xa5\ \x23\x93\x9e\x01\x89\x5c\xa9\x83\x22\x56\x80\x3d\x4c\x66\x5c\xec\ \xab\x63\xf8\x0e\xb6\x2a\xc0\xa5\x64\xc1\xa3\x99\xf5\x76\x1c\x23\ \xf0\x04\x0c\xa5\x4f\x88\x2d\xe6\xea\xa3\x18\x49\x1f\x80\xf5\x4c\ \xd3\x6a\x98\xca\xa9\xd6\xe2\x4d\xc0\x05\x06\x21\xb1\x49\x86\xbe\ \xbe\x60\x86\xc9\x37\x49\x4a\x3d\x42\xa9\x47\x11\xd5\x2e\x06\xb9\ \xf1\x76\xdd\x76\x80\xcb\x9d\x14\x07\xae\x49\xd6\xad\xef\x80\x6c\ \xcd\x25\xe3\x1b\x08\x95\xf2\x8f\x69\x21\x22\x56\x38\xb3\x1a\x7f\ \x4c\x76\xee\x18\x53\xf9\x52\x3d\x14\x63\xec\x5a\x3d\x27\x74\xd1\ \xc3\xe3\xd0\xf8\x26\x90\x4b\xc4\xd8\x21\xcc\x31\xc6\x8b\x9f\x98\ \x25\xa6\xb2\x03\x27\xc1\x4e\x51\x87\x0f\x8e\x32\xa9\x6c\x0f\xc0\ \xfc\x83\xc1\x46\x30\x9c\xc7\xb6\xd2\xdd\x6d\x98\xc6\x80\x92\xc2\ \xa0\x11\x48\x93\x5c\xb2\x88\x49\x8d\xe9\xbf\xe6\x3f\x02\x0c\x00\ \x19\xca\x22\x70\x0c\xa6\x9f\x87\x00\x00\x00\x00\x49\x45\x4e\x44\ \xae\x42\x60\x82\ \x00\x00\x06\xbb\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x37\x34\x35\ \x38\x33\x43\x33\x39\x35\x39\x38\x35\x31\x31\x45\x33\x41\x31\x43\ \x32\x46\x42\x37\x41\x42\x30\x37\x44\x42\x42\x38\x37\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x37\x34\x35\x38\x33\x43\x33\ \x38\x35\x39\x38\x35\x31\x31\x45\x33\x41\x31\x43\x32\x46\x42\x37\ \x41\x42\x30\x37\x44\x42\x42\x38\x37\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x63\x31\x65\x61\x38\x31\x32\x35\ \x2d\x65\x62\x64\x64\x2d\x63\x38\x34\x62\x2d\x39\x66\x37\x61\x2d\ \x30\x36\x39\x39\x32\x39\x38\x64\x62\x39\x33\x63\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\x83\x53\ \x5b\xa8\x00\x00\x02\xe0\x49\x44\x41\x54\x78\xda\xc4\x97\x5d\x88\ \x4d\x51\x14\x80\xcf\x3d\xf7\xc6\x0c\xe6\x87\x51\x1a\x43\x8d\x14\ \xae\x19\x3f\xe3\xa7\x1b\xde\x66\x42\x89\x32\xf2\xa0\x79\x98\x97\ \x21\x0f\xc6\x95\xbc\x88\x46\x24\xc9\x4f\xe8\x26\x2f\x46\x29\x49\ \x1e\x64\x3c\x90\x78\xf0\xf3\xc2\x2d\xa1\xe6\x0e\x93\x22\xf2\x73\ \xf3\x30\x4d\x83\x49\x46\x5c\xdf\xd2\xbe\x75\xbb\x73\xf6\xbe\xfb\ \xdc\xb9\x87\x55\x5f\xeb\xfc\xec\xb3\xd6\x3a\x6b\xaf\xb3\xf7\x3a\ \x21\xc7\x52\xe2\xf1\x78\x15\xaa\x15\x56\x42\x0c\xa6\xc3\x14\x70\ \xe1\x3b\xbc\x85\x3e\x78\x00\xd7\x13\x89\xc4\x47\x1b\xbb\x21\x0b\ \xc7\xf3\x50\x5d\xb0\x09\xca\x2c\xe3\xcd\xc0\x6d\x38\x4e\x20\xf7\ \x8b\x0a\x00\xc7\x95\xa8\x13\xd0\x01\x61\xa7\x78\xe9\x81\x4e\x5d\ \x46\x42\x1a\xe7\x8b\x25\x8d\x50\xef\x94\x46\x06\xa0\x8d\x20\xee\ \xe4\xdf\x08\x7b\x38\x6f\x56\xe9\x9b\xe6\x94\x4e\x26\xc0\x96\x58\ \x2c\xf6\x26\x99\x4c\xf6\x6a\x33\x80\xf3\x26\x55\x44\x15\x4e\x30\ \xf2\x1b\x36\x90\x89\x5b\xa3\x02\xc0\x79\x35\xea\x99\x45\xda\x87\ \xe1\x26\x3c\x86\x34\xfc\x84\x19\xb0\x5c\x8c\x43\x65\x81\xe7\x87\ \x60\x29\x41\xbc\x96\x93\x48\xce\x8d\xa3\x05\x9c\x7f\x85\xc3\x70\ \x8e\x87\x87\x35\xb5\x53\x8e\xda\x0e\x07\xa1\x4a\x63\x47\xae\x9f\ \x67\x6c\x0b\x76\x32\x21\xf5\x60\x23\xea\xb9\xa1\xda\x53\xb0\x31\ \x1b\xb5\xc5\xa7\x3b\x53\x55\xff\x12\xc3\xb0\x56\xec\xf5\xb8\xea\ \xe4\x15\x6c\x53\x8e\xf2\xa5\x1f\x9a\x6d\x9d\x8b\x30\xf6\xbd\x3c\ \xa3\x5e\x4a\x27\xfb\xbd\x8a\x50\xce\x57\xc3\x1e\x58\x03\x23\xd0\ \x84\xc1\x17\xc5\x54\x1c\xf6\x66\xa3\xa4\xea\xcb\x35\x43\x16\x9a\ \x16\xa2\x05\xa8\xf9\x38\xbf\x3a\x96\xb2\xc7\xce\x21\xd4\x01\xcd\ \xed\xae\x90\x13\xb0\x10\x40\x2d\xea\x83\xda\x33\xf2\xe5\xae\x1b\ \x74\x00\x64\x30\x6d\xa8\x85\x68\x84\x08\xeb\x38\x58\x25\x55\xcb\ \xe0\x91\x80\xe2\x48\x69\xbe\x88\x5a\xc9\xc0\x1c\x90\x79\xfe\x44\ \x30\xa7\xa0\x21\x80\x00\x06\x35\xd7\xc3\xb2\x10\x4d\x56\x27\x35\ \xb0\x5b\x20\x88\x47\xe8\x0b\x12\x18\x59\xf9\x56\x82\x00\x6a\x34\ \xd7\x7f\x49\x06\xaa\x3d\x6e\xac\x80\x6e\x59\x6a\x09\xa6\x1b\x62\ \x63\x0c\xa0\x51\x73\x3d\x9d\x9b\x01\x2f\x99\xa4\xfa\x81\x0e\x82\ \x48\xa9\xac\x5c\x22\x2b\x03\x3e\xbe\x02\xd9\x27\x16\x69\x6e\xbf\ \x74\x0b\x04\x90\xff\x16\xa7\xe1\x22\x46\xcb\x7c\xbc\xfd\x4e\x43\ \xe3\xf3\x30\xe2\x23\x80\xcf\x52\x1f\xbc\xfd\x15\x1f\x6f\x1f\x45\ \xed\x32\x0c\xb9\x11\xd1\xd4\x40\xbe\x5c\x86\x1d\x38\x1f\xf2\xe1\ \x7c\x2a\xea\x1a\x8c\xd7\x0c\x79\x82\xbd\x5e\xdb\x29\x58\x26\xdf\ \xac\xcf\x3d\x40\x1a\x9b\xa8\x61\xd8\x91\x6c\x3f\x60\x13\xc0\x5c\ \x78\x8a\x61\x69\x52\xcf\x10\xf9\xa0\xa1\x91\xed\x84\x7d\x30\xd1\ \x60\xef\x9e\xa4\xff\xef\x6e\xc8\x43\xfd\xca\x81\xad\xfc\x90\x35\ \x1c\x92\x6a\x8d\x17\xa9\x53\x1d\xd1\x5a\x8b\xd6\x7d\x54\x47\x94\ \xcd\xc0\x3b\x38\xa9\x52\x63\x6a\xab\x64\x4e\xd7\x2b\x8a\xe9\x09\ \xdb\x72\x7b\x0b\x57\xa5\xea\x98\xda\x7a\xcf\xaa\xbe\xee\x4b\x00\ \xcb\xb1\xf4\x8e\xed\xb9\x0d\x69\x76\x0a\x1a\xb8\xd8\xe7\xd1\x0b\ \xc8\x1c\xcd\x0a\xfa\xbf\xc0\xd4\x90\x54\xa8\x29\xd9\xaa\xd9\xcb\ \x83\xfb\x33\xf2\xc8\xc6\x5e\xd8\x0c\xe3\xfe\xd9\xbf\xa1\x66\x61\ \x59\x07\x2d\x6a\x6d\xaf\xcf\x69\xbd\x8b\xff\x3b\xce\x64\x32\xce\ \xff\x94\x3f\x02\x0c\x00\xbe\x84\xeb\xde\xd4\xad\xd3\x24\x00\x00\ \x00\x00\x49\x45\x4e\x44\xae\x42\x60\x82\ \x00\x00\x07\x88\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x30\x31\x43\ \x33\x45\x33\x41\x37\x35\x39\x38\x35\x31\x31\x45\x33\x42\x46\x41\ \x33\x46\x46\x39\x46\x44\x38\x42\x31\x45\x45\x45\x30\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x30\x31\x43\x33\x45\x33\x41\ \x36\x35\x39\x38\x35\x31\x31\x45\x33\x42\x46\x41\x33\x46\x46\x39\ \x46\x44\x38\x42\x31\x45\x45\x45\x30\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x63\x31\x65\x61\x38\x31\x32\x35\ \x2d\x65\x62\x64\x64\x2d\x63\x38\x34\x62\x2d\x39\x66\x37\x61\x2d\ \x30\x36\x39\x39\x32\x39\x38\x64\x62\x39\x33\x63\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\x90\x2e\ \xe6\x71\x00\x00\x03\xad\x49\x44\x41\x54\x78\xda\xbc\x97\x69\x48\ \x55\x41\x14\xc7\xef\xd3\xd7\x26\x2d\x56\x28\x25\xb6\x88\x49\x54\ \x52\x7e\x50\xb3\xc5\x28\x69\x5f\xa0\x45\x2a\xa1\x32\xa3\x68\x7f\ \x24\x45\x44\x82\x96\x85\x96\x08\x81\x12\x51\xbd\xc8\x16\x22\xc2\ \xea\x43\x1b\xf5\x21\xeb\x4b\x4a\x09\x6a\x52\x10\xd8\x2e\x11\x11\ \xee\xb8\x96\xf5\x3f\xf0\xbf\x32\x5d\x6e\xef\xde\x6b\xcf\x0e\xfc\ \x98\xb9\x33\x6f\xce\x9c\x99\x39\x73\xe6\x3c\x97\xc7\xe3\x71\x69\ \x9a\xe6\x01\xdb\x41\x98\xd6\x3b\x29\x01\xc9\x05\x05\x05\x3f\x9d\ \x0e\x74\xc1\x80\x43\x28\x73\x41\x3b\x28\x02\x55\xac\xdb\x91\x20\ \x70\x9a\xf5\xcb\x60\x33\x8c\xf8\xe5\xc4\x00\x37\xd8\x0f\x5a\xc0\ \x1c\x0c\xae\x70\x32\x18\xc6\x07\xd3\x80\x8f\x60\x13\xa8\x03\xe9\ \x4e\x77\x40\x2c\x3e\x09\x72\xc0\x08\xd0\xc0\x1d\x18\x65\xf8\xed\ \x57\x30\x10\x04\xf3\xbb\x9d\xd4\x83\x75\x60\x23\x58\x0e\x32\xb1\ \x90\x63\x76\x0d\x08\x60\x59\x0e\xb6\x80\xf7\x60\x1f\x48\x60\x5d\ \x25\x81\x7d\xfa\xf7\x75\x45\x4f\x27\x8d\x10\x5f\xc8\xc6\xa2\x76\ \x3b\x35\xe0\x07\x28\x03\x47\xc1\x07\xae\x52\xea\x7b\xc1\x02\xd6\ \x83\xd9\xb7\x02\x6c\xa3\xbf\xf4\x08\x56\xdd\x8a\x62\x25\x78\x2e\ \x9f\x30\x22\xc5\x89\x01\x1a\x57\x98\x05\x2e\x82\xdb\xac\xcf\xe7\ \xee\x64\xb1\x4d\xfa\x6a\x41\xb4\x38\x9c\xc1\x97\xc4\x88\x26\x14\ \x8b\xc1\x6b\x70\x09\x46\x2c\x75\x62\xc0\x53\x3a\x50\x3a\x8f\x23\ \x02\xdc\xe7\xca\x23\x14\x44\x79\x36\x58\x0f\xf4\x6b\x17\xa3\xec\ \x84\xf8\x44\x12\xf8\x04\x8a\x61\xc4\x2c\x3b\x4e\xb8\x0a\x8c\x07\ \xa7\xd8\x5e\x05\x45\x31\xec\x4b\x43\xbd\xc8\xc7\x4d\x10\xcf\x0f\ \x04\x33\xf1\xbb\x57\x4a\x7b\x38\x8a\x52\x30\x14\x24\xa2\xef\xa5\ \x95\x01\x0f\xc0\x20\x93\xdf\xb4\x62\x70\xa7\x0f\x03\x32\xe9\x23\ \xcd\xc0\x0b\xaa\x81\x1e\x0b\x26\x80\x0c\xf0\x0d\xc4\x42\xcf\x67\ \xb3\x38\xa0\x8b\x38\xd7\x1e\x93\x39\x4e\x60\x92\xc1\x4a\x5f\x0d\ \x14\x6d\x55\xfa\x8f\x83\x2e\xb0\x83\xb7\xc4\x65\xa2\x23\x14\x44\ \x02\x9f\x06\x34\xd1\xcb\x8d\xd2\xcd\x09\xf4\xbe\x2f\x06\xef\xef\ \x66\x24\xcd\xf5\x11\xac\xea\xed\x38\x61\x08\x9d\x49\x38\x4c\x27\ \x92\x7a\x1e\xb7\x38\x12\x93\x89\xe7\xc7\x42\x69\x25\xf0\x6a\x7e\ \x10\x75\x07\xe4\x7a\x3d\xe6\x4e\x8c\xe4\xf7\x13\xa5\xbf\x8d\x65\ \x19\x23\x66\x8d\xbf\x0d\x98\x2c\xf7\x1e\xab\x9c\x8a\xd5\x49\x6c\ \x1f\xc6\xf6\x5d\x68\xbb\xa6\x6c\x79\xb6\xe6\x47\x51\x0d\x90\x95\ \x75\xe8\x8e\x07\x06\xb0\x5e\xa9\xf5\xa1\xb8\x95\x95\xc9\x4b\x58\ \xc1\xfa\x19\xed\x3f\x89\xdb\xc6\x93\x1b\xcb\x64\x25\xa4\x97\x73\ \xf4\xd3\xaf\x2b\x74\x7d\x67\x5d\x4a\x2f\x16\x5a\xe6\xb6\x98\x7c\ \x11\x8a\x3b\x8a\x92\x7f\x11\x63\x48\x4e\x83\xfe\xd5\x01\x16\x83\ \xf2\xfc\x34\xf9\xdf\x42\x40\xbe\x95\x01\x53\x58\x5e\x01\xaa\x5f\ \xa4\x82\x7b\x60\x1e\x58\xc6\x67\x58\xea\x0f\x59\x4a\x68\x5f\x08\ \xde\x2a\x63\x6e\xb2\x3d\x19\xbc\xd1\x43\xb5\x95\x01\x81\x2c\xab\ \x0d\x61\x54\x8e\x25\x8a\x09\x48\x28\x9f\xe0\x12\x25\x97\x94\xa7\ \xfb\x11\xc3\x6f\xcf\x89\x82\xab\x60\x09\xdf\x0c\x7b\x4e\x48\x69\ \xe6\x6b\xa9\x4b\x8b\x12\x27\x1a\x95\x47\xac\x93\x01\x4a\x9e\xf4\ \x70\xe6\x9b\xba\xac\x65\x0e\x21\x21\xfd\x82\x59\x28\xb6\x32\xa0\ \x3f\xeb\x75\xf0\xde\x2e\x25\x37\x6c\x53\xea\xad\x0c\x68\xf2\x28\ \x6d\x90\xa4\x84\x93\xde\xe2\xf1\xe4\xf3\xb8\xce\x3b\xdd\x81\x78\ \x70\x0e\x0c\x91\xc4\x05\xde\x9b\xa4\x04\xaa\x46\xc3\x83\x36\x1a\ \x8c\x53\x7c\x25\x95\xef\x8a\x24\xbb\x2f\x98\xf6\xc7\xdb\x35\x40\ \x5e\xb1\xe1\x3c\xbf\x19\xcc\x86\x52\x98\x27\xea\x92\xc3\x14\x4d\ \xa3\xe3\xcd\x36\xd1\x33\x96\x19\x57\x29\xf3\xcc\x44\xb6\x77\x58\ \x19\x70\x83\x41\x48\x24\x8e\x18\x65\xae\x52\x9f\xe8\x43\x57\x14\ \xf9\x43\x7f\x80\xc1\xdb\x8d\x72\x80\xe7\xd7\x17\x72\x57\x76\x43\ \xdf\x81\x68\xde\x53\xcd\x90\x6c\x88\xb7\xaf\xc1\x99\x87\xf1\xba\ \xf5\x46\xe4\x48\x0a\x99\xca\x97\xeb\xa1\x18\xba\x6b\xf5\x9c\xb0\ \x81\xd9\x6d\x1c\x1a\xdf\xf9\x73\x89\xd0\x1d\xc4\x1c\x63\x3a\x98\ \x66\x96\x98\xca\x0e\x9c\x05\x07\xe5\x0f\x05\x06\x14\x32\xe8\x74\ \xfb\x61\xfe\x31\x60\x27\x98\x04\x9e\x51\xaf\xe9\x6b\x98\xc1\x2c\ \x56\x92\xca\x23\x7e\x3e\x67\x89\x17\xc5\x4c\x6a\x4c\xff\x35\xff\ \x16\x60\x00\x9d\x8f\x25\xe2\xca\x2c\x04\xd4\x00\x00\x00\x00\x49\ \x45\x4e\x44\xae\x42\x60\x82\ \x00\x00\x06\xed\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x36\x31\x41\ \x31\x30\x32\x43\x34\x35\x39\x38\x35\x31\x31\x45\x33\x42\x46\x35\ \x45\x43\x42\x45\x34\x45\x41\x32\x36\x32\x30\x45\x41\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x36\x31\x41\x31\x30\x32\x43\ \x33\x35\x39\x38\x35\x31\x31\x45\x33\x42\x46\x35\x45\x43\x42\x45\ \x34\x45\x41\x32\x36\x32\x30\x45\x41\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x63\x31\x65\x61\x38\x31\x32\x35\ \x2d\x65\x62\x64\x64\x2d\x63\x38\x34\x62\x2d\x39\x66\x37\x61\x2d\ \x30\x36\x39\x39\x32\x39\x38\x64\x62\x39\x33\x63\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\xf0\xfb\ \xe3\xbf\x00\x00\x03\x12\x49\x44\x41\x54\x78\xda\xc4\x97\x59\x68\ \x14\x41\x10\x86\x67\x36\x6b\x3c\x58\x3c\x50\x30\xa8\xa8\xa0\x46\ \xe3\x85\x20\xc6\x20\x51\x04\x2f\x54\x44\xd4\x27\xf3\x10\x04\x11\ \x3c\xe2\x2a\xe2\x8b\x04\x3c\x02\x1e\xa0\x08\xae\x27\x88\x22\x06\ \x7c\x92\x48\x10\x73\x78\x60\x50\x09\x1e\x08\x12\x95\xa8\x41\xf0\ \x26\x3e\x88\x9a\x88\x17\xd9\xe8\x57\x50\x23\xcd\xb2\x99\xe9\xdd\ \x6c\xd6\x82\x2f\x95\xdd\xe9\xa9\xfa\xa7\xa7\xbb\xba\xd6\x75\x2c\ \x2c\x1a\x8d\xe6\xe0\xe6\xc0\x12\x98\x09\xf9\x30\x54\x2f\xff\x82\ \x37\xf0\x08\x6e\x40\x75\x2c\x16\x6b\x75\x2c\xcd\x0d\x48\x1c\xc1\ \x95\xc1\x26\x18\x61\x19\xb3\x03\xae\xc0\x01\x84\xdc\x4d\x5b\x00\ \xc9\x57\xe2\x8e\xc2\x30\x27\x7d\xbb\x04\xdb\x10\xf2\xca\x88\x3b\ \x1c\x57\xc1\x77\x6b\x93\x0a\x60\x40\x2f\x5c\x0c\xd6\x3b\x99\xb1\ \x76\x99\x41\x12\x56\x12\x7b\x22\xff\xd7\xc1\x10\x88\xf0\x5d\xa7\ \x9b\x90\x3c\x17\x77\x11\x96\x39\x99\xb7\xf3\x1a\x77\x90\x7e\xce\ \x47\x40\x4b\xc8\x48\x2e\x62\x2e\xf4\x50\x72\xb1\x52\x23\xb9\xd8\ \x64\xf9\x13\x36\xbe\xd8\x01\xab\x2c\x02\xb5\x41\x03\x3c\x87\x2f\ \x30\x18\x8a\xa1\x30\x45\x41\x53\x64\x8d\x84\xf5\xe9\x45\x4d\x45\ \xc0\x0d\xb2\x90\xf6\xc8\x2c\x31\x75\xbf\x93\xac\x9d\x31\xb8\xcd\ \xb0\x01\x72\x2d\x05\xfc\x9b\x81\x43\x90\x13\xf0\xfe\x64\x21\x7d\ \xeb\x6a\x00\xd7\x5e\xe2\xb6\x22\x44\x16\xf0\x39\x98\x6d\x23\x20\ \xc4\x0d\xd3\xf1\x8b\x7c\x06\x9e\x80\x35\x7e\xc9\x13\xec\x35\xb4\ \x58\x8c\x1b\x4b\xee\x3e\x32\x03\xeb\x7c\x06\xdd\x86\x2d\x24\xff\ \x63\x59\x31\xfb\xe9\x2e\x5a\x6c\x31\x5c\x66\xbc\x20\xac\xe5\x35\ \x99\x49\xd2\x32\x92\x77\x58\x26\xef\x8b\xbb\x06\xb3\x52\x59\x88\ \xb2\x0d\x27\xc0\x02\xd8\x0b\x8d\x10\xd7\x8b\x57\x49\xde\x64\x1b\ \x89\xb1\x3f\xf4\x61\x96\x6b\x05\x6d\xb6\x11\xe0\x76\x51\xff\x65\ \x5b\x7d\x22\xe8\x83\xee\x6c\x7c\x2d\xbb\xf3\x0d\xf2\x12\x86\xd4\ \xbb\x4e\x16\x0d\x41\x93\x0c\x31\x73\xe1\x6b\x56\x05\x24\x88\x91\ \xf5\x57\x24\xff\x14\xeb\x87\xff\x62\x2e\xc9\xdf\xe1\x07\x68\x79\ \xbd\x2e\xf0\xee\x9f\x66\x53\x40\x5d\x92\x42\xd4\xea\x89\x51\x41\ \xef\xbb\x39\xdd\x33\xf4\xcc\xb8\x93\x58\xd0\x44\xc0\x41\xfc\xf6\ \x80\x18\xcd\x86\xa0\x06\x82\xb4\xa5\x28\xc0\x7b\x48\xd9\xe2\xf7\ \xe0\xa6\xce\x78\xa3\xd4\x81\xc7\x16\x31\x0a\xf4\xa0\xa9\x86\x5a\ \x2d\x3a\xb6\xc9\xa7\xe2\x16\x1a\xd5\x4f\x0a\x55\xb9\x16\xad\x67\ \xb6\x02\x3c\xab\x95\xa2\xa5\x45\xc7\x76\xa5\x1f\xf3\x69\xfd\x6a\ \x42\x3a\xbd\x9d\x16\xf1\xce\x4a\xb3\x42\xf2\xef\x96\xc9\x25\xe9\ \x91\x80\x53\xf1\x74\x88\x80\x3f\x2d\x4f\xaf\x71\x30\xca\x32\x79\ \x44\x8f\xe4\x8d\x3e\xc3\xea\xc9\xfd\xd0\xdb\xff\xf2\x1a\xc6\x07\ \xc4\x95\x27\x69\x26\xf8\x49\xa9\xf5\x7a\xfe\x3b\x49\x7a\xca\x12\ \xd8\x05\xa3\x7d\x62\xc5\xbd\x85\xef\xea\x8d\x72\xc3\xee\x14\x77\ \xd7\x7d\xd9\x56\x72\x66\xc0\x40\x7d\x00\x29\xaf\xfd\x2d\xee\x2d\ \xe7\x01\xf6\x99\x1d\x51\x53\x1a\xdb\xbb\x30\x8d\x3e\x50\xac\x0a\ \xf6\x7b\x1f\xbc\xae\xf8\x89\x31\xe0\x33\x54\xf6\x50\xe1\xbb\x0c\ \xab\xcd\x06\xc7\x13\x20\xef\x53\xb6\xd6\x5b\x39\x8a\x19\x50\xaa\ \x6d\x74\x7b\x06\x93\x9f\x92\xae\x3b\xb1\xa1\x75\x8d\x05\x74\x06\ \xb7\xd3\x2c\xbb\x7c\x27\x0b\xe9\x30\xac\xe8\x46\xe2\x0f\x52\xc4\ \x88\x5b\x95\xf2\x8f\x53\x43\x48\x91\xfe\x6e\x58\x1a\xd0\x3d\x9b\ \x26\x87\xdc\x71\x29\x44\x7e\x0d\x6d\x4a\xfd\x00\x42\xf2\xb4\xe5\ \x9a\x07\xd3\x60\x24\xf4\xd6\xcb\x1f\xe1\x85\xd6\xfa\x1a\xb8\x45\ \xe2\x78\x50\xcc\xbf\x02\x0c\x00\xb3\x4a\xfb\x1f\xcd\xe1\x9d\xc3\ \x00\x00\x00\x00\x49\x45\x4e\x44\xae\x42\x60\x82\ \x00\x00\x07\x89\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x44\x39\x41\ \x43\x30\x30\x39\x35\x35\x39\x38\x44\x31\x31\x45\x33\x41\x41\x46\ \x43\x43\x39\x35\x30\x31\x33\x33\x31\x41\x30\x30\x39\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x44\x39\x41\x43\x30\x30\x39\ \x34\x35\x39\x38\x44\x31\x31\x45\x33\x41\x41\x46\x43\x43\x39\x35\ \x30\x31\x33\x33\x31\x41\x30\x30\x39\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x36\x63\x33\x30\x35\x65\x36\x65\ \x2d\x66\x31\x33\x66\x2d\x35\x65\x34\x38\x2d\x62\x37\x32\x65\x2d\ \x33\x31\x38\x39\x62\x37\x63\x66\x34\x66\x34\x38\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\x3e\x1d\ \x49\x08\x00\x00\x03\xae\x49\x44\x41\x54\x78\xda\xbc\x97\x69\x48\ \x54\x51\x14\xc7\xdf\x8c\x93\x95\x59\x4d\x8b\x11\x52\xe0\x46\xb4\ \x59\x7e\x50\xb2\x15\x22\xcb\x16\x82\xf6\x0d\x5a\x8c\x16\x93\x8a\ \xa4\x85\xc8\xd0\xb2\xc8\x32\xa1\x0f\x12\x51\x08\x69\x1b\x11\x56\ \x1f\x8c\x82\xc8\x16\xa8\x94\x92\xd4\xac\x88\xb0\xcd\x24\x22\x4a\ \xc5\x6c\x52\x4b\xeb\x7f\xe0\xff\xe4\xf6\x78\xce\xcc\x9b\xc6\x0e\ \xfc\xb8\xf7\xdd\xfb\xde\xbd\xff\x7b\xe7\xdc\x73\xcf\xd8\x76\x9e\ \x2d\xb1\x69\x9a\xb6\x15\x6c\x04\xa1\x9a\x6f\x76\x07\x2c\x3a\xba\ \x72\x7c\x9b\xd5\x0f\x6d\x10\xb0\x1b\x65\x16\x68\x06\xf9\xa0\x92\ \x75\x6f\x2c\x08\x1c\x67\xbd\x00\x24\x41\xc4\x6f\x2b\x02\x1c\x60\ \x3b\x68\x02\x53\xf0\x71\xb9\x95\x8f\x21\xde\x49\x01\xef\xc1\x6a\ \x50\x0f\x52\xad\xee\x80\x28\x3e\x02\x0e\x81\xfe\xa0\x81\x3b\x30\ \xd8\xf0\xee\x27\xd0\x03\x38\xf9\xdc\x4c\x64\xd2\xa5\x60\x15\x98\ \x03\xd2\xb1\x90\x03\xde\x0a\xb0\xb3\x2c\x03\x6b\xc1\x5b\xb0\x0d\ \xc4\xb3\xae\x12\xcf\x3e\xfd\xf9\xa2\x32\x4e\x2b\x58\x42\x5f\xc8\ \xc4\xa2\x52\xac\x0a\xf8\x05\x4a\xc1\x7e\xf0\x8e\xab\x94\xfa\x16\ \x30\x9d\x75\x27\xfb\xe6\x82\xf5\xf4\x97\x0e\xc3\xaa\x5d\x28\xe6\ \x81\x47\x20\x17\x22\x96\x5b\x11\xa0\x71\x85\x19\xe0\x34\xb8\xca\ \x7a\x02\x77\x27\x83\x6d\xd2\x57\x0b\x46\x83\x35\x06\x5f\x12\x11\ \x8d\x28\x66\x82\x17\xe2\x94\x10\x31\xdb\x8a\x80\x7b\x74\xa0\x54\ \xfe\x1c\xe1\xe0\x3a\x57\x1e\xae\x20\x83\x67\x82\x65\x40\x3f\x76\ \x31\xca\x4e\x88\x4f\x4c\x03\x35\xa0\x10\x22\x26\x7a\xe3\x84\xf3\ \x41\x18\x38\xc6\xf6\x4a\x0c\x14\xc3\x3e\x39\x5a\xf9\x6e\x4e\x42\ \x1d\x8a\x00\x30\x01\xef\x3d\x57\xda\x87\xa0\x28\x01\x7d\xc0\x64\ \xf4\x3d\xf5\x24\xe0\x06\xe8\x69\xf2\x8e\x0b\x1f\xb7\xba\x11\x90\ \x4e\x1f\xf9\x06\xf2\x40\x15\xd0\x63\x41\x14\x48\x03\x9f\x41\x2c\ \xc6\xf9\x60\x16\x07\x74\x13\xe7\xda\x6c\x32\xc7\x61\x4c\x12\xac\ \xf4\x55\x63\xa0\x75\x4a\xff\x41\xf0\x13\x24\xf3\x94\xd8\x4c\xc6\ \x18\x04\x22\x81\x5b\x01\x8d\xf4\x72\xa3\xb5\x73\x02\xbd\xef\xa3\ \xc1\xfb\xdb\x19\x49\xb3\xdc\x04\xab\x7a\x6f\x9c\x30\x84\xce\x24\ \xec\xa1\x13\x49\x3d\x9b\x5b\x1c\x89\xc9\xc4\xf3\x63\x31\x68\x05\ \xc8\xd3\xfc\x60\xea\x0e\xc8\xf1\xba\xcd\x9d\x18\xc0\xe7\xbb\x4a\ \xff\x0f\x96\xa5\x8c\x98\xd5\xfe\x16\x30\x52\xce\x3d\x56\x39\x06\ \xab\x93\xd8\xde\x97\xed\x29\x68\xbb\xa0\x6c\x79\xa6\xe6\x47\x53\ \x05\xc8\xca\x5a\x74\xc7\x03\xdd\x59\xaf\xd0\xba\xd0\x1c\xca\xca\ \xe4\x26\x2c\x67\xfd\x84\xf6\x9f\xcc\xe1\xc5\x95\x1b\xcb\x64\x25\ \xc4\xc7\x39\xba\xe9\xc7\x15\x63\x7d\x61\x5d\xca\x3c\x2c\xb4\xd4\ \xe1\x61\xf2\x44\x14\x45\xca\x20\xff\x62\xc6\x90\x9c\x84\xf1\x17\ \xd8\x3d\x7c\x94\xed\xa7\xc9\x3b\x0b\x01\x39\x9e\x04\x8c\x32\x69\ \x2b\x62\xe2\xf1\x8c\xcf\xaf\xf9\x5c\xcc\xe7\x27\x8c\x8e\x4d\xcc\ \x92\x12\x18\xa2\x2b\x79\xc9\xa9\x16\xe5\x49\x40\x80\xe1\x59\x62\ \xbc\xc4\xfe\x68\x70\x8e\x6d\x75\x14\x93\xcc\x53\x24\xe1\xf6\x15\ \xef\x96\x97\xe0\x16\x85\x48\xa6\xf5\xc0\x5d\x24\xf4\xc6\x24\x0b\ \x1a\xc8\xeb\xf6\x3c\x05\x49\x22\x12\x07\xa6\x32\x1c\xbb\x78\x03\ \xca\xdd\x12\x08\xf6\xf1\x67\x74\x31\x89\xf5\x59\x40\x1b\x13\x13\ \x39\x15\x0f\x79\x73\x16\x33\x72\xf6\xa6\xbf\x14\x70\x37\x82\x99\ \x3f\xde\x64\x7c\xc9\x01\xdf\x41\x2f\xcb\xc7\x50\xb1\x53\x60\xb8\ \x72\xe9\xc8\xa4\x67\x40\x22\x57\xea\xa4\x88\x15\x60\x2f\x93\x99\ \x06\xf6\x7d\x65\xf8\x0e\xb4\x2a\x40\x6e\xb1\x7e\xac\x47\xd3\xd9\ \x3a\x8e\x11\x78\x0c\x86\x81\xb1\x6c\x5b\xcc\xd5\x47\x30\x92\xde\ \x07\x1b\x98\xa6\xd5\x30\x95\x53\xad\xc5\x93\x80\x4b\x0c\x42\x62\ \x93\x0c\x7d\x22\x6c\x86\xc9\x37\xb3\x94\x7a\x98\x52\x8f\x20\x7f\ \x8d\x6f\xef\xc4\xdb\x75\xdb\x01\xae\x74\x51\x1c\xb8\x26\x59\xb7\ \xbe\x03\xb2\x35\x97\x8d\x6f\x20\x54\xca\x59\x5e\x88\x88\x15\xca\ \xac\xc6\x17\x93\x9d\xcb\x65\x2a\x5f\xa6\x87\x62\x8c\x5d\xab\xe7\ \x84\x0d\xf4\xf0\x38\x34\xbe\xf1\xe7\x12\x31\x76\x10\x73\x8c\x71\ \xe2\x27\x66\x89\xa9\xec\xc0\x49\xb0\x4b\xfe\x50\xe0\x83\x5c\x26\ \x95\xed\x7e\x98\x7f\x28\xd8\x04\x46\xf0\xd8\x56\x75\x76\x1b\xa6\ \x31\xa0\x24\x33\x68\xf8\xd3\x24\x97\x2c\x64\x52\x63\xfa\xaf\xf9\ \x8f\x00\x03\x00\xa7\xa0\x22\x71\x6e\x63\x94\xd3\x00\x00\x00\x00\ \x49\x45\x4e\x44\xae\x42\x60\x82\ \x00\x00\x06\xed\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x35\x34\x30\ \x45\x44\x39\x43\x31\x35\x39\x38\x35\x31\x31\x45\x33\x39\x39\x43\ \x37\x38\x31\x46\x35\x33\x32\x45\x32\x43\x37\x44\x43\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x35\x34\x30\x45\x44\x39\x43\ \x30\x35\x39\x38\x35\x31\x31\x45\x33\x39\x39\x43\x37\x38\x31\x46\ \x35\x33\x32\x45\x32\x43\x37\x44\x43\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x63\x31\x65\x61\x38\x31\x32\x35\ \x2d\x65\x62\x64\x64\x2d\x63\x38\x34\x62\x2d\x39\x66\x37\x61\x2d\ \x30\x36\x39\x39\x32\x39\x38\x64\x62\x39\x33\x63\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\xce\x34\ \xc5\x6a\x00\x00\x03\x12\x49\x44\x41\x54\x78\xda\xc4\x97\x7b\x68\ \x8d\x71\x18\xc7\xdf\xf7\xec\x98\x4b\x27\x97\x28\x0b\xa1\x30\xe6\ \x96\x92\x59\x1a\xa9\xb9\x84\x24\xfc\x65\x7f\x2c\x91\x62\x26\x92\ \x7f\xb4\x72\x59\xb9\x14\x29\xb7\x51\xb2\x64\xe5\x2f\x4d\x4b\x76\ \x71\xc9\x42\xcb\x25\xa5\xa1\x83\xa5\xdc\x9b\x3f\x84\x4d\x6e\xed\ \x8c\xcf\x53\xcf\xab\x5f\xa7\xb3\xf7\xfd\x9d\xcb\xe6\xa9\xcf\x9e\ \x9d\xf3\xfe\xde\xe7\xf9\xbe\xbf\xf7\xf7\x7b\x7e\xcf\x71\x1d\x0b\ \xbb\x51\xb9\x2e\x0b\x37\x0f\x96\xc2\x6c\xc8\x85\xe1\x7a\xf9\x17\ \xbc\x81\x47\x32\x14\x6a\x8b\x4a\xab\xda\x1c\x4b\x73\x03\x12\x47\ \x70\x65\xb0\x19\x46\x59\xc6\xec\x84\x2b\x70\x10\x21\x77\x53\x16\ \x40\xf2\x55\xb8\xe3\x30\xc2\x49\xdd\x2e\xc1\x76\x84\xbc\x32\xe2\ \x8e\xc4\x55\xf0\xdd\xfa\x84\x02\x18\xd0\x07\x77\x0c\x36\x3a\x99\ \xb1\x0e\x99\x41\x12\x56\x13\x7b\x32\xff\x37\xc0\x30\x88\xf0\x5d\ \x97\x1b\x97\x3c\x1b\x77\x11\x96\x3b\x99\xb7\xf3\x1a\x77\x88\x7e\ \xce\x45\x40\x6b\xc8\x48\x2e\x62\x2e\xf4\x50\x72\xb1\x12\x23\xb9\ \xd8\x54\xf9\x13\x36\xbe\xd8\x09\xab\x2d\x02\xb5\x43\x13\x3c\x87\ \x2f\x30\x14\x0a\x21\x3f\x49\x41\xd3\x64\x8d\x84\xf5\xe9\x45\x4d\ \x45\xc0\x0d\xb2\x90\xf6\xca\x2c\x31\x75\xbf\x13\xac\x9d\x71\xb8\ \x2d\xb0\x09\xb2\x2d\x05\xfc\x9b\x81\xc3\x90\x15\xf0\xfe\x64\x21\ \x7d\xeb\x6e\x00\xd7\x5e\xe2\xb6\x21\x44\x16\xf0\x39\x98\x6b\x23\ \x20\xc4\x0d\x33\xf1\x8b\x7d\x06\x56\xc2\x5a\xbf\xe4\x71\xf6\x1a\ \x5a\x2d\xc6\x8d\x27\x77\x3f\x99\x81\x0d\x3e\x83\x6e\xc3\x56\x92\ \xff\xb1\xac\x98\x03\x74\x17\x2d\xb1\x18\x2e\x33\x9e\x17\xd6\xf2\ \x9a\xc8\x24\x69\x19\xc9\x3b\x2d\x93\xf7\xc7\x5d\x83\x39\xc9\x2c\ \x44\xd9\x86\x93\x60\x21\xec\x83\x66\x88\xe9\xc5\xab\x24\x6f\xb1\ \x8d\xc4\xd8\x1f\xfa\x30\x2b\xb4\x82\x46\x6d\x04\xb8\xdd\xd4\x7f\ \xd9\x56\x9f\x08\xfa\x20\x9d\x8d\xaf\x65\x77\x81\x41\x4e\xdc\x90\ \x46\xd7\xe9\x45\x43\xd0\x14\x43\xcc\x7c\xf8\xda\xab\x02\xe2\xc4\ \xc8\xfa\x2b\x90\x7f\x0a\xf5\xc3\x7f\x31\x97\xe4\xef\xf0\x83\xb4\ \xbc\x5e\x17\x78\xf7\x4f\x7b\x53\x40\x43\x82\x42\xd4\xe6\x89\x51\ \x41\xef\xd3\x9c\xee\x59\x7a\x66\xdc\x89\x2f\x68\x22\xe0\x10\x7e\ \x47\x40\x8c\xa8\x21\xa8\x89\x20\xed\x49\x0a\xf0\x1e\x52\xb6\xf8\ \x3d\xb8\xa9\x33\xde\x2c\x75\xe0\xb1\x45\x8c\x3c\x3d\x68\x6a\xa1\ \x5e\x8b\x8e\x6d\xf2\xe9\xb8\x45\x46\xf5\x93\x42\x55\xae\x45\xeb\ \x99\xad\x00\xcf\xea\xa5\x68\x69\xd1\xb1\x5d\xe9\x27\x7c\x5a\xbf\ \xba\x90\x4e\x6f\x97\x45\xbc\x2a\x69\x56\x48\xfe\xdd\x32\xb9\x24\ \x3d\x1a\x70\x2a\x9e\x09\x11\xf0\xa7\xe5\xe9\x35\x01\xc6\x58\x26\ \x8f\xe8\x91\x5c\xea\x33\xac\x91\xdc\x0f\xbd\xfd\x2f\xaf\x61\x62\ \x40\x5c\x79\x92\x28\xc1\x4f\x49\xad\xd7\xf3\xdf\x49\xd0\x53\x16\ \xc3\x6e\x18\xeb\x13\x2b\xe6\x2d\x7c\x57\x6f\x94\x1b\xf6\x24\xb9\ \xbb\xee\xcb\xb6\x92\x33\x03\x06\xeb\x03\x48\x79\x1d\x68\x71\x6f\ \x39\x0f\xb0\xdf\xec\x88\x5a\x52\xd8\xde\xf9\x29\xf4\x81\x62\x35\ \x70\xc0\xfb\xe0\x75\xc5\x4f\x8c\x01\x9f\xa1\xba\x87\x0a\xdf\x65\ \x58\x63\x36\x38\x9e\x00\x79\x9f\xb2\xb5\xde\xca\x51\xcc\x80\x12\ \x6d\xa3\x3b\x32\x98\xfc\xb4\x74\xdd\xf1\x0d\xad\x6b\x2c\xa0\xb3\ \xb8\x5d\x66\xd9\xe5\x3b\x59\x48\x47\x60\x65\x1a\x89\x3f\x48\x11\ \x23\x6e\x4d\xd2\x3f\x4e\x0d\x21\x05\xfa\xbb\x61\x59\x40\xf7\x6c\ \x9a\x1c\x72\x27\xa5\x10\xf9\x35\xb4\x49\xf5\x03\x08\xc9\xd1\x96\ \xab\x08\x66\xc0\x68\xe8\xab\x97\x3f\xc2\x0b\xad\xf5\x75\x70\x8b\ \xc4\xb1\xa0\x98\x7f\x05\x18\x00\x90\xb5\xfd\x36\x34\xeb\xb9\xe4\ \x00\x00\x00\x00\x49\x45\x4e\x44\xae\x42\x60\x82\ \x00\x00\x06\xa4\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x42\x33\x41\ \x34\x45\x35\x42\x34\x35\x39\x38\x34\x31\x31\x45\x33\x42\x33\x31\ \x41\x45\x43\x34\x30\x43\x43\x32\x45\x39\x37\x31\x33\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x42\x33\x41\x34\x45\x35\x42\ \x33\x35\x39\x38\x34\x31\x31\x45\x33\x42\x33\x31\x41\x45\x43\x34\ \x30\x43\x43\x32\x45\x39\x37\x31\x33\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x63\x31\x65\x61\x38\x31\x32\x35\ \x2d\x65\x62\x64\x64\x2d\x63\x38\x34\x62\x2d\x39\x66\x37\x61\x2d\ \x30\x36\x39\x39\x32\x39\x38\x64\x62\x39\x33\x63\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\x47\x2d\ \xcb\x84\x00\x00\x02\xc9\x49\x44\x41\x54\x78\xda\xc4\x57\x3f\x68\ \x93\x41\x14\xff\xbe\x10\x07\x07\x3b\x39\x89\x53\x51\x52\x1b\xd4\ \x45\x70\x90\xaa\x74\x28\xba\x28\x14\x07\xd7\x12\x41\x68\x27\x69\ \x52\x1d\xc4\x21\x76\x51\x11\xb7\xba\xa8\x38\x38\x04\x07\xc1\xe2\ \x10\x1d\x4a\x1d\xbb\xf9\x87\xb4\x69\xa3\x99\x82\x53\x1d\xcc\x2a\ \x34\xfe\x1e\xfc\x0e\x8e\xf3\xde\xdd\x97\xd0\x4f\x1f\xfc\xf8\xc2\ \x5d\xde\x7b\xbf\x7b\xef\xdd\xbb\xbb\x34\x19\x41\xce\xbe\xbd\x5e\ \xc5\xe7\x1e\x70\x88\x43\x7d\xa0\xbe\x71\xb5\xf1\x78\x58\x5b\xe9\ \x08\xce\x8f\xe0\xd3\xf3\xe8\x0e\x80\xa3\x20\xf1\x63\x18\x7b\x85\ \x11\x02\x70\x5c\x21\x9e\x72\x6e\x28\x29\x2a\xab\x9c\xc3\x67\x1e\ \xd8\x05\xaa\x58\x55\x2b\x63\xd4\x52\xc7\xce\x79\x49\x0d\xfd\x2c\ \xc3\x4e\x33\x1a\x01\x28\xdd\xc1\xe7\x05\x70\x06\xb8\x04\xac\x63\ \xec\x24\xe7\xc4\xc1\x78\x80\xc0\x38\xff\x23\xff\x9d\xc6\x47\x1c\ \x5e\x00\xce\x01\xab\x18\xbb\x12\x63\x3c\x47\xe7\xae\x48\x24\x1e\ \x01\x37\x32\x84\xf9\x1b\xd0\x00\x16\x81\x83\xce\xdc\x6f\x59\x14\ \x22\xb1\xa6\x45\x60\x5e\x31\x7a\x18\x78\x90\x31\xc7\xc7\x80\xbb\ \x1e\xe7\x22\x07\x80\x9b\xa1\x14\xec\x26\xf9\xcb\xcf\x10\x81\x6a\ \xce\x24\xbe\x03\xf7\x83\x7d\x80\x05\xb7\xc6\xb0\x87\x64\x1b\xd8\ \xe2\xef\x13\x40\x29\x83\xf3\x8b\xc8\x7f\x2f\xda\x88\x40\x62\x89\ \x39\xf7\xc9\x7b\x60\x09\x86\xbe\x38\x3a\xa7\x58\xa8\x33\x8a\xde\ \x02\x74\x56\xa2\x9d\x90\xdb\x68\x5b\x29\xb8\x27\x52\xdd\x30\x34\ \x50\x88\x8b\xae\xb4\xe3\x5b\x9e\xe9\x1d\x60\xc2\xd5\x4d\xad\xf6\ \x6a\x3a\x9c\xec\xf3\xe7\xca\xca\x2f\x1b\x03\xd0\x91\xfa\x99\xe4\ \xdc\x26\xc6\xf7\x2c\x12\x4d\x25\x12\x15\xa0\xcb\xb6\xdd\x91\xb6\ \x9d\x42\x61\x91\xa1\x8b\x9d\x0b\xa7\x4d\xd8\xa1\x23\x39\x7f\x23\ \x2b\xe2\x5c\x1b\x98\xc5\xfc\x96\x95\x8e\xcf\x11\x7b\x42\xa2\x26\ \x04\x7e\xe1\xc7\x58\xac\xe0\x60\x7c\xc2\x5a\x79\xcb\x72\x9e\x58\ \x24\xca\x56\x24\xda\x19\x0a\xb3\x5f\xc8\xe0\xdc\x18\x37\x52\xf6\ \x38\x4f\x38\x36\xa9\xe8\x68\x32\x56\x48\xfe\xb3\x14\x78\x99\x88\ \x89\xbd\xe2\x96\xb2\x3a\x19\xdb\x54\x74\x82\x29\xa8\xb3\x20\x42\ \x52\x62\x61\x25\xcc\xf1\xac\x43\xc2\x14\xe1\x9e\x55\x84\xa5\x0c\ \x45\x58\x1f\x66\x1b\x7e\xe0\x49\x66\x6f\xc3\xb2\x89\xca\xc8\xdb\ \x50\x69\x26\x3b\x3c\xd5\xf6\xb3\x11\x75\x24\x2a\xae\xee\x5f\x45\ \xc8\x3f\x34\x94\xb0\x89\xe1\xa6\x49\x87\xa7\x15\x37\x15\xe7\x22\ \xcf\x7c\xc4\x7d\x11\x90\x9b\xcc\x3b\xe5\x3c\x77\x0f\xa3\xb6\x55\ \x70\xb1\x9c\xcb\x29\x3b\x0d\x12\x5f\x63\x77\xb8\x66\x06\xe7\xa3\ \x8a\x90\x98\x02\x89\xb6\x96\x82\x7a\x8e\xce\xcd\xcd\xea\x76\xa8\ \x06\x8a\xff\xa0\xf7\x14\x43\x04\x96\x79\x71\xf4\x5d\x26\x16\xb8\ \x3b\x62\xd2\xe1\x2a\x7d\x37\xab\x3e\x77\x89\x9f\x00\xef\xed\xd7\ \x1c\x12\xe6\x26\xb3\xc2\x62\xab\x04\x9c\x57\xb8\xd5\x1e\x4a\xc1\ \x39\x24\xc4\xf9\x0c\xe6\x3e\xc5\xb6\xe1\x2a\xdf\x03\xaf\x81\xa7\ \x2c\x9a\x9e\xb5\x45\xbb\x01\x02\x5d\xb3\xd5\x58\xed\x53\xc0\x4b\ \xe0\x95\xbc\x0f\x30\xb6\xb1\x1f\x6f\x43\x79\x68\xac\x2b\xd3\x12\ \xa9\x8f\x79\xbf\x0d\x3b\xca\xd9\x31\xe0\x5c\x92\x2b\x01\xbe\x7e\ \x6b\xce\x29\x2a\x97\x9a\xda\xb0\x2f\x63\x91\x3f\x02\x0c\x00\x21\ \x27\x10\xbf\xa7\x82\xc6\x68\x00\x00\x00\x00\x49\x45\x4e\x44\xae\ \x42\x60\x82\ \x00\x00\x04\xf8\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x41\x45\x36\ \x37\x43\x43\x34\x36\x35\x39\x38\x44\x31\x31\x45\x33\x39\x32\x37\ \x33\x46\x43\x46\x32\x35\x44\x37\x31\x38\x43\x35\x39\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x41\x45\x36\x37\x43\x43\x34\ \x35\x35\x39\x38\x44\x31\x31\x45\x33\x39\x32\x37\x33\x46\x43\x46\ \x32\x35\x44\x37\x31\x38\x43\x35\x39\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x37\x31\x65\x61\x35\x61\x61\x61\ \x2d\x63\x33\x30\x31\x2d\x30\x61\x34\x35\x2d\x62\x36\x30\x35\x2d\ \x38\x64\x36\x65\x63\x37\x33\x34\x65\x37\x62\x66\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\xe1\x20\ \xe3\x43\x00\x00\x01\x1d\x49\x44\x41\x54\x78\xda\x62\x6c\x4f\x5c\ \x74\x8e\x81\x81\xc1\x90\x01\x3b\xf8\x0b\xc4\x61\x95\xf3\xe3\xd6\ \x81\x38\x40\xb5\x09\x40\x6a\x1e\x10\x33\x32\x50\x07\x9c\x67\xc2\ \x63\x39\x08\x30\x03\xb1\x1e\x12\xdf\x81\x8a\x96\x83\x80\x21\x13\ \xc3\x00\x83\x51\x07\x8c\x3a\x00\xe4\x80\x4f\x04\xd4\x7c\x44\x62\ \x3f\xa7\xb2\xfd\x9f\x58\x80\x84\x31\x10\xeb\xe0\x50\xf0\x03\x88\ \xf7\x20\xf1\x1b\x80\xf8\x30\x10\xb3\x51\xc9\x01\x57\x18\x46\x3c\ \x60\x84\x16\xaf\x0e\x38\xe4\xbf\x00\x71\x07\xb0\x28\x7e\x02\x2d\ \x8a\xd5\x80\x54\x31\x10\xb3\x53\xc9\xfe\x03\x2c\x44\x94\xed\xaf\ \x80\xb8\x09\xca\x2e\x04\xe2\x34\x2a\x06\x40\x1c\x13\x11\x65\x3b\ \x72\x56\xe5\xa4\x76\x0c\x8c\x16\x44\xa3\x0e\x00\x39\xe0\x3f\x01\ \x35\xff\x90\xd8\xdf\xa9\x6c\xff\x7f\x50\x36\x4c\x22\x50\x0e\xcc\ \x43\xe2\xf7\x43\x1d\x4d\xb5\x72\x60\xb4\x28\x06\x15\xc5\x2a\x78\ \x6a\x43\x50\x9c\xef\x05\x16\xc5\x7f\xa0\x45\x31\x28\xe8\x9d\xa9\ \x59\x1b\x82\xd2\xc0\x59\x20\xe6\xc3\xa3\xa8\x08\x1a\xf7\xb0\xea\ \xb8\x82\x9a\xed\x01\x26\x02\x96\x83\x00\x3f\x12\x5b\x92\xca\x31\ \xc0\x37\x5a\x10\x8d\x3a\x60\x50\x38\xe0\x1c\x1e\x79\x50\xfe\xbf\ \x84\x56\x74\xfe\xa7\xa2\xfd\xe7\x18\xff\xff\xff\x3f\xa0\x21\x00\ \x10\x60\x00\xb3\xf5\x3a\xe9\xf9\xc0\x6c\x8c\x00\x00\x00\x00\x49\ \x45\x4e\x44\xae\x42\x60\x82\ \x00\x00\x06\xb1\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x00\x20\x00\x00\x00\x20\x08\x06\x00\x00\x00\x73\x7a\x7a\xf4\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x71\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\ \x39\x66\x62\x31\x39\x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\ \x39\x39\x31\x31\x2d\x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\ \x31\x22\x20\x78\x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x42\x45\x42\ \x44\x37\x42\x46\x37\x35\x39\x38\x44\x31\x31\x45\x33\x39\x39\x41\ \x31\x41\x44\x34\x30\x37\x44\x35\x45\x43\x33\x39\x32\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x69\x69\x64\x3a\x42\x45\x42\x44\x37\x42\x46\ \x36\x35\x39\x38\x44\x31\x31\x45\x33\x39\x39\x41\x31\x41\x44\x34\ \x30\x37\x44\x35\x45\x43\x33\x39\x32\x22\x20\x78\x6d\x70\x3a\x43\ \x72\x65\x61\x74\x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\ \x65\x20\x50\x68\x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\ \x57\x69\x6e\x64\x6f\x77\x73\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\ \x4d\x3a\x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\ \x52\x65\x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x69\x69\x64\x3a\x37\x31\x65\x61\x35\x61\x61\x61\ \x2d\x63\x33\x30\x31\x2d\x30\x61\x34\x35\x2d\x62\x36\x30\x35\x2d\ \x38\x64\x36\x65\x63\x37\x33\x34\x65\x37\x62\x66\x22\x20\x73\x74\ \x52\x65\x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\ \x78\x6d\x70\x2e\x64\x69\x64\x3a\x63\x34\x37\x39\x66\x62\x31\x39\ \x2d\x34\x33\x34\x34\x2d\x62\x65\x34\x33\x2d\x39\x39\x31\x31\x2d\ \x33\x64\x35\x32\x63\x31\x30\x33\x35\x37\x65\x31\x22\x2f\x3e\x20\ \x3c\x2f\x72\x64\x66\x3a\x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\ \x6e\x3e\x20\x3c\x2f\x72\x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\ \x78\x3a\x78\x6d\x70\x6d\x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\ \x63\x6b\x65\x74\x20\x65\x6e\x64\x3d\x22\x72\x22\x3f\x3e\x59\x34\ \x5e\xf3\x00\x00\x02\xd6\x49\x44\x41\x54\x78\xda\xc4\x97\x5d\x88\ \x4d\x51\x14\x80\xcf\x3d\x73\x63\x26\xe6\x0f\x2f\x63\xa8\x91\xc2\ \x35\xe3\x67\xfc\x34\xe1\x6d\x26\x94\x28\x23\x4f\xa3\xa6\x34\xe4\ \x61\x46\x92\x17\x3f\x8d\x48\x92\x9f\xf0\x20\x2f\x46\x44\x92\x07\ \x19\x85\xc4\x83\x9f\x17\x94\x50\x73\x87\x49\x29\xf2\x73\xf3\x30\ \x4d\x83\x49\x46\x5c\xdf\xd2\x3e\x75\xba\x73\xf6\xbe\xfb\x9c\xb9\ \x87\x55\x5f\xeb\xde\x73\xf6\x59\x6b\xed\xb5\xd7\xd9\x7b\x9d\x84\ \x63\x29\x87\x36\x5e\x28\x47\x35\xc3\x52\x68\x80\xc9\x30\x01\x5c\ \xf8\x0e\x6f\xa1\x17\x1e\xc0\xb5\x5d\xe7\x5a\x3f\xda\xd8\x4d\x58\ \x38\x9e\x85\xea\x84\x75\x50\x6c\x19\x6f\x16\x6e\xc3\x11\x02\xb9\ \x1f\x29\x00\x1c\x97\xa1\x8e\x42\x1b\x14\x39\xd1\xa5\x1b\x3a\x74\ \x19\x49\x68\x9c\xcf\x97\x34\x42\x8d\x53\x18\xe9\x87\x16\x82\xb8\ \x93\x7b\xc3\x0d\x70\xde\xa8\xd6\xb1\x50\xce\x45\x26\xc2\x0d\x6c\ \x6f\x30\x66\x80\x01\xf5\xca\x79\xa9\x13\x8f\xfc\x86\x35\x64\xe2\ \xd6\x88\x00\x70\x5e\x81\x7a\x6e\x31\xf3\x21\xb8\x09\x8f\x21\x03\ \x3f\x61\x0a\x2c\x16\xe3\x50\x96\xe7\xf9\x41\x58\x48\x10\x6f\xe4\ \x4f\xd2\x9f\x80\x3c\xce\xbf\xc2\x01\x38\xcd\xc3\x43\x9a\xda\x29\ \x41\x6d\x81\x7d\x50\xae\xb1\x23\xd7\xcf\x30\xb6\x09\x3b\xd9\x84\ \x7a\xb0\x0e\xf5\xc2\x50\xed\x69\x58\xeb\x45\x6d\xf1\xea\x4e\x55\ \xd5\xbf\xc0\x30\xac\x19\x7b\xdd\x5e\x11\xbe\x86\xcd\xca\x51\xae\ \xf4\x41\xa3\xad\x73\x11\xc6\xbe\x97\x67\xd4\xa4\x74\xb2\x27\xa8\ \x08\xe5\xff\x72\xd8\x01\x2b\x60\x18\xea\x31\xf8\x32\x4a\xc5\x61\ \x6f\x3a\xaa\x07\x4a\x34\x43\xe6\x9a\x36\xa2\x39\xa8\xd9\x38\xbf\ \x32\x9a\xb2\xc7\xce\x7e\xd4\x5e\xcd\xed\xce\x84\x13\xb3\x10\x40\ \x15\xea\x43\xd0\x9e\x83\xdc\x75\xe3\x0e\x80\x0c\x66\x0c\xb5\x90\ \x4a\x12\x61\x35\x3f\x96\x49\xd5\x32\x78\x38\xa6\x38\xd2\x9a\x37\ \xa2\x4a\x32\x30\x03\x64\x9d\x3f\x11\xcc\x71\xa8\x8d\x21\x80\x01\ \xcd\xf5\x22\xd9\x88\x2a\x7d\xfb\xf5\x76\x81\x20\x1e\xa1\xcf\x4a\ \x60\x64\xe5\x5b\x81\xce\x82\x20\xf9\x25\x19\xa8\x08\xb8\xb1\x04\ \xba\x64\xab\x25\x98\x2e\x68\x18\x65\x00\x75\x9a\xeb\x19\x7f\x06\ \x82\x64\xbc\xea\x07\xda\x08\x22\xad\xb2\x72\x91\xac\xf4\x87\x78\ \x0b\xe4\x9c\x98\xa7\xb9\xfd\xca\xcd\x13\x40\xee\x2c\x4e\xc0\x79\ \x8c\x16\x87\x98\xfd\x56\x43\xe3\xf3\x30\x19\x22\x80\xcf\x52\x1f\ \xcc\xfe\x72\x88\xd9\xa7\x50\xdb\x0c\x43\xae\x27\x35\x35\x90\x2b\ \x97\xa0\x1d\xe7\x83\x21\x9c\x4f\x42\x5d\x85\xb1\x9a\x21\x4f\xb1\ \xd7\x63\xbb\x04\x8b\xe4\x9d\x0d\x79\x06\x48\x63\x93\x32\x0c\x3b\ \xe8\xf5\x03\x36\x01\xcc\x84\x67\x18\x96\x26\xf5\x24\x91\x0f\x18\ \x1a\xd9\x0e\xd8\x0d\xe3\x0c\xf6\xee\x49\xfa\xff\x9e\x86\x3c\xd4\ \xa7\x1c\xd8\xca\x0f\xd9\xc3\xe1\x89\xda\xe3\x45\xaa\x55\x47\xb4\ \xd2\xa2\x75\x1f\xd1\x11\x79\x19\x78\x07\xc7\x54\x6a\x4c\x6d\x95\ \xac\xe9\x6a\x45\x94\x9e\xb0\xc5\xdf\x5b\xb8\x2a\x55\x87\xd5\xd1\ \x7b\x4a\xf5\x75\x5f\x62\xd8\x8e\xa5\x77\x6c\xf5\x37\xa4\xde\x12\ \xd4\x72\xb1\x37\xa0\x17\x90\x35\x9a\x16\xf7\x77\x81\xa9\x21\x29\ \x55\x4b\xb2\x49\x73\x96\xc7\xf7\x65\x14\x90\x8d\x9d\xb0\x1e\xc6\ \xfc\xb3\x6f\x43\xcd\xc6\xb2\x0a\x9a\xd4\xde\x5e\xe3\x6b\xbd\xa3\ \x7f\x1d\x67\xb3\x59\xe7\x7f\xca\x1f\x01\x06\x00\x05\x3b\xea\xc8\ \xfa\x24\x85\x20\x00\x00\x00\x00\x49\x45\x4e\x44\xae\x42\x60\x82\ \ \x00\x00\x69\xec\ \x89\ \x50\x4e\x47\x0d\x0a\x1a\x0a\x00\x00\x00\x0d\x49\x48\x44\x52\x00\ \x00\x01\x00\x00\x00\x01\x00\x08\x06\x00\x00\x00\x5c\x72\xa8\x66\ \x00\x00\x00\x19\x74\x45\x58\x74\x53\x6f\x66\x74\x77\x61\x72\x65\ \x00\x41\x64\x6f\x62\x65\x20\x49\x6d\x61\x67\x65\x52\x65\x61\x64\ \x79\x71\xc9\x65\x3c\x00\x00\x03\x6b\x69\x54\x58\x74\x58\x4d\x4c\ \x3a\x63\x6f\x6d\x2e\x61\x64\x6f\x62\x65\x2e\x78\x6d\x70\x00\x00\ \x00\x00\x00\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x62\x65\x67\ \x69\x6e\x3d\x22\xef\xbb\xbf\x22\x20\x69\x64\x3d\x22\x57\x35\x4d\ \x30\x4d\x70\x43\x65\x68\x69\x48\x7a\x72\x65\x53\x7a\x4e\x54\x63\ \x7a\x6b\x63\x39\x64\x22\x3f\x3e\x20\x3c\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x3d\x22\x61\x64\x6f\ \x62\x65\x3a\x6e\x73\x3a\x6d\x65\x74\x61\x2f\x22\x20\x78\x3a\x78\ \x6d\x70\x74\x6b\x3d\x22\x41\x64\x6f\x62\x65\x20\x58\x4d\x50\x20\ \x43\x6f\x72\x65\x20\x35\x2e\x35\x2d\x63\x30\x31\x34\x20\x37\x39\ \x2e\x31\x35\x31\x34\x38\x31\x2c\x20\x32\x30\x31\x33\x2f\x30\x33\ \x2f\x31\x33\x2d\x31\x32\x3a\x30\x39\x3a\x31\x35\x20\x20\x20\x20\ \x20\x20\x20\x20\x22\x3e\x20\x3c\x72\x64\x66\x3a\x52\x44\x46\x20\ \x78\x6d\x6c\x6e\x73\x3a\x72\x64\x66\x3d\x22\x68\x74\x74\x70\x3a\ \x2f\x2f\x77\x77\x77\x2e\x77\x33\x2e\x6f\x72\x67\x2f\x31\x39\x39\ \x39\x2f\x30\x32\x2f\x32\x32\x2d\x72\x64\x66\x2d\x73\x79\x6e\x74\ \x61\x78\x2d\x6e\x73\x23\x22\x3e\x20\x3c\x72\x64\x66\x3a\x44\x65\ \x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x20\x72\x64\x66\x3a\x61\x62\ \x6f\x75\x74\x3d\x22\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\ \x4d\x4d\x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\ \x6f\x62\x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\ \x6d\x6d\x2f\x22\x20\x78\x6d\x6c\x6e\x73\x3a\x73\x74\x52\x65\x66\ \x3d\x22\x68\x74\x74\x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\ \x65\x2e\x63\x6f\x6d\x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x73\x54\ \x79\x70\x65\x2f\x52\x65\x73\x6f\x75\x72\x63\x65\x52\x65\x66\x23\ \x22\x20\x78\x6d\x6c\x6e\x73\x3a\x78\x6d\x70\x3d\x22\x68\x74\x74\ \x70\x3a\x2f\x2f\x6e\x73\x2e\x61\x64\x6f\x62\x65\x2e\x63\x6f\x6d\ \x2f\x78\x61\x70\x2f\x31\x2e\x30\x2f\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x4f\x72\x69\x67\x69\x6e\x61\x6c\x44\x6f\x63\x75\x6d\x65\x6e\ \x74\x49\x44\x3d\x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x30\x43\x31\ \x42\x46\x41\x46\x35\x41\x33\x39\x32\x45\x31\x31\x31\x41\x36\x37\ \x39\x38\x32\x45\x39\x30\x31\x31\x30\x33\x32\x43\x43\x22\x20\x78\ \x6d\x70\x4d\x4d\x3a\x44\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\ \x22\x78\x6d\x70\x2e\x64\x69\x64\x3a\x43\x41\x33\x32\x31\x42\x46\ \x41\x35\x34\x30\x38\x31\x31\x45\x33\x41\x31\x35\x45\x45\x45\x33\ \x31\x41\x34\x30\x39\x34\x30\x45\x31\x22\x20\x78\x6d\x70\x4d\x4d\ \x3a\x49\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\x78\x6d\x70\ \x2e\x69\x69\x64\x3a\x43\x41\x33\x32\x31\x42\x46\x39\x35\x34\x30\ \x38\x31\x31\x45\x33\x41\x31\x35\x45\x45\x45\x33\x31\x41\x34\x30\ \x39\x34\x30\x45\x31\x22\x20\x78\x6d\x70\x3a\x43\x72\x65\x61\x74\ \x6f\x72\x54\x6f\x6f\x6c\x3d\x22\x41\x64\x6f\x62\x65\x20\x50\x68\ \x6f\x74\x6f\x73\x68\x6f\x70\x20\x43\x43\x20\x28\x4d\x61\x63\x69\ \x6e\x74\x6f\x73\x68\x29\x22\x3e\x20\x3c\x78\x6d\x70\x4d\x4d\x3a\ \x44\x65\x72\x69\x76\x65\x64\x46\x72\x6f\x6d\x20\x73\x74\x52\x65\ \x66\x3a\x69\x6e\x73\x74\x61\x6e\x63\x65\x49\x44\x3d\x22\x78\x6d\ \x70\x2e\x69\x69\x64\x3a\x39\x31\x66\x35\x61\x38\x61\x34\x2d\x36\ \x31\x62\x36\x2d\x34\x66\x34\x62\x2d\x62\x38\x61\x38\x2d\x32\x31\ \x61\x66\x32\x62\x30\x37\x63\x64\x31\x38\x22\x20\x73\x74\x52\x65\ \x66\x3a\x64\x6f\x63\x75\x6d\x65\x6e\x74\x49\x44\x3d\x22\x78\x6d\ \x70\x2e\x64\x69\x64\x3a\x30\x43\x31\x42\x46\x41\x46\x35\x41\x33\ \x39\x32\x45\x31\x31\x31\x41\x36\x37\x39\x38\x32\x45\x39\x30\x31\ \x31\x30\x33\x32\x43\x43\x22\x2f\x3e\x20\x3c\x2f\x72\x64\x66\x3a\ \x44\x65\x73\x63\x72\x69\x70\x74\x69\x6f\x6e\x3e\x20\x3c\x2f\x72\ \x64\x66\x3a\x52\x44\x46\x3e\x20\x3c\x2f\x78\x3a\x78\x6d\x70\x6d\ \x65\x74\x61\x3e\x20\x3c\x3f\x78\x70\x61\x63\x6b\x65\x74\x20\x65\ \x6e\x64\x3d\x22\x72\x22\x3f\x3e\x64\xc0\x1f\x2c\x00\x00\x66\x17\ \x49\x44\x41\x54\x78\xda\xec\x7d\x07\x80\x1d\x75\xb5\xfe\x37\x73\ \x7b\xdd\xbb\x7d\x37\xbd\x07\x12\x52\x08\x81\xd0\xa4\x13\xaa\x48\ \x49\xa4\x17\x69\x02\x8a\xe2\x53\xf9\x8b\xa0\xf2\xb0\x20\x8a\xcf\ \xf7\xf4\xd9\x50\x9f\x0a\x22\x9d\xa0\x14\xe9\x45\x29\xd2\x09\x25\ \x05\x42\xfa\x6e\xb6\xef\xbd\x7b\x7b\x99\x99\xff\x39\x67\xe6\x6e\ \x49\x93\x96\x6c\xc9\xef\xc0\xe4\xee\xde\x3b\xf7\xee\xcc\xdc\x39\ \xdf\xf9\x4e\xf9\x9d\xa3\x59\x96\x05\x25\x4a\x06\x43\x0e\x3b\xec\ \x30\x3c\xf5\xd4\x53\xbb\xdc\x79\xf3\x39\x1f\x72\xc8\x21\x43\xe2\ \x58\xdc\xea\x36\x54\x32\x58\xd2\xdd\xdd\x8d\xda\xda\x5a\xdc\x78\ \xe3\x8d\x35\x9d\x9d\x9d\x99\x1f\xfd\xe8\x47\x99\x96\x96\x96\x01\ \xfb\x5c\x75\xd5\x55\x98\x3b\x77\x2e\x72\xb9\xdc\xb0\x3b\x3f\xbf\ \xdf\x8f\xef\x7c\xe7\x3b\x58\xb1\x62\xc5\x80\xe7\x03\x81\xc0\x90\ \x39\xc6\x21\x07\x00\xf1\x78\x1c\x6f\xbc\xf1\x86\x7c\xe1\x7b\xed\ \xb5\x17\xdf\x20\x7e\xd3\x34\xab\xe9\xa5\x1a\xda\x82\xb4\x79\x69\ \xd3\x94\xfa\x0c\x7f\xd9\x67\x9f\x7d\x90\xcd\x66\x23\xc7\x1d\x77\ \xdc\x1e\xa4\xf8\x6f\xdd\x77\xdf\x7d\x8f\x13\x28\x88\xa6\xe7\xf3\ \x79\xd9\x67\xdf\x7d\xf7\xc5\xc2\x85\x0b\x91\x4e\xa7\x87\xdd\xf9\ \x85\x42\x21\xfc\xec\x67\x3f\xdb\xe2\xf9\x17\x5e\x78\x01\xd3\xa7\ \x4f\x47\x2c\x16\x53\x00\xb0\xb9\xbc\xf6\xda\x6b\x38\xfc\xf0\xc3\ \x31\x7e\xfc\x78\xdc\x71\xc7\x1d\x7a\x65\x65\xe5\x78\x02\x83\xc5\ \x9a\xa6\x9d\xac\xeb\xfa\x74\x06\x01\xfa\x59\x69\xcf\x08\x90\xdf\ \xfc\xe6\x37\x02\xf4\x1d\x1d\x1d\x08\x87\xc3\xef\x90\xa5\xbf\x64\ \xe5\xca\x95\xaf\xa6\x52\x29\xd2\xff\xbc\xc9\xfb\xf0\xeb\xac\xfc\ \xc3\x11\x00\x58\x0c\xc3\xd8\xe2\xb9\xaf\x7c\xe5\x2b\x98\x35\x6b\ \x96\xdc\xe7\x83\x2d\xfa\x50\xbb\x60\x1c\x93\xf0\xf9\x7c\x78\xf0\ \xc1\x07\x7d\x0b\x16\x2c\x38\x90\x6e\x80\x2f\xd0\xd3\x27\x91\xd2\ \x4f\xa4\xcd\x4f\x9b\x0a\x5a\x8c\x10\xc9\x64\x32\xe8\xe9\xe9\x01\ \x31\x3c\xfe\xde\x77\x3f\xf5\xd4\x53\x7f\x70\xd8\x61\x87\x1d\x44\ \xca\xee\x25\x9a\xec\xe2\x7d\xbc\x5e\xef\x88\x3c\x77\x97\xcb\xa5\ \x5c\x80\xad\x09\x23\xfe\x0d\x37\xdc\xa0\xcf\x9c\x39\x73\x36\xdd\ \x08\x5f\x72\xbb\xdd\x9f\x76\x68\xbf\x92\x11\x26\x0c\xf6\xac\xfc\ \x72\x23\xba\xdd\xfa\x98\x31\x63\x3e\x75\xde\x79\xe7\x7d\xd3\xe3\ \xf1\x58\xf7\xdf\x7f\xff\xb3\xe4\x1e\x64\xd7\xad\x5b\x67\x1d\x75\ \xd4\x51\x02\x16\xc3\x4d\x98\xa9\x0e\x75\xb6\xaa\x0f\xc5\x83\x9a\ \x30\x61\xc2\x34\x7a\x38\x91\x28\xff\xd1\x4a\xf9\x77\x1d\x30\x60\ \x65\xd9\x7d\xf7\xdd\x0f\xba\xe4\x92\x4b\xbe\x73\xf0\xc1\x07\xef\ \x53\x53\x53\x13\xf8\xc6\x37\xbe\xa1\xdd\x79\xe7\x9d\x20\x57\x10\ \x2a\x63\xb5\x8b\x00\x40\xb1\x58\x3c\xd1\xa1\xfd\x21\xf5\x15\xed\ \x02\x37\xa1\xae\xf7\x5a\x4b\xfe\xb9\xb1\xb1\x71\xff\x2b\xaf\xbc\ \xf2\xfb\x8b\x16\x2d\x3a\x98\x18\xa1\xe7\xa2\x8b\x2e\xd2\x96\x2c\ \x59\x82\xea\xea\xea\x01\x96\x75\x38\x6c\x43\x5d\xdc\x43\xf4\x86\ \x38\x84\x1e\xa6\x2b\xd5\xd8\x35\x99\x00\xb9\x00\x20\x77\x60\xff\ \x53\x4e\x39\xe5\xca\x52\xa9\x64\xdc\x7a\xeb\xad\xff\xfc\xdc\xe7\ \x3e\xc7\xd9\x01\xeb\xe4\x93\x4f\x96\xf4\xa1\x92\x11\x0c\x00\xb0\ \xd3\x7d\xba\xfa\x7a\x76\x0d\xd9\x9a\xa5\xe4\xe7\x76\xdb\x6d\xb7\ \x43\xce\x3f\xff\x7c\xcf\xc6\x8d\x1b\xbf\xf1\xf4\xd3\x4f\xbf\x7a\ \xe1\x85\x17\x72\x6e\xd0\x24\x60\x40\x57\x57\xd7\x90\xb7\xb0\xc3\ \x81\x01\x0c\x55\x25\x53\xce\x9e\x02\x05\x71\x07\x46\x8f\x1e\x7d\ \xc0\x35\xd7\x5c\xf3\x7d\xb2\xfc\xfb\x16\x0a\x05\xf7\x05\x17\x5c\ \xa0\xdd\x7b\xef\xbd\xa8\xaa\xaa\x52\x17\x69\x04\x33\x00\x25\xbb\ \x38\x03\x28\x0b\xbb\x03\x13\x27\x4e\x3c\xe8\xec\xb3\xcf\xbe\x8a\ \x00\xe0\x7b\x0f\x3e\xf8\xe0\xcb\x65\x77\x80\x99\xc0\x50\x76\x07\ \x14\x03\x50\xa2\xe4\x13\x88\x09\xb0\x22\xcd\x9e\x3d\xfb\xc8\x2b\ \xae\xb8\xe2\x3f\xf7\xd9\x67\x9f\x39\xf4\xb4\x97\x98\x80\xce\x4c\ \x80\xb3\x03\x4a\x14\x00\x28\x19\xc6\xd6\xff\x83\x44\xd2\xd9\x1d\ \x18\x37\x6e\xdc\xc1\xdf\xff\xfe\xf7\x7f\xf0\xd9\xcf\x7e\x76\x3f\ \x62\x03\x2e\x62\x02\x3a\x67\x07\xd8\x1d\x50\x99\x00\xe5\x02\x28\ \x19\x81\x2e\x40\x7f\xf1\x7a\xbd\xda\xe4\xc9\x93\x0f\x3d\xe7\x9c\ \x73\x8a\xf4\xeb\xf5\x77\xdd\x75\xd7\x8b\xf4\x73\x8e\x58\x82\xb5\ \x68\xd1\xa2\x21\x17\x18\x54\x2e\x80\x12\x25\x3b\xc0\x1d\x98\x35\ \x6b\xd6\x42\x76\x07\x0e\x3a\xe8\xa0\x3d\x43\xa1\x90\xef\xa2\x8b\ \x2e\xd2\x09\x0c\x54\x60\x50\x01\x80\x92\x91\xea\x06\xf4\xa7\xd3\ \x1c\x18\x6c\x6c\x6c\xfc\xd4\xb5\xd7\x5e\xfb\xbd\xe3\x8e\x3b\x6e\ \x41\x36\x9b\x75\x9d\x7f\xfe\xf9\x7a\x39\x3b\xa0\xe8\xff\x08\x71\ \x01\x54\xe9\xe7\xc8\xb7\xe8\x1f\x85\x2a\x3b\x0b\xc6\xb4\xa9\x53\ \xa7\xb2\x3b\x90\x8b\xc7\xe3\xdf\x7d\xf4\xd1\x47\x5f\xa7\x9f\xb9\ \x4e\x60\xc8\xb8\x03\xca\x05\x50\xa2\x64\x07\x01\x7c\xd9\x1d\xd8\ \x73\xcf\x3d\x8f\xb9\xfa\xea\xab\xaf\xdb\x7b\xef\xbd\x67\xea\xba\ \xee\x3d\xef\xbc\xf3\xf4\xbb\xef\xbe\x5b\xb9\x03\x0a\x00\x94\x8c\ \x44\x17\x60\xf3\xcd\xed\x76\x63\xd2\xa4\x49\x47\xdc\x70\xc3\x0d\ \x3f\xf8\xcc\x67\x3e\xb3\x57\xa1\x50\xd0\x89\x09\xe8\xf7\xdc\x73\ \xcf\x90\x71\x07\x94\x0b\xa0\x44\xc9\x0e\xa2\xca\xcc\x04\xb8\x67\ \xc0\x8c\x19\x33\x16\x9e\x7b\xee\xb9\x05\xfa\xfd\x07\x8f\x3d\xf6\ \xd8\x1b\x67\x9d\x75\x96\x14\x0b\x2d\x5e\xbc\x78\xd0\xdc\x01\x15\ \x03\x50\xa2\x64\x27\x29\x0a\x7f\xc6\x3e\xfb\xec\x73\x7c\x5d\x5d\ \x5d\xa0\xad\xad\xed\xaa\x57\x5e\x79\xe5\x4d\x02\x84\x22\x3d\x6f\ \x0e\x16\x08\xa8\x18\x80\x12\x25\x3b\xd3\x9a\x91\x3b\x30\x66\xcc\ \x98\x43\xaf\xbf\xfe\xfa\xef\x9f\x71\xc6\x19\xfb\x95\xdd\x01\x95\ \x22\x54\x0c\x40\xc9\x10\xf7\xff\x3f\x09\x61\x77\xc0\xef\xf7\xeb\ \xd3\xa7\x4f\x3f\xf2\x94\x53\x4e\x29\x90\xd5\xcf\x3f\xf1\xc4\x13\ \x4b\xc9\x1d\xc8\x72\x2b\xb9\x9d\xcd\x04\x94\x0b\xa0\x44\xc9\x4e\ \x96\x72\x76\x60\xaf\xbd\xf6\x3a\xae\xba\xba\x3a\xd0\xd4\xd4\x74\ \xe5\x6b\xaf\xbd\xf6\xd6\xd9\x67\x9f\x5d\x32\x49\x4e\x3d\xf5\x54\ \xd5\x4f\x40\xb9\x00\x4a\x46\xba\x70\xb1\xd0\xb8\x71\xe3\x0e\xbd\ \xe1\x86\x1b\xbe\x7b\xf2\xc9\x27\xef\xcd\xee\xc0\xb9\xe7\x9e\x2b\ \xee\x80\x6a\x2f\xa6\x18\x80\x92\x21\xe6\x06\xec\x08\x26\xc0\xc5\ \x42\xb3\x67\xcf\x3e\xe6\x82\x0b\x2e\xb0\x7a\x7a\x7a\xfe\xf3\x9f\ \xff\xfc\xe7\x9b\x67\x9e\x79\x66\x7e\x67\xb9\x03\xaa\x29\xa8\x12\ \x25\x43\xc0\x1d\xd8\x73\xcf\x3d\x8f\xbd\xee\xba\xeb\x7e\x30\x7f\ \xfe\xfc\x59\x4c\x0e\xce\x3a\xeb\x2c\x15\x18\x54\x00\xa0\x64\x57\ \x01\x01\xc7\x1d\x38\xec\xfb\xdf\xff\xfe\xf7\x88\x01\x48\x76\xe0\ \x8c\x33\xce\xe8\x75\x07\x94\x0b\xa0\x44\xc9\x08\x73\x01\xb6\xe6\ \x0e\xec\xb6\xdb\x6e\x0b\xcf\x3e\xfb\x6c\x83\xe4\xfa\x7b\xef\xbd\ \xf7\x55\x02\x81\x2c\x9c\x62\x21\x1e\x49\x37\xdc\xce\x4b\x31\x00\ \x25\x4a\x3e\x04\x08\x70\x53\x91\x59\xb3\x66\x1d\xf5\xb5\xaf\x7d\ \xed\xba\x03\x0f\x3c\x70\xb6\xcb\xe5\xf2\x96\xdd\x01\x9e\xd3\xb7\ \x2b\x06\x06\x15\x00\x28\xd9\xa5\x84\xeb\x04\x1a\x1b\x1b\x0f\xfe\ \xf6\xb7\xbf\x7d\xed\x79\xe7\x9d\x27\x9d\x85\x88\x09\x68\xbb\xaa\ \x3b\xa0\x5c\x00\x25\x23\xde\x05\xd8\x9c\x09\x10\x08\x68\x33\x67\ \xce\x3c\x8a\xa8\xbf\xd9\xda\xda\xfa\xdd\xa7\x9e\x7a\xea\x0d\x02\ \x81\x1c\x67\x07\x78\x29\x71\x22\x91\x50\x2e\x80\x12\x25\x23\xdd\ \x1d\x98\x3b\x77\xee\x31\xc4\x04\xbe\xb7\x60\xc1\x82\x59\xf4\x9c\ \xe7\xcc\x33\xcf\x14\x77\xa0\xa2\xa2\x62\x97\x71\x07\x14\x00\x28\ \xd9\x65\x41\x80\x57\x11\x8e\x1d\x3b\xf6\xd0\xab\xaf\xbe\xfa\xda\ \x73\xce\x39\x47\xdc\x81\xd3\x4f\x3f\x5d\xfa\x09\x70\x4c\x40\xb9\ \x00\x4a\x94\xec\x04\xfa\x3f\x58\x54\xb9\x9c\x1d\x98\x33\x67\xce\ \x31\x04\x00\x56\x73\x73\xf3\x75\xaf\xbf\xfe\xfa\x5b\x04\x02\xec\ \x0e\xc8\x04\x22\x1e\x5f\xae\x5c\x00\x25\x4a\x46\xb8\x3b\xb0\xc7\ \x1e\x7b\x1c\xcd\xab\x08\xf7\xdf\x7f\xff\xd9\xa6\x69\xba\xd8\x1d\ \x60\x26\x10\x8d\x46\x47\xb4\x3b\xa0\x00\x40\xc9\x90\x61\x01\x83\ \xd9\xb1\x87\xb3\x03\xec\x0e\x5c\x71\xc5\x15\xd7\x9c\x75\xd6\x59\ \x0b\xf2\xf9\x3c\xbb\x03\x32\x86\x8c\x63\x02\x1f\xe7\x38\x15\x00\ \x28\x51\x32\x0c\x98\x00\xb9\x03\xfa\x9e\x7b\xee\x79\xdc\x79\xe7\ \x9d\xf7\xff\x0e\x3b\xec\xb0\x39\xc1\x60\xd0\xc7\x31\x01\x06\x81\ \x48\x24\xa2\x18\xc0\xce\xfc\x32\xca\x8f\x6a\x1b\xf9\xdb\x50\x63\ \x23\xb3\x67\xcf\x3e\xf6\x86\x1b\x6e\xf8\x1e\xb9\x05\x33\xb8\x6c\ \x98\x41\xe0\xcd\x37\xdf\x14\x10\x18\x69\xee\x80\x62\x00\x4a\x94\ \x6c\x26\xec\x0e\x4c\x9a\x34\x69\xe1\x75\xd7\x5d\xf7\x9d\x4f\x7f\ \xfa\xd3\xd2\x68\xf4\xca\x2b\xaf\xd4\x96\x2e\x5d\xca\x2c\x61\x44\ \x9d\xab\xca\x02\x28\x19\x12\x56\x77\x08\xba\x03\xda\x82\x05\x0b\ \x4e\xf8\xf2\x97\xbf\x6c\xb5\xb7\xb7\x5f\xfb\xe4\x93\x4f\xae\x58\ \xb4\x68\x51\x9e\x40\xc0\x62\x10\x20\x50\x18\x76\xe7\xa5\x18\x80\ \x12\x25\x1f\x02\x04\x58\x81\xe7\xcd\x9b\x77\xc2\xcf\x7e\xf6\xb3\ \x1f\x1c\x78\xe0\x81\x33\x57\xad\x5a\xe5\xda\x7b\xef\xbd\xf5\xe5\ \xcb\x97\x23\x1c\x0e\x8f\x08\x77\x40\x01\x80\x12\x25\xff\x86\x09\ \x4c\x9e\x3c\xf9\xa8\xab\xae\xba\xea\x9a\x33\xcf\x3c\x73\xc1\xb2\ \x65\xcb\xdc\x5f\xff\xfa\xd7\x35\x8e\x09\x8c\x04\x77\x40\xb9\x00\ \x4a\x06\x9d\xfe\x0f\x65\xaa\x5c\xce\x0e\xec\xb7\xdf\x7e\x27\x7a\ \xbd\x5e\x7d\xfd\xfa\xf5\xec\x0e\x2c\x27\x26\x90\x7f\xf9\xe5\x97\ \xad\xd9\xb3\x67\x23\x9d\x4e\x2b\x17\x40\x89\x92\x91\x2c\x2e\x97\ \x8b\xb3\x03\xc7\xfd\xe4\x27\x3f\xf9\xde\x21\x87\x1c\x32\x93\xcb\ \x86\x2f\xbc\xf0\x42\x9d\x03\x83\xa1\x50\x48\xb9\x00\x4a\x94\x8c\ \x74\x77\x20\x10\x08\xb8\xa6\x4e\x9d\x7a\x0c\xb9\x00\x57\x1f\x7b\ \xec\xb1\xf3\x88\x01\xb8\xbf\xf5\xad\x6f\x69\xab\x57\xaf\x96\xae\ \x43\xca\x05\x50\xa2\xe4\x23\xba\x01\xc3\x05\x04\xc8\x0d\xd0\x3e\ \xf5\xa9\x4f\x9d\x44\x8f\xee\x8d\x1b\x37\x5e\xf3\xcc\x33\xcf\xac\ \xe4\x91\x64\x0f\x3f\xfc\xb0\xc5\x4c\x80\xdd\x81\xe1\x72\x3e\x8a\ \x01\x28\x51\xf2\x11\x01\x6b\xde\xbc\x79\xc7\xdf\x74\xd3\x4d\xd7\ \x93\x5b\x30\xe3\xd9\x67\x9f\x75\x2d\x58\xb0\x40\x5f\xb2\x64\xc9\ \xb0\x73\x07\x14\x00\x28\x51\xf2\x11\x98\x00\x67\x07\x66\xcc\x98\ \x71\xec\x35\xd7\x5c\xf3\xed\x45\x8b\x16\xcd\x7f\xe7\x9d\x77\xdc\ \x5f\xfd\xea\x57\xb5\xb7\xde\x7a\x0b\xc1\x60\x50\xb9\x00\x4a\x94\ \x8c\x64\x31\x4d\x53\x66\x11\x1e\x78\xe0\x81\x27\xfa\xfd\x7e\x57\ \x57\x57\xd7\xb5\xcf\x3f\xff\xfc\xb2\x93\x4f\x3e\x39\x7f\xef\xbd\ \xf7\x5a\xb3\x66\xcd\x52\x0c\x40\x89\x92\x0f\x43\xab\x87\xdb\xc6\ \x52\xce\x0e\xdc\x78\xe3\x8d\xd7\x1f\x7d\xf4\xd1\x73\xb8\x58\x68\ \xfe\xfc\xf9\xfa\x7d\xf7\xdd\xa7\x00\x40\x89\x92\x0f\x42\xa7\xb9\ \xac\xb6\x54\x2a\x0d\xdb\xe3\x27\xca\x2f\x6b\x07\x2e\xbb\xec\xb2\ \x6f\x72\xb1\x10\x9d\x8f\x7b\xf1\xe2\xc5\xda\xc3\x0f\x3f\x3c\xe4\ \x57\x11\x2a\x17\x40\xc9\xa0\x5b\xfd\x6c\x36\x2b\x74\x9a\xcb\x6b\ \x87\xab\x3b\xc0\x55\x81\x07\x1c\x70\xc0\x09\x04\x06\xee\x35\x6b\ \xd6\x7c\x6b\xe9\xd2\xa5\xec\x0e\x14\x02\x81\x80\xa9\x18\x80\x12\ \x25\xdb\x00\x00\xee\xc6\x53\x66\x00\xc3\x29\x7d\xb6\x35\x26\xe0\ \x74\x16\x3a\xe6\xe7\x3f\xff\xf9\x0d\x07\x1d\x74\xd0\x1c\x02\x36\ \xbd\xab\xab\x4b\x57\x00\xa0\x44\xc9\x36\x00\x80\x2d\x3f\x6f\xc5\ \x62\x51\x98\xc0\x70\x77\x67\xb8\xe5\xf8\xb4\x69\xd3\x8e\xf8\xea\ \x57\xbf\x7a\x0d\xb9\x01\xfb\xd0\x39\x32\xcb\x1e\xb2\xc8\xe6\x1e\ \xaa\x17\xb2\xff\xa3\x92\x91\x2b\x6c\x35\x49\x69\x90\x4a\xa5\xd0\ \xdd\xdd\x2d\x03\x3b\xf9\xf7\xe1\x0c\x02\x5c\x15\xb8\xff\xfe\xfb\ \x1f\x4f\xee\x80\x97\x18\xc0\xb7\x5b\x5b\x5b\xdf\xde\xb0\x61\x43\ \x36\x91\x48\x0c\x39\x77\x40\x31\x00\x25\x83\x0e\x00\xac\x30\x9c\ \x3b\x67\x46\xd0\xde\xde\x0e\x52\x18\xa9\xa8\x63\xdf\x7a\xb8\x82\ \x80\x93\x1d\x58\xf8\xd3\x9f\xfe\xf4\xbf\x2e\xbf\xfc\xf2\x23\x08\ \xd8\xc2\x43\x91\x09\xa8\x20\xa0\x92\x41\x17\x56\x96\xf2\xd2\xda\ \x64\x32\x89\x7c\x3e\x2f\x3d\xfb\xf9\x39\x76\x0f\x86\xab\xf0\xf1\ \x8f\x19\x33\x66\xbf\x99\x33\x67\x5e\x1c\x0a\x85\x5a\xe9\xa9\xd7\ \x68\x2b\x32\x46\x28\x00\x18\x06\xfe\x29\x6f\x43\xb1\x6f\xdd\x48\ \x92\x72\xe3\x0d\x4d\x23\x26\x40\x4a\xcf\x69\xb3\x5c\x2e\x27\x40\ \xd0\xd1\xd1\x21\xc1\xc1\xe1\x7a\xfd\x19\xd8\x78\x23\x10\x58\x18\ \x0e\x87\x1f\xa1\xa7\x56\xd3\xc6\x73\xc7\x0a\x43\x05\x04\x14\x00\ \x6c\x83\x96\x66\x73\x59\xc4\xe3\x5d\xa8\xa9\xae\x13\x8a\x3a\x5c\ \xe9\xe8\x50\x55\x7a\xd3\x32\x85\x11\x9b\x0c\x00\xd0\x9c\x8c\x80\ \x0b\x1e\xb2\x9a\xac\x19\xa6\x69\xc1\xa0\x6b\xce\xfb\xf2\x63\xa1\ \x58\x14\xfe\xec\xf5\x78\x69\x3f\xda\x97\x14\x0b\x43\x1c\x18\xf8\ \x3e\xe2\xc5\x43\x95\x95\x95\x6e\x02\x82\xc9\xf4\xd4\x24\xda\xde\ \xa7\xad\x8b\x36\x43\x01\xc0\x50\x55\xfe\x6c\x06\xad\x6d\x9b\xc4\ \x22\xad\x5d\xbf\x1a\x0d\xf5\xa3\x10\x09\x47\xe9\xa6\x34\xd4\x05\ \xfa\x98\x8a\x5f\x32\x0c\xa6\x57\xf0\xb8\x49\x81\xc9\xea\xbb\x49\ \x87\x4b\x06\x59\x79\x52\x72\x83\x40\x81\x15\x5f\x7c\x68\x0f\xb9\ \x05\x08\xc2\x4d\xdf\x81\x2c\xc5\xa5\xf7\xb1\xba\xeb\xf4\x5e\x2f\ \x01\xb2\xcf\xef\x87\x6f\x18\x2c\xc1\x65\x60\x73\xe2\x1b\x8d\xf4\ \xeb\x78\xda\xda\x68\x8b\x2b\x00\x18\xa2\x94\x8d\x2d\x7f\xf3\xa6\ \x8d\x18\x3b\x66\x1c\x2a\x2a\x2a\xd1\xd1\xd9\x86\xb5\x6b\xdf\x47\ \x5d\xdd\x28\xd4\xd6\xd6\xcb\x8d\xaa\x5c\x82\x0f\x2f\x6c\xc5\x99\ \x45\x31\x9b\x62\x90\xe5\xeb\x58\x2a\x96\x60\x90\xf2\x97\x5f\x33\ \xd8\xea\xf3\xef\xa4\xec\x86\xc3\xb8\xf8\x3b\x61\xcb\xaf\xd1\xfb\ \x5c\xcc\x10\xbc\x9c\x36\xf4\xa0\xa5\xb3\x1b\x95\x91\x30\x2a\xa3\ \x43\xbf\x55\x37\xc7\x31\x08\x00\xb8\x24\xb0\x8a\xb6\x00\x86\x50\ \xf0\x5d\x01\x40\x3f\xcb\xcf\x69\xa8\xa6\xe6\xf5\x18\x37\x7e\x3c\ \xdc\x74\xc3\x15\x8a\x05\x71\x01\xfc\xbe\x20\x56\xbc\xfb\x0e\x52\ \xa9\x24\xc6\x8f\x9f\xd8\x1b\x1b\x50\xf2\xc1\x95\x9f\x85\xd3\x7b\ \xcc\xa2\x8a\x85\x22\x59\x7b\x52\xf2\x52\x59\xf1\x0d\x9b\xf2\x93\ \xf2\x0b\x43\x70\x8a\x6a\xca\xdf\x0b\xf1\x67\x04\x03\x41\x7a\xbf\ \x0f\x89\x54\x0a\xab\x37\x6c\x44\x4f\x3a\x23\xaf\x57\x0e\x9f\x81\ \x1d\xac\x6b\x4c\x59\x5c\x43\xea\xbe\x57\xb7\x67\x3f\x00\x20\x9f\ \xff\xe9\xa7\x9e\x96\x14\x54\x8e\x98\x00\x6f\x0c\x02\x5c\xa2\x3a\ \x67\xd6\x3c\x14\xf3\x79\xbc\xfd\xf6\x52\x29\x5a\x61\xcb\xa4\xe4\ \x83\xd1\x7e\xcd\xa1\xed\x25\x52\xf8\x62\xa9\x24\x20\x60\x5b\x7d\ \x43\x14\x9e\x2d\x3e\x07\xfb\x8a\x04\x00\x9a\x28\xbf\x4b\xde\xe3\ \x21\x4b\xcf\xd7\xbe\xb6\xa6\x06\x9a\x4b\xc7\xd2\x15\xef\xe2\x1f\ \x2f\xbd\x8a\xa6\x96\x56\x04\xbc\x3e\x54\x47\x23\xea\x02\x2b\x00\ \xf8\x64\x84\x6f\xc0\x29\x93\xa7\x62\xf7\xdd\x67\xe0\x81\xfb\x1f\ \x20\x25\x2f\x48\x34\x3a\x93\xc9\x08\x08\x30\x75\x9d\x33\x77\x2f\ \x72\x0b\x62\x78\xf5\xf5\x97\x88\x2d\x74\x0d\xeb\x14\xd5\x4e\x74\ \x82\xe5\x3a\x95\xc4\xba\x93\xe5\x37\x08\x04\x18\x00\x8a\x86\xfc\ \x6c\x98\x44\xf9\x4b\xc4\x0a\x08\x04\x24\x18\x48\x40\xcc\x41\xbe\ \x50\x20\x40\x8a\x5f\x8d\x00\xb1\x86\x37\x57\xbe\x8b\x25\x0f\x3f\ \x8e\xd7\xde\x5e\x46\x6c\x40\xc7\xd4\x09\xe3\x31\x73\xca\x24\xc4\ \xa2\x61\x58\x50\x4c\x4c\x01\xc0\x27\x08\x02\x47\x1c\xb1\x50\x82\ \x36\x4f\x3c\xf9\x04\xdd\x8c\x16\x72\xf9\x2c\xb2\x04\x02\x0c\x08\ \x2c\xbb\x4d\x9f\x81\x69\x53\x77\xc3\x1b\x4b\x5f\xc3\xba\x75\x6b\ \xca\xfe\x9d\xba\x78\xdb\x61\x56\xa2\xe0\xb4\x99\x6c\xed\xf9\xb1\ \x64\x08\xed\x2f\x99\xf6\x73\x45\x62\x03\xa4\xf3\x12\xe0\x73\xe9\ \x6e\x54\xc7\x2a\x11\xa3\xed\xbd\xf5\x1b\x70\xcb\x7d\xf7\xe3\xef\ \x4f\xfe\x03\xe9\x6c\x16\xd3\x27\x4d\xc0\xbe\x73\xe7\x60\xf2\xb8\ \xb1\xf0\x79\x3d\xe2\x36\x28\x51\x31\x80\x4f\x94\xae\xf2\x76\xd2\ \x49\xa7\xe0\x77\xbf\xbb\x09\xaf\xbe\xf6\x1a\xe6\xce\x99\x8b\x4c\ \x2e\x03\x5b\xc7\x35\x61\x02\x63\x46\x8f\x45\x24\x1c\xc1\x0b\x2f\ \x3e\x87\xae\x78\x37\x66\xed\x31\x47\xc5\x05\xb6\x61\xfd\xd9\x42\ \xb3\x95\xb7\x7a\x7d\x7d\x93\x14\x9f\x23\xfe\xf4\x0a\x53\x7f\x93\ \x5d\x04\x4b\xea\x00\xd8\x4d\xa8\xae\xaa\x42\x73\x7b\x07\x1e\x7f\ \xee\x5f\x58\xf1\xfe\x6a\xf8\x3c\x6e\xcc\x9c\x3a\x05\x7b\xcf\xda\ \x03\x63\x1a\xea\xa1\xbb\x34\x61\x0e\x4a\x14\x03\xd8\x31\x01\x2b\ \xba\x29\xc3\xa1\x30\x16\x2f\xfe\x2c\xfe\xf5\xc2\x8b\x58\xbb\x6e\ \xad\xe4\xac\x33\x4e\x4c\x80\x5f\x67\x61\x57\xe0\xb0\x43\x8f\x44\ \x9e\xdc\x84\x17\x5e\x78\x4e\x18\x82\x62\x02\x9b\x29\x3f\xe1\x21\ \x5b\x7c\xa1\xfa\xb4\x99\x42\xf9\xed\xc0\x9f\x55\xb2\xa3\xff\xbc\ \x93\x4b\x94\xdf\x0d\xaf\xcf\x87\xbf\x3d\xf5\x0c\x7e\x78\xd3\x1f\ \xf0\xec\xab\xaf\xa3\xbe\xa6\x0a\xc7\x1f\x76\xb0\x6c\xe3\xc7\x8c\ \x92\x42\x5a\xa5\xfc\x0a\x00\x76\xb8\x70\x90\x8f\xd3\x80\xc7\x1c\ \x7d\x0c\x1e\xf9\xfb\x23\x88\xc7\xe3\x44\x61\x8b\xe2\x0e\xe4\xf3\ \xb9\x5e\x4b\xcf\x45\x29\x07\x1f\x74\x28\x1a\x1b\x1a\xd1\x93\xec\ \x51\x00\xd0\xab\xfb\xe5\x0a\x4a\xd3\x49\xe9\x31\x08\x14\x9d\x9f\ \x2d\x3b\xf2\x2f\xc5\x40\xa4\xfc\x9c\x12\xa4\xf7\x04\xc9\xe7\x5f\ \xdb\xd4\x8c\xbb\x1f\x7e\x02\x01\x9f\x17\x27\x1e\x79\x28\xce\x39\ \xf1\xd3\x98\x3f\x6b\xa6\x13\x40\x2c\x29\x86\xa5\x00\x60\xe7\x09\ \xd7\xa3\xef\x35\x6f\x3e\xf6\x9c\x3b\x17\x0f\xff\xfd\xef\x62\xe1\ \x19\x18\x72\x04\x00\x85\x42\x7e\xc0\xbe\x93\x26\x4d\x42\x28\x18\ \x52\x37\x68\x2f\x02\x00\xec\x9e\x8b\xa2\x1b\xe5\x60\x1f\xa7\xf9\ \x2c\x71\x05\x4c\xd3\x2e\xf8\xd1\x9d\x0a\x40\x4d\x40\xb7\x84\xa0\ \x3f\x80\x86\xda\x6a\x9c\x7e\xdc\xd1\xf8\xf4\xc1\x9f\x42\x2c\x1a\ \x95\xe7\x55\x15\xa6\x02\x80\x41\x11\x6e\x54\xb1\x70\xe1\x31\x08\ \x91\x4b\xf0\xd8\x63\x8f\x43\xd3\x35\x61\x02\x0c\x06\xa6\xd1\x57\ \xc8\xe5\x72\xb9\x7b\x63\x08\xca\xfa\xdb\x65\xbc\x96\xe9\x58\x7e\ \xd3\xa6\xfe\x6c\xed\xc9\xe6\x4b\xea\x8f\x5f\xe7\xe8\x80\xcb\xa5\ \xf7\x32\x06\x06\xd7\x48\x28\x88\xc6\xda\x1a\x79\xe4\xfd\x0d\x43\ \x55\x5e\xee\x92\x00\x50\x0e\xc6\x0d\xf6\x26\x96\x87\x74\x7a\xf1\ \xa2\xc5\xe8\xee\xe8\x04\xb7\x7c\x0e\xd1\xcd\x69\x95\xef\x74\x47\ \xbc\x5e\x8f\xfc\x5a\xce\x14\x0c\x95\xe3\x1f\x9c\x0d\x92\xdb\x17\ \xeb\x2f\x91\x7f\xbb\xc4\xd7\x32\xcc\x5e\x40\xe0\x8b\xea\xee\x57\ \x47\xc1\x1c\x80\x9f\x0f\x07\xfc\x72\x2d\x57\xad\xdf\x38\xe2\xae\ \xa3\x02\x80\x61\x2a\x9c\xbf\xe6\x75\x00\x8b\x16\x2f\xc6\xf3\xcf\ \x3d\x87\x0d\xeb\x36\xc0\xe7\xf3\x4b\x8d\x00\xc7\x06\x78\x2b\xd1\ \x8d\x1e\xab\xa8\x14\xea\x5b\x2a\x16\x76\xe9\xeb\x25\x96\xde\xa1\ \xf8\x25\xc3\x49\xf5\x95\x4c\x94\x2c\xdb\x0d\xb0\x1c\xbf\xbf\xbf\ \xf2\xf3\xff\xd2\x52\x4b\xd3\x51\x55\x51\x81\x8e\xee\x6e\x01\x84\ \x8f\x1a\x51\x51\xb1\x98\x0f\x2e\x2a\x0d\xf8\x01\x5d\x81\xf1\xe3\ \x26\xe2\xa8\xa3\x8e\x96\x78\xc0\xb8\xf1\xcb\xc4\xd2\x75\xc7\xbb\ \xc1\x6b\x3a\x8e\x38\xe2\x08\x4c\x18\x3f\x19\x15\xd1\x18\x7a\x92\ \x09\x29\x69\x2d\xbb\x05\xbb\x1c\x00\xb0\xf5\x77\x16\xfd\xf4\xd6\ \xf8\xc3\x74\xd8\x94\x6d\xf9\xcb\x0a\x5a\x56\xfe\xb2\xef\x50\x20\ \x7f\x7f\x5c\x63\x23\x5e\x7e\xeb\x6d\x64\x09\x60\xfd\xce\x42\xa0\ \x0f\x05\xd8\xa5\x12\xf2\x85\xa2\x94\x0d\xf7\x07\x1a\x25\x0a\x00\ \x3e\x76\x50\x70\xee\x9c\x79\xa4\xe8\x13\xe5\x67\x7f\x20\x80\x9e\ \x9e\x1e\xfc\xf9\xb6\x3f\xe3\xa5\x57\x5e\x94\xe2\xa1\xba\x9a\x06\ \x44\x89\x2d\xa4\xd2\x49\xf1\x75\xb9\xa4\x75\x97\x63\x4c\x8e\xf5\ \xb7\xd3\x7f\xf6\x66\x3a\xe5\xc0\xe5\x85\x3d\x5b\x28\xbf\xf3\x8c\ \x69\x19\xa8\xaf\xae\x44\xa2\x27\x89\x54\x26\x83\x00\x29\x31\xf9\ \x0f\x1f\x28\xea\x28\x6b\x0c\xe8\x6f\x32\x33\xeb\x49\xa5\x88\x91\ \x55\x10\x73\x0b\x0d\xf9\x25\xc3\xca\x05\x18\x46\xc2\x37\x33\xe7\ \xff\xeb\xeb\x49\xd1\x23\x51\x4c\x24\x30\x38\xe5\xa4\x45\x78\xe5\ \x95\xa5\x78\xf2\xa9\x27\xd1\xda\xbe\x89\x6d\xa0\x14\x09\x71\x39\ \xeb\xae\x16\xbd\x96\xb8\x09\xf9\xfa\xec\x02\x14\x39\xed\x27\xa9\ \x3b\x88\xd5\x77\xeb\xfa\x76\x95\x9f\x6f\x44\x8e\x11\x48\x1c\xc0\ \xe3\x46\x53\x6b\xbb\xb8\x04\xff\x8e\xea\xdb\x73\x05\xf2\xc8\x66\ \x73\x28\x12\x53\x2b\x4a\x65\xa1\x25\xeb\x0a\x54\xf6\x40\x01\xc0\ \x27\x4f\x71\x9d\xd4\x16\x3f\xe6\xe9\xc6\x9b\xb1\xdb\xee\x38\xfb\ \xcc\x73\xf0\xca\xab\x6f\xe0\x89\xa7\x1e\x17\x10\x90\x80\x56\x28\ \x22\x51\x6e\xcb\xda\x35\x6e\x42\x56\xc6\x32\xe5\x2f\x95\x8a\x12\ \x17\xb1\x78\x1d\x80\x6b\xa0\xe2\x6f\x4d\xf9\x9d\x22\x4b\x49\x17\ \xf2\x22\x9f\xa3\x0f\x3a\x10\x95\xb1\x8a\x0f\xa0\xf8\x05\xe9\x24\ \xcc\x8f\xd2\x44\x84\xfe\xe5\xc5\x46\xd2\x67\xc0\xed\xb6\x1b\x8a\ \xa8\xb5\x02\x0a\x00\x76\xb4\x6b\xb0\xfb\x6e\xbb\xe1\x73\xe7\x7e\ \x0e\xaf\xbd\xfa\x16\x1e\x7d\xec\x51\xb4\xb5\x37\x8b\xf5\x0b\x06\ \x43\x12\x0b\xd8\x15\xd2\x83\xac\x94\x12\xfd\xb7\x9c\xee\x3d\xa4\ \xd0\x6e\x6d\xcb\x60\xdf\xb6\x94\xbf\x0c\x0e\xac\xcc\x53\xc7\x8c\ \x42\x7d\x65\x0c\x19\xa2\xf3\xe5\xd9\x01\xe5\xb8\x41\x7f\xc5\xe7\ \x6b\x2f\xeb\x01\x9c\xd7\xb8\x66\x80\x19\x80\xdb\xa5\x09\x8b\x30\ \x9c\x2c\x8e\x12\x05\x00\x3b\x1c\x04\xa6\x4f\x9f\x8e\xf3\xcf\x3b\ \x1f\x6f\x2c\x7d\x07\x8f\x3c\xfe\x28\x5a\xca\x20\x10\x08\xc2\xe5\ \x76\x8d\x78\x10\x90\xd6\x5d\x6c\xf5\x2d\x3b\xe7\x2f\xf4\xbd\xac\ \xec\x16\xb6\xd2\x0f\x77\xa0\xf2\xf7\x43\x12\x64\xf3\x05\xa4\x33\ \x59\x59\x89\xd9\x93\x4c\x4a\x93\x16\xd3\x61\x17\xac\xf8\x39\x51\ \x7c\xb3\xfc\x66\x79\x64\xd0\xe1\x20\x62\x89\x58\x04\x57\x68\xf6\ \xae\xcd\x50\x19\x01\x05\x00\x3b\x05\x04\x72\x79\x4c\x9b\x36\x0d\ \x17\x9e\x7f\x21\xde\x5c\xba\x0c\x8f\x0a\x08\x6c\x94\xda\x80\x80\ \x3f\x20\x94\x74\xa4\x82\x00\x2b\x1b\x5b\x62\x56\xc2\x62\xd1\x10\ \xe5\xef\xd3\x3b\xad\xb7\x77\x42\xf9\xfc\xed\x1e\x80\x5b\x2a\x3f\ \x3f\x57\x6e\xc6\xca\x31\x14\x51\x62\xfa\xdc\x7c\xae\x80\x54\x3a\ \x8d\x0c\x29\xbf\x9d\x1e\xec\x73\x25\x98\x00\xc8\xdf\x25\xb0\x2d\ \x39\x8b\x8d\x82\x7e\x1f\x4a\x45\x43\x90\x47\xa9\xbf\x02\x80\x9d\ \xca\x04\xa6\x4e\x99\x4a\x20\x70\x11\xde\x7a\x6b\x39\x1e\xfa\xfb\ \xc3\x04\x02\x4d\xb2\x0e\x9e\xd7\xb5\x7b\x3c\xee\x11\x0b\x00\x85\ \x52\xc1\x29\x84\xb2\x06\x18\x5d\x17\x47\xff\x89\x01\xb9\xe9\xdc\ \x03\x92\x9a\x73\x6d\xce\x01\x7a\x95\xbf\x4c\x13\x34\x6d\xe0\x67\ \x73\x05\xa6\x66\x23\x48\xef\x7b\x4c\x27\x66\x20\x81\x3f\x2e\x17\ \x36\x2c\xb1\xfe\xbc\x4c\xd8\xe5\xd6\x05\x0c\xf8\x6f\x29\x00\x50\ \x00\x30\x08\x20\x30\x05\x9f\xbf\xf0\x62\xac\x5c\xf1\x1e\xee\x7f\ \xe0\x01\x6c\x6a\x6d\x92\x12\x62\xbf\x6f\x84\x82\x00\x69\x59\x8e\ \xac\xb4\xbe\xb9\xcf\xcf\x15\x7e\x96\x6d\xb1\x3d\x2e\x0f\x51\xf7\ \xa2\xa4\xe8\x6c\x85\xde\xbe\xf2\xf7\xb7\xf2\xfd\x83\x88\xcc\x21\ \xf8\x33\xd9\xe2\x73\xf9\xb0\xd4\x1b\x58\xf4\xb3\x65\x08\x00\x70\ \x23\x11\x0e\xd2\x5a\xfd\x16\x1a\x29\x51\x00\xb0\xd3\x41\x60\xd2\ \xa4\xc9\xb8\xe4\xf3\x97\xe2\xfd\xf7\xd7\xe2\xbe\x25\x4b\xb0\xa9\ \x65\x83\x80\x80\xcf\xeb\x95\x9e\x02\x23\xc9\xfa\x17\x0b\xb6\x32\ \xb2\x62\xf7\xc6\x04\x34\xbb\xf6\x3f\x14\x0a\x21\x12\x0e\x4b\xc6\ \xa4\xb9\xb5\x45\x4a\xa9\x3d\xd2\x49\xc9\xda\xae\xe5\x07\xfa\x5c\ \x7c\xcd\x21\xf3\x5c\x63\x20\xd5\x85\xe5\xa6\x22\x96\x5d\x66\xcc\ \x15\x86\x5c\x03\xc0\xbd\x03\x78\xe5\x60\x81\x8e\x87\xd3\x8e\xaa\ \x10\x48\x01\xc0\xa0\x82\xc0\xf8\x71\x13\x70\xd9\x25\x97\x61\xfd\ \x86\x66\xdc\x75\xcf\x3d\x68\x12\x10\x28\xd9\x20\xe0\x1d\x19\x20\ \xc0\x2d\xbc\x32\x32\xd4\xb3\xbf\x7f\x6f\x07\xe0\x22\xa1\x30\x42\ \xc1\x00\xda\x3a\xda\xb1\x76\x43\x13\xc6\x8f\x1d\x2b\x1d\x7d\xb9\ \xa1\xa7\xee\x72\x8b\x9f\xbf\x55\xda\xdf\xdf\xec\xf3\xda\x02\xd3\ \x4e\xef\xf1\xc6\x81\x55\xae\x35\x28\x95\xab\x0c\x65\x6e\x00\xe4\ \x39\xfe\x5b\xec\x8a\xb0\xab\xc0\xd7\x58\x95\x04\x2b\x00\x18\x54\ \xe1\x02\x95\xb1\x63\xc6\xe2\x8b\x97\x7d\x11\x2d\xad\x1d\xb8\xf3\ \xce\xbb\xb0\xb1\x79\x1d\x3d\x9f\x23\x6b\xe5\x95\xf1\x57\xc3\xfa\ \xe6\x21\xe5\x2f\x4a\xf4\xbd\xdc\x0c\xa5\x4f\x71\xd9\x1d\xc8\x93\ \x6f\xbe\x7e\x63\x33\xd6\x35\x35\x63\xd2\xf8\xf1\xe2\x26\xbc\xb5\ \x6c\x85\xd4\x09\xb0\x75\xe6\x36\x5f\x76\xe0\x6f\x4b\xe5\x17\xaa\ \xcf\x81\xc5\x92\xdd\x30\xb4\x5c\x51\xc8\x0a\x5f\x5e\x57\x50\x32\ \xec\x25\xc6\xcc\x0a\x82\x01\x3f\x5c\x2e\x8d\x80\xb7\x28\x1d\x9d\ \x3d\x6e\xb7\x5a\x9d\xa9\x00\x60\x28\x80\x40\x41\x1a\x86\x7c\x89\ \x40\xa0\xb3\x33\x8e\xdb\xef\xbc\x93\x40\x60\xbd\xf4\x15\x60\xba\ \xca\x29\xab\xe1\x2c\xdc\x41\xb9\xbc\x90\x87\x8b\x7e\xf4\x7e\xb4\ \xdb\x20\x70\xc8\xe7\x0b\x98\x4c\xca\xcf\xb1\x8f\xd5\xeb\xd7\x63\ \xca\x84\x71\xb4\x8d\x17\xd6\xc0\xa9\xbe\xfe\xeb\x02\xfa\x16\x06\ \x41\xfc\x79\xc3\xa9\x2b\x30\xca\x0d\x44\x7a\x7b\x09\x38\xe5\xc6\ \xce\x92\x61\x06\x93\x50\xd0\x2f\xeb\x07\x64\x10\x87\xdf\xa7\xac\ \xff\x70\x07\x80\x91\xb4\x14\x94\x41\xa0\xb6\xb6\x8e\x98\xc0\x65\ \x48\xc4\x93\xb8\xe3\x6e\x9b\x09\x64\xf3\x59\x59\xfe\xca\x31\x81\ \xe1\x76\x4e\x9c\xda\x4b\x67\x32\xe4\xdb\x17\x6c\x6b\x4b\xff\xa5\ \xb3\x39\x02\xb6\x82\x53\xb8\x63\xdf\x5a\x95\xb1\xa8\x44\xff\x79\ \xbf\xe9\x13\x27\x60\xdc\xa8\x51\x88\x27\x7a\xb0\xb1\xa5\x45\x62\ \x03\x76\x43\x90\x3e\x67\x9f\x95\xbb\x4c\xf5\x0d\x67\x5a\x50\x7f\ \xe5\x37\x9c\x91\x61\x76\x97\x21\x3b\xd8\x17\x8b\x46\x48\xf9\xf3\ \x28\x30\x13\xf0\xf9\xe0\xa5\xe3\x31\x9d\x01\x2e\x6a\x39\xb0\x62\ \x00\x43\x42\x98\x2a\xd7\xd6\x10\x08\x5c\xfa\x05\xf4\xf4\xa4\x71\ \xdb\xed\x77\x60\x43\xd3\x5a\x69\x33\xc6\x53\x64\x87\x93\x3b\xe0\ \x76\xbb\x08\xbc\x72\x02\x00\x7c\xdc\xf1\x64\x0a\xef\xae\x5d\x8f\ \x35\x4d\x9b\xb0\x81\x14\xbb\xad\x2b\x6e\xa7\xec\x9c\x68\x7f\x81\ \x68\x79\xa1\x50\x94\x02\x9e\xf7\xd7\xaf\xc3\xb2\xf7\x56\xa1\xa6\ \xaa\x52\xea\xfe\x2d\xa9\xe4\x73\x18\x83\x94\x11\x9b\xce\x8a\x42\ \xfb\x77\xa6\xf8\xa6\x69\x39\xb3\x02\x1d\xe5\xb7\xd0\x1b\x03\xe0\ \xe5\xc3\x05\x72\x29\xb2\xf4\xd9\x3e\xb7\x17\xe1\x60\x40\x51\x7f\ \x05\x00\x43\x17\x04\x6a\x6a\x6a\x71\x39\x81\x40\xbe\x50\xc2\x9f\ \xff\x7c\x1b\xd6\x6d\x78\x9f\x7c\xe3\x8c\x80\x80\x6f\x18\x80\x00\ \x5b\x7e\xb6\xf2\xc9\x64\x9a\x2c\xad\x07\x9d\xf1\x04\xd6\x35\x6f\ \x12\x1a\x5e\x11\x0a\x4a\x1a\x8e\xb3\x1d\x09\xc7\x35\x60\xdd\x66\ \x1a\xef\x71\xeb\x52\xb0\x93\x22\xda\x3f\xa6\xa1\x81\x14\x37\xea\ \x94\xf1\xc2\xd9\xc7\x92\xe8\xbe\x58\x76\xfa\x9d\xfd\x7c\x06\x87\ \x5e\x17\xa0\xbc\xb1\xf2\x17\x4b\x72\x2c\xdc\x3e\x8c\xf7\x4f\xa6\ \xd2\xb2\xe0\x28\x16\x09\x0f\x70\x41\x94\x28\x00\x18\x92\x20\x50\ \x55\x55\x83\x2f\x5c\x72\x99\xd0\xdf\x9b\x6f\xf9\x0b\x56\xaf\x7b\ \x8f\x40\x80\x14\xca\xe7\x1d\xd2\x20\xc0\xca\x25\xca\xdf\x93\x14\ \x16\xd0\x1e\x8f\xa3\xa9\xb5\x15\xb5\x95\x95\xa4\x8c\x35\xb2\x80\ \x27\x1a\x0a\x91\x65\x0f\xd8\xc5\x41\xa4\xa8\x52\x05\x4c\x1a\xce\ \x00\x51\x15\x8b\x61\x6c\x63\x83\x44\xeb\xb9\x70\xc7\xbe\xf9\xec\ \x02\x1e\x1e\x17\x66\xf7\x0e\x70\x56\x14\x3a\x9d\x84\x0c\xa3\x2f\ \x06\xc0\xfb\x71\x00\xd1\xef\xf7\x62\x14\x29\x3f\xbb\x1c\xdd\x74\ \x2c\x9c\x4d\xa8\x22\x37\xe0\xa3\xf4\x0f\x50\x00\xa0\x64\x50\x40\ \xa0\x32\x56\x29\x29\x42\x9f\x2f\x80\x3f\xfd\xe9\xcf\x58\xb5\xfa\ \x5d\x64\xb2\x69\x69\x8d\xed\xf3\x79\x81\x21\x56\xc3\xc6\x2b\x1b\ \xf3\x74\xdc\x3d\x69\x52\x7e\x8f\x0b\x1d\x9d\xdd\xa4\xfc\x6d\x68\ \xa8\xa9\x46\x4d\x65\x0c\x01\x3e\x6e\x9e\xda\xeb\xf5\xc8\xf1\xfb\ \x69\x73\xf1\xd0\x14\xe9\xfb\x67\xb7\x08\x37\x1d\xbf\x5d\x14\x9c\ \x9e\xe0\x81\x20\x9c\x29\xc8\x16\x0a\x02\x16\xec\xc3\x97\x0a\x86\ \x3c\x72\x1c\x80\x33\x00\x85\x72\xfa\x8f\x6b\xfc\xbd\x6e\x34\x54\ \x57\xc9\x50\xd0\x76\x62\x1e\xcc\x3e\xb8\xd2\xb0\x86\xae\x65\x38\ \x18\x54\xca\xaf\x00\x60\x78\x81\x40\x45\x24\x86\x4b\x3f\x7f\x09\ \xa2\xd1\x0a\xfc\xf1\xe6\x5b\xf0\xee\xaa\x15\xe4\x57\x27\xc5\xaf\ \xf6\x49\x9d\xc0\xd0\x00\x01\xb6\xde\x39\x52\x52\x6e\x7d\xee\xd1\ \xc9\xf2\x93\x8f\xdf\xd4\xd1\x81\xc6\x3a\xb2\xfa\x15\x31\xbb\x42\ \xaf\x37\xd8\xa5\x49\x9f\x7f\x2e\xc4\xf1\x90\xf2\x33\x10\x30\x5b\ \xe8\xbf\x2c\x8f\xfd\xf7\x24\x59\xef\x78\x3a\x43\x2e\x41\x8e\x3e\ \xbb\x88\xbc\xe1\x4c\x0f\x92\xfd\x2c\xc9\x1a\x70\x40\x2f\x16\x89\ \xa0\x8e\x00\xa6\xb1\xa6\x0a\x15\xe1\x10\x3a\xba\xba\xb0\x62\xf5\ \x1a\x7a\xec\x96\x7d\x6a\x09\x10\xa2\x21\xa5\xfc\x1f\x39\x9e\xa3\ \x2e\xc1\x20\x82\x00\xd1\x59\xee\x1b\x70\xc9\x45\x9f\xc7\x6f\xff\ \xef\xf7\xb8\xf9\xe6\x5b\x71\xe6\x99\xa7\x61\xda\x94\xe9\x88\x84\ \xa2\xc2\x9d\x39\x8d\x36\x98\x6b\x5a\x7b\x95\x3f\x95\x22\xe5\x77\ \xa3\xa3\x3b\x61\x2b\x3f\x59\xfe\x4a\x02\x2e\x5b\xf1\xb6\x3c\x3e\ \xcb\x71\x19\x3c\x6e\xaf\xf8\xf2\x9c\xcb\x07\xec\x74\x1f\x7f\x26\ \x2b\x37\xbb\xeb\xb6\xde\xd2\xb3\x2e\x9b\x25\x70\x47\x1f\x66\x1b\ \xc2\x08\x8a\x05\xa4\xd3\x29\x49\x17\x76\xf5\xf4\x88\xaf\xcf\x90\ \x18\xab\x88\x12\xf8\xd4\x62\x54\x5d\x9d\xe4\xff\x2d\xd5\xf8\x43\ \x01\xc0\x70\x15\x56\x8c\x40\x30\x8c\x8b\x2e\xb8\x10\xbf\xff\xc3\ \xef\xf1\xe7\x5b\xff\x82\x33\x4e\x3b\x15\xd3\xa7\xed\x8e\x68\xd8\ \x6e\x8a\x31\x58\x20\x50\x56\xfe\x24\x2b\xbf\x8b\x68\x3f\x51\xee\ \xe6\xf6\x76\xa1\xfd\x55\xd1\xe8\x76\x15\x8f\x15\xdd\xed\x72\x8b\ \x95\xe6\x61\x2a\xe5\xe7\xec\x71\xdf\xa4\xe0\x74\x4e\x5d\xf1\x38\ \xda\xbb\xe3\xe8\xa4\x8d\x15\x9c\x0b\x85\xb8\x38\x48\xe6\x2f\xd0\ \x75\xe1\xa5\x3c\x6e\xb7\x2e\xc1\xc6\x68\x38\x8c\x7a\xf2\xfb\x59\ \xe9\x79\x44\x58\x55\xac\x42\x66\x09\xaa\xae\x3f\x0a\x00\x86\xbd\ \x70\xce\x3b\xe0\x0f\xe1\x82\xf3\x2e\xc0\x1f\x6f\xf9\x23\x6e\xb9\ \xf5\x36\x9c\x7e\xea\x62\xcc\xd8\x7d\x96\xb8\x09\x36\x08\xe4\x77\ \xb2\xcf\xef\x92\xdc\x7d\x4f\x92\x94\xdf\xcd\xca\x4f\xb4\xbf\xad\ \xa3\x4f\xf9\xad\xed\xf7\xda\x61\xda\x1f\x20\xeb\x5c\x94\x25\xc2\ \x45\xbb\x50\x88\x9e\x63\x9a\xbf\x7e\x53\x8b\x04\x0f\xbb\x08\x50\ \xf2\x64\xe5\x79\xd5\x5e\xd0\xe7\x47\x45\x28\x6c\x67\x05\x68\x5f\ \x8b\x1e\x3d\x04\x20\x95\xd1\x08\x5d\x83\x08\xb9\x1a\x11\x62\x45\ \x21\x04\xfd\x7e\x61\x46\x52\x17\xa0\x68\xbf\x02\x80\x11\x03\x02\ \x06\x81\x40\x20\x88\xcf\x9d\x73\x1e\x6e\xfe\xcb\x9f\x71\xeb\x5f\ \xee\xc0\xa9\xa7\x1a\x98\x3d\x73\x8e\x80\x00\xaf\x83\xe3\xd5\x74\ \x3b\x83\x09\x94\x95\x3f\x41\x3e\x3f\x5b\x6b\xb6\xd2\x2d\x1d\x65\ \xe5\x8f\x08\x6f\xdf\xe6\x51\xd0\x0b\xbc\xfc\x97\x2d\x36\x2b\x69\ \x92\x00\x84\xb3\x00\xcc\x04\x92\x44\xe5\x37\x34\xb7\xa0\x2b\x11\ \x97\xc6\x21\x13\xc6\x8e\x46\x6d\x55\x25\x7d\x66\x85\x2c\x97\xe6\ \xa2\x28\xbd\xdc\x3b\x50\x1b\x78\xaa\xe2\x68\x94\x95\x5e\x29\xbe\ \x02\x80\x91\x09\x02\x06\xfc\xfe\x20\xce\x3d\xf3\x1c\xdc\x7e\xe7\ \x6d\x04\x02\xb7\xa3\xb4\xa8\x80\x3d\xe7\xce\x97\x66\xa4\x7e\xd2\ \x8a\xdc\x0e\x76\x07\xf4\x5e\xcb\x9f\x84\x5b\x7c\xfe\x38\x36\x75\ \x76\xd8\x69\xbe\x70\x44\xfe\xf4\xb6\xd4\x9f\x59\x01\x57\x35\x72\ \x47\x5e\x56\x70\xee\x9a\xcc\x2d\xd1\xb8\x45\x77\x82\xdc\x88\x96\ \x8e\x4e\xa9\xdb\xaf\x23\x20\x19\x55\x5b\x8b\xea\xca\x98\xdd\x2c\ \xc4\x99\x13\x58\xbe\x06\x4a\x14\x00\xec\xd2\x20\xc0\x83\x47\xce\ \x38\xed\x0c\x49\xa3\xdd\x76\xc7\xdd\xa2\x34\x7b\xcd\xdb\x9b\x68\ \x70\x15\xfc\x9a\x8f\x7c\xe5\xfc\x0e\x01\x01\x56\xfe\x82\x43\xfb\ \xd9\xff\x6f\xef\xee\x46\x4b\x67\x27\x1a\x49\x59\x63\x64\xd1\xb7\ \x67\xf9\x59\x7f\x45\xf9\x63\x51\x69\xd3\x93\x24\x00\xe1\xb5\x0e\ \x3e\x7f\x00\xdd\x3d\x09\x74\x27\x7a\xc4\xc2\x57\xd1\xeb\x75\x95\ \x95\x52\xef\xa0\xc6\x7f\x29\x00\x50\xb2\x0d\x10\xf0\xb8\x7d\x38\ \x6d\xf1\xa9\xb2\x6c\xf8\x8e\xbb\xee\x95\x8c\xc1\x3e\xf3\x17\x90\ \xd5\xac\x15\x8b\xca\xd1\xf2\x4f\x96\xf6\xeb\xbd\x96\x9f\x7d\x72\ \x2e\xe7\x6d\x25\xe5\x1f\x55\x67\x2b\xff\xf6\x7d\x7e\x4b\x94\x9b\ \xa3\xf3\x9c\xe3\x4f\xa6\x53\x52\xd9\xc8\x0d\x50\xda\x89\xee\xf7\ \x70\xa5\x9e\x9b\xfd\xf9\x28\x62\x91\x90\xf0\x7b\x43\x05\xef\x14\ \x00\x6c\xf3\x76\x1a\x06\x8b\x28\x76\xb4\x94\x64\xba\x90\x07\xa7\ \x7c\xe6\x64\x89\xa6\xdf\xbb\xe4\x7e\xc9\x18\x2c\xd8\x7b\x5f\xd4\ \x54\xd5\x13\x08\xd8\xe3\xc9\x3e\x89\x6b\xc4\x3e\x7b\x39\xe0\xc7\ \x91\x75\xb6\xfc\x6d\x5d\xdd\x42\xd3\xff\x9d\xf2\xf3\xf3\xbc\xa2\ \xd1\x56\x7e\xbb\x2c\x97\x47\x7d\xfb\xe8\xf8\x38\x65\x98\xcd\xe4\ \x84\x19\x54\xd2\xe7\xd8\x75\xfa\xd8\x65\x5a\xa5\x6f\x7e\x3f\x2b\ \x00\x50\xf2\xa1\x99\x80\x4e\x7e\xf8\x09\xc7\x9f\x20\xe5\xae\x7f\ \xbb\xff\x21\x01\x81\xfd\x16\xec\x8f\xfa\x9a\xc6\x4f\x04\x04\xec\ \x80\x5f\x51\x82\x75\x1c\x80\xeb\x8c\xdb\x96\xbf\x4c\xfb\xb7\x17\ \x69\xe7\xbf\xcb\x96\xbf\x92\x94\x9f\x6b\xf2\x53\xac\xfc\x74\x4c\ \x7e\xa2\xfd\x9c\xd6\xe3\x05\x43\x1c\xfc\xe3\x69\xbf\x21\x7a\x5e\ \x15\xeb\x28\x00\x50\xf2\x21\x85\x23\xe9\x2e\x02\x81\xe3\x8e\x39\ \x5e\x2c\xf5\x43\x7f\x7f\x54\xca\x62\x0f\xd8\xef\x00\x34\xd4\x35\ \x4a\xf4\x3c\xfb\x11\x41\x80\x3f\x8f\x1b\x6a\xb2\xbf\xce\xd5\x7b\ \x9d\xf1\x1e\xb4\x74\x74\xa3\xa1\xba\x06\x15\x8e\xe5\xc7\xf6\x2c\ \x3f\xf9\xf1\xbc\x14\x97\x2d\x7f\x2a\x95\x12\xc5\x0f\xf0\xc8\x34\ \x02\x02\x0e\x56\xb2\xe5\x0f\x93\xbb\xc2\x65\xc2\x4a\xf9\x15\x00\ \x28\xf9\x18\x20\xe0\x26\x77\xe0\xe8\x23\x8f\x11\xff\xfc\x91\x47\ \x1e\x95\x95\x75\x87\x1c\x74\x30\x1a\xeb\x46\x4b\xbe\x9d\xfb\xe5\ \x7f\x18\x1d\x63\xcb\xcf\xab\xef\x12\x64\xa9\x99\xf6\x77\x26\x12\ \xd8\xd4\xd1\x85\xfa\xea\x2a\x54\x90\x52\x5b\xff\xc6\xf2\x7b\xca\ \x3e\x3f\x59\x7e\xae\x12\xe4\x3c\xbe\x28\x3f\xf7\x04\x20\x96\xc2\ \x01\xc0\x80\xcf\x03\x9f\xea\xcc\xa3\x00\x40\xc9\x27\x07\x02\x47\ \x1e\xbe\x50\x94\xeb\x6f\xf7\x3f\x28\x2b\xe8\x8e\x38\xfc\x70\x02\ \x81\x51\x0e\x13\xc8\x6f\x55\xd9\x98\xda\xf3\x56\x6e\xa0\xa1\xbb\ \x02\xb2\x08\xa7\x27\xd9\x05\xb7\x28\x7f\x0f\x36\xb5\x77\xc8\xf2\ \x5a\xae\xbd\xdf\x6e\xb4\x9f\xeb\xf4\xc9\xf2\xf3\x72\x5e\xfe\x3c\ \x51\x7e\xb1\xfc\x7e\xf4\x48\x5d\x7f\x5e\x32\x08\x01\x02\x08\xaf\ \x4b\x75\xe5\x55\x00\xa0\xe4\x13\x07\x81\x43\x0e\x3e\x4c\xfa\xec\ \xdf\x7b\xef\x5f\xc5\x8a\x2f\x5c\x78\x24\x46\x11\x08\x70\xf0\x8d\ \xc7\x69\xf5\x2f\xd1\x95\xf5\xfb\xf4\x5c\x47\x7b\x3b\x6a\xeb\x1b\ \xe0\xf3\x85\x01\x63\x25\xb2\x69\x1e\xdf\x35\x1a\x1d\x89\x36\xb4\ \x76\x74\xa2\xa1\xa6\x86\xe8\x3c\xa7\xf0\xcc\xed\xa6\xfa\x78\xc9\ \x72\x2c\x5a\x21\x41\xca\x54\x32\x25\xeb\xff\xfd\xc1\x00\x92\x99\ \x0c\x29\x7f\x49\x29\xbf\x02\x00\x25\x3b\x23\x26\x70\xe0\xfe\x07\ \x49\x9d\xc0\xdd\x77\xdf\x23\x6b\xe4\x8f\x3a\xea\x28\x8c\x69\x1c\ \x6b\x33\x81\x6c\x4e\x22\xed\xec\x83\xf3\xda\xfd\x3f\xdc\xf2\x27\ \xbc\xfa\xc6\x9b\xd8\x7b\xcf\xbd\x71\xe9\x67\x4b\x08\xe5\x7f\x01\ \x7f\x60\x22\x56\xe5\xbe\x8d\xe6\xf6\x20\x46\xd7\xb1\xcf\x1f\xd9\ \x6e\x6d\xbf\xad\xfc\x76\x2a\x4f\x94\x9f\x2d\x7f\x28\x28\xa9\xbe\ \x64\x3a\x2b\x2b\xfa\x94\xf2\x2b\x00\x50\xb2\x13\x41\x60\xbf\xbd\ \xf7\x93\x01\x9c\x5c\x27\xc0\x9d\x73\x8e\x3e\xea\x68\x8c\x69\x18\ \x8b\x60\xd0\xdf\x1b\xdc\xfb\xe5\x6f\x7e\x85\x17\x49\xf9\x03\xc1\ \x08\x1a\x83\x77\xc0\x6b\xa4\x01\xcd\x07\x57\x6a\x29\xea\xbd\x3f\ \x47\xa1\xe1\x3b\x64\xc5\xab\xe8\x53\x0b\xdb\x55\x7e\x8f\xd7\x2d\ \xab\xff\x98\xf6\xb3\xe5\x0f\x06\x6d\xe5\x4f\x64\xec\xe9\xbc\xba\ \x52\x7e\x05\x00\x4a\x76\x36\x08\x78\x30\x7f\xfe\x02\x59\x1c\xc3\ \x73\x07\x78\x38\xe7\xd1\x47\x2d\xc4\x94\x49\xd3\x45\x6b\x59\xf9\ \x1f\xff\xe7\x73\x88\x56\xd4\xe3\xcc\x23\xd7\xe1\x94\x63\x8b\x30\ \xbc\x7b\xc2\xcc\xb4\x03\x49\x03\xb1\xe2\x73\x70\x55\x3e\x84\xb6\ \xfc\x05\xb4\xfb\x36\xd6\x19\x38\x01\xbf\x01\xa9\x3e\xa2\xfc\x9c\ \x82\xec\x21\xe5\xe7\xfa\x01\x65\xf9\x15\x00\x28\x19\x0c\x10\x20\ \xab\xcf\xc5\x42\xf3\xf6\x9c\x4f\x20\x60\x11\x08\xdc\x2b\xad\xb8\ \xdc\x47\xbb\x71\xcb\xad\x77\xe0\xaf\x7f\x7f\x04\xbe\x60\x0d\x4e\ \x5d\xd8\x84\x53\x16\x76\xc1\x4a\x73\xcd\x7d\x0f\x11\x80\x4a\x68\ \xa5\x06\x18\xa4\xcc\xa1\xcc\x6d\x08\xf9\xe7\x21\x9d\xdf\x13\xba\ \x96\x42\xff\x26\x24\x76\x9e\xbf\x7f\x91\x4f\x4a\x06\x9d\x72\xba\ \xcf\x0e\xf8\x29\xe5\x57\x00\xa0\x64\x50\x85\xfd\x76\x8f\xc7\x87\ \x3d\x67\xef\x25\xfe\xff\x43\xa4\xf4\x57\x5d\xfd\x6d\xbc\xb9\x72\ \x15\x2c\xbd\x02\x17\x2f\xee\xc2\x39\x9f\xe9\x81\x55\xd0\xa5\xa8\ \x47\xcb\x6e\x80\x15\xdd\x0d\xf0\xd7\x13\x08\x24\x01\xfa\x3d\xe6\ \xbd\x19\x39\xd7\x74\x52\x72\x37\x01\x88\xd1\xe7\xf3\x7b\x9d\x85\ \x3d\xac\xfc\x44\xfb\x39\xcd\xc7\xee\x05\xd3\x7e\xa5\xfc\x23\x43\ \x54\x4b\xb0\x11\x02\x02\xa1\x50\x54\xa8\x7f\x57\x57\x1c\xcf\xbe\ \xf4\x3a\x7a\xd2\x6e\x7c\x7e\x51\x06\x9f\x3f\x2d\x49\x96\x1f\x28\ \xf5\x14\x61\x66\x8b\xd0\x8a\x69\x1b\x04\x3c\x11\x58\x81\x46\x98\ \xee\x0a\xf8\xd2\x4f\xa1\xc2\xfd\x20\x4c\x2d\x28\x6e\x80\x58\x7e\ \x0f\xf9\xfc\xa4\xfc\x9c\xe7\x4f\xa4\x92\x42\xfb\x79\xeb\x49\xe7\ \x24\xdd\xa8\x94\x5f\x31\x00\x25\x43\x44\x38\xda\x9f\xcb\x66\xf0\ \x3f\xff\xfb\x0b\x2c\x79\xf0\x51\x64\x4b\x7e\x7c\xf3\xec\x3c\xae\ \x38\x8f\xdc\x84\xa4\x07\x85\x44\x09\x16\xbd\x6e\x15\x73\xd0\xe8\ \x1b\x77\x57\x11\x10\xb8\x43\xb0\x7c\xc4\x02\x02\x04\x10\xc9\x95\ \x88\x14\x6e\x45\xca\xbd\x1f\x72\xc5\x06\x52\x6c\x43\x2c\x3f\x57\ \x1c\x72\x1f\x40\xee\xe2\x1b\x08\x06\xd1\x93\xca\x22\xcb\x15\x7e\ \xdc\xec\x83\x94\xdf\xad\xa6\xef\x2a\x00\xd8\x21\x16\x4d\x2d\x06\ \xfa\xc0\xc2\x79\x7e\x4e\xc9\xfd\xf8\x27\x37\xe2\x57\xbf\xff\x13\ \x32\x45\x2f\xae\xbb\x3c\x80\xff\x77\x29\x5d\xbf\x6c\x10\xc5\xbc\ \x9f\x76\xca\x12\x4a\x98\x76\xff\xfd\x5c\x06\xc5\xf6\x14\xbc\xee\ \x35\xd0\x6a\x08\x04\x42\x63\x09\x18\x7a\xe0\xca\x2c\x47\x2c\x7a\ \x07\xba\xfd\x57\x21\x16\x71\x89\xe5\x4f\x92\xe5\x0f\x05\x82\x92\ \xe7\x4f\x48\xaa\x2f\x2f\x2d\xba\x02\x1e\x47\xf9\xd5\xf7\xf3\x81\ \xef\x67\xe5\x02\x28\xd9\x61\xd6\x7f\xc9\x92\x25\xf8\x9f\x9f\xff\ \x0a\xa9\x8e\x1c\xbe\x75\x89\x1f\x57\x5f\xee\x81\x95\xd7\x50\x34\ \xa2\xd0\x7c\x21\x68\xde\x00\x3d\x12\xbd\xf7\x06\xa1\xf9\x83\xe4\ \x32\xe8\x30\xba\x53\xd0\x12\xef\x02\x9a\x8b\x40\x60\x02\xd1\xff\ \x08\x02\x99\x7b\x50\x13\x5a\x06\xc3\x0c\x90\xcf\xdf\x23\x3e\x7f\ \x80\x69\x7f\x2a\x23\x53\x7d\xb8\x3b\x10\x2b\xbf\x4b\xd7\x94\xf2\ \xab\x18\x80\x92\xa1\x20\x6c\xd5\x0b\x45\x1e\xa4\xe1\xc5\x37\x2f\ \xf7\xe1\xda\xaf\x04\x80\x3c\xf7\x19\x64\x7e\xe7\x23\x84\xf0\x43\ \xf3\x04\xfa\x36\x02\x01\xdd\xeb\x07\x67\xfd\x8c\x44\x0f\xf4\xd4\ \x6a\x58\xde\x18\xac\xf0\x44\xe8\xc5\x0e\x78\x12\x3f\x46\x26\xd7\ \x86\x60\x20\x26\x3e\xbf\x58\x7e\xa2\xfd\xfd\x95\x5f\x89\x72\x01\ \x94\x0c\x11\xe1\x99\x7b\x27\x9c\x70\x0a\xc6\x57\x3c\x8c\x63\x3e\ \x45\x16\xbd\xe8\x86\x41\xcf\xf1\x6c\x4e\x4d\x27\x60\xd0\x83\xd2\ \xa1\x47\x2b\x1b\x6c\x99\xc7\x6d\x92\xf6\x13\xcd\x2f\x1a\xd0\x7a\ \xda\xa1\xbb\x89\x15\x04\xc7\xd2\xef\x49\xe8\x89\xc7\x51\x59\xfd\ \x2b\x18\xd1\x6b\x91\x48\xf5\x48\x47\x5f\xee\x47\xa0\x94\x5f\x01\ \x80\x92\x21\x28\xa6\xe6\xc5\xa8\x8a\x7f\x62\xdc\xc1\xcb\x60\x21\ \x8a\x12\x6d\x9a\xa7\x00\x94\x12\xd0\x4b\x1d\x30\xfd\x51\x58\x3e\ \xee\xc2\xd3\x0f\x04\x60\xda\xd4\xdf\xca\xc3\xcc\xd3\xf3\xc9\x26\ \xe2\x82\x5e\x58\x15\xd3\x09\x18\x72\xf0\x75\xfd\x2f\xd2\x7a\x35\ \xb2\xb8\x0c\x2e\x97\x86\x80\xb7\xa4\x94\x5f\x01\x80\x92\x21\xe7\ \xbf\xb9\xc8\x8a\xf3\x0c\xbe\xcc\x13\x70\xa5\x5b\x48\xad\x4b\x44\ \xf1\x0d\x52\xf8\x28\xe0\xaa\x81\x56\x88\x43\xcf\x31\xc5\x1f\x0b\ \x8b\x5c\x01\xa9\xf4\x63\xeb\xaf\x31\x33\xd0\xa0\x95\x98\x0d\x30\ \x08\x98\xd0\x93\xeb\xa0\x85\x2d\x58\x95\xf3\xc8\x35\x78\x03\xc1\ \xf6\x6b\x51\x5d\x99\x46\x31\x74\x01\x5c\x1a\xaf\x10\xcc\xab\x0b\ \xae\x00\x40\xc9\x50\x11\x8e\xfe\x73\x20\x2e\x1e\x4f\x10\x3d\x3f\ \x01\x9e\xe8\x2a\x78\x92\x2f\x90\x01\x2f\x90\xa5\x27\x65\xf5\x90\ \x5f\xef\xad\x24\x26\x90\x24\x20\x58\x4b\xbf\xd7\x13\x08\xf8\xe8\ \x35\x0f\x2c\x8d\xa8\x3f\xd3\x01\xcd\x69\xb1\x6d\x16\x61\x15\x4c\ \x68\xe9\xf5\xd0\x82\x25\x02\x81\xbd\x60\xba\xa3\x08\x75\xdf\x08\ \xc3\x78\x17\xb9\xe8\x95\x04\x34\x93\x68\x5f\x5e\x2f\xa0\x9a\x78\ \x2a\x00\x50\x32\xf8\xca\x4f\x8f\x89\x9e\x24\x3c\xba\x85\x96\xae\ \x89\x78\x2f\xf3\x45\xcc\x69\x1c\x83\x70\xee\x61\x98\xb9\x0e\xc9\ \xf9\xc3\x5f\x45\x8a\x4f\xd6\xdb\x20\x40\x28\x36\x43\xd3\x09\x14\ \xdc\x21\x7a\x74\xf3\x0c\x5e\x9b\x0d\x94\x2c\xbb\xd5\xb7\x49\x00\ \x40\xba\xad\x65\x68\xbf\x52\x06\x56\x78\x02\x0c\x3f\xb1\x88\xf8\ \x53\x08\xe4\x96\xa1\x10\xbb\x14\x25\xdf\xb1\xe2\x66\xd8\x40\xa0\ \x9a\x7a\x8e\x08\x16\xa9\x2e\xc1\xf0\x54\xfe\x78\x4f\x42\xe2\x79\ \xf1\x54\x0a\xcd\x6d\xab\xe1\x76\x8f\x47\x5b\xf1\x2a\x74\x87\xae\ \x81\x15\x99\x49\x5f\x6c\xca\x56\xe6\x5c\x1b\xd1\x7d\x17\x41\x3d\ \x29\xbe\x11\x27\xa3\xdf\x49\xef\x23\x65\xf7\xb8\x68\xf3\x90\xcb\ \xe0\xa5\x47\x2f\xb8\x42\xc8\x2a\x71\x7a\x8f\xf6\x2d\xd2\x7e\xf1\ \xb7\xa0\x9b\x05\x58\xd5\xfb\x01\x3e\x1d\xbe\x8e\xab\x11\xe8\xbc\ \x14\xee\xd2\x53\x36\x73\x80\x0f\x43\x6d\x82\xb1\x12\xc5\x00\x76\ \x0d\xe5\x4f\x24\xc0\xf3\x73\x58\xf9\x37\xb4\xb4\xa2\xb6\xaa\x0a\ \x55\x15\xa4\x90\x96\x86\x44\xf1\x64\xe4\xbd\x73\x11\x75\xdf\x8c\ \x40\xe6\x01\x20\xd7\x0a\xd3\x60\x36\x50\x4b\x2e\x40\x98\xac\x7b\ \x8a\x3e\x83\x9b\x81\x84\x79\xf8\x1f\xbd\x87\x3f\xd3\x6d\xab\x32\ \xbb\x03\x86\xc9\xc1\x05\xfb\x0f\xa6\xd7\x49\xf7\x20\x8b\x98\x80\ \xe5\xde\x03\x7a\x7a\x29\xfc\x6d\x97\xc1\x88\x1c\x87\x42\xe8\x6c\ \x18\xfa\xee\xf4\x1e\xbe\x85\x8a\xea\xcb\x51\x0c\x40\xc9\x4e\xf1\ \xf9\x59\xf9\x1d\xcb\xbf\xa1\xb5\x4d\x94\xbf\x3a\x5a\x61\x0f\xe3\ \xf4\xb2\x4e\xa7\x90\xc9\x8f\xc1\xa6\xd2\xff\x43\x5b\xe0\x07\x28\ \x56\x1c\x48\xcf\x65\xa0\x67\xd6\x41\x2b\x24\x6c\x17\x80\x19\x80\ \x45\x0c\x82\x0b\x06\xdc\x6c\xfc\x5d\xfc\x07\xe8\x6e\x70\xcb\x2d\ \x61\x99\x9a\x6d\xdc\x75\x8f\xd0\x7d\x2d\xb3\x91\xde\xdb\x0e\x04\ \x1a\xc8\xf0\xc7\xe0\xea\xfa\x33\xb1\x81\xcb\xe0\x2f\xfe\x92\xf6\ \x5e\x43\x3b\x0e\x9d\x51\xe6\x4a\x14\x03\x18\x79\xca\xef\x94\xdd\ \xc6\x79\xd4\x16\xf1\xfe\x78\x92\x2d\x7f\x1b\x6a\xaa\x2a\x64\x50\ \x27\xfb\x02\xdc\x22\x8c\xa5\xc4\x2d\xbd\xac\xb4\x14\x02\x75\x17\ \x0f\x46\x97\x35\x03\x21\xeb\x6f\x68\xf4\xde\x01\x4f\x61\x3d\x19\ \xf8\x3a\xb2\xe8\x75\xd0\x8a\x49\x52\xee\x24\xbd\xd5\x47\xc4\x81\ \x18\x80\x9b\x14\xd8\x74\xd9\xae\xbd\x65\xd8\x6c\x40\x73\x6c\x84\ \x66\x8f\xef\x02\xbf\x87\x41\xc1\x5f\x4f\xec\xe0\x7d\x78\xcc\xdf\ \xc1\x55\xb1\x0c\x79\xdf\xa9\x28\xe1\x60\xd8\x01\x42\x55\x21\xa8\ \x00\x40\xc9\x27\x47\xd1\x48\xf9\x59\x27\x39\xe0\xc7\x74\xad\x9b\ \x94\x7f\x23\xd3\xfe\xca\x18\xaa\x2b\x62\x7d\x83\x32\x99\xbd\x5b\ \x26\x29\x78\x89\x36\x7e\x8e\xde\x65\xf5\xa0\xbb\xdb\xc2\xf2\x8e\ \x43\xd1\x58\x35\x15\x33\x6b\xef\x44\x94\x7c\x78\x33\x67\xc1\xf4\ \x35\x90\x3b\x10\xa7\x7d\x72\x04\x02\x1e\xb9\x15\x2c\xe1\x83\x9a\ \xf4\x14\x80\xcb\x6d\xc7\x05\x84\x22\xe8\x70\xc6\xf6\xda\x7f\x28\ \x10\xa0\xdd\x69\xcb\x76\x40\x4b\xbd\x05\x9f\x46\x68\xe3\x0d\x11\ \x08\x2c\x80\x94\x21\x2a\x51\x00\xf0\x71\x44\x2d\x06\xea\x53\x7e\ \x3b\xda\x6f\xb7\xee\xee\x4a\x24\xd1\xd4\xd6\x2e\x13\x75\xab\x2b\ \xa2\x65\xbd\x17\x10\xe0\x11\xdc\xac\xa3\x16\x29\xbf\x44\xf4\x69\ \xff\x54\x3a\x45\x2e\x43\x07\x02\x5e\x1d\xdd\xe9\xf1\x78\x36\xfd\ \x05\xcc\xa8\xab\xc5\x04\xcf\xdd\xb0\x4a\x1e\x58\x9e\x2a\xa2\xf6\ \xdd\x8e\xe5\x36\xd8\x89\xb0\x03\x7c\xbc\xc4\x57\xf3\xdb\xd6\x9e\ \x97\x0f\x4a\x4c\xc0\x61\x02\xbc\xd1\x71\xc1\x47\x4c\xc2\x2c\x42\ \xcb\x75\x42\xf3\x34\xc3\xab\xdf\x05\xc3\x5d\x07\xd3\x1a\xa7\x62\ \x02\x5b\xb9\x9f\x55\x0c\x40\xc9\x87\x56\x7e\xd6\xe8\x44\x32\xe9\ \x28\x7f\x0f\x36\x92\xf2\xd7\x55\x57\xd9\xca\x6f\x6d\x79\x63\x09\ \x6b\xb7\x6c\x5f\x9c\xc7\x7c\x75\x76\x25\xe0\x76\x7b\x64\x96\xa0\ \x46\x74\x3f\x9e\xc8\xe1\xc9\x65\x9f\xc6\xea\xfc\x69\x70\x15\xc9\ \x7a\x1b\x39\x58\xae\x20\xa3\x86\xf3\x09\x25\x27\xc2\xef\x95\xca\ \x40\xd9\x5c\x3e\xe9\x21\x08\xde\xcf\xc5\x96\x3f\x28\xc0\x61\x95\ \xd1\x87\x0f\x33\x4f\x20\x50\x78\x1f\x5e\xf3\xaf\x84\x15\x05\xe9\ \x52\x24\x2c\x42\xc9\xd0\xbf\xcf\xd4\x25\x18\xa2\x96\x9f\x14\x88\ \x6b\xf1\x75\xd2\x4d\xee\xdb\xbf\xb1\xb5\x1d\x0d\xd5\xd5\xb6\xcf\ \x6f\x6d\xdd\xd3\x66\x95\x63\xbd\x0b\xf3\x2a\x3e\x9f\x4f\xca\x78\ \x79\xe8\x27\xaf\x17\xc8\xe4\xf2\x64\x9d\x33\xa8\x8c\x78\xd1\x66\ \x7c\x01\xb9\xd0\x69\xd0\x73\x76\x09\x70\x2f\xb5\x97\x0f\x71\x91\ \x2b\xe0\xe9\x03\x00\x0e\xf0\x69\x5e\x9b\x0d\xb8\xbc\xb0\x08\x00\ \x34\x66\x0c\xdd\x2b\xc8\x7b\x48\xd3\x73\x21\x3b\x6d\x98\xeb\x82\ \xd7\x78\x11\x5a\xfa\x56\x64\x32\x19\x3a\x07\x97\x03\x62\x4a\x14\ \x00\x28\xf9\x90\x96\x9f\x2c\x38\xd1\x7e\x36\xc6\x5d\x49\x9b\xf6\ \x37\xd4\x90\xf2\x57\xfc\xbb\xa1\x1d\x4e\xf7\xde\x58\x05\x26\x8e\ \x1b\x83\x49\xe3\xc6\x12\x10\xf8\x91\xce\x64\x61\x94\x4c\xd4\x54\ \x56\x61\xe2\x98\x3a\x4c\x18\x55\x87\x42\xe4\x4b\x30\xfc\xb3\xed\ \x3a\x01\xb6\xec\x65\x36\x21\x8b\x85\x5c\x0e\xed\x77\xdb\x8a\xcf\ \xd3\x7d\x34\x72\x19\x1c\xb0\xb0\x3a\xdf\x82\x11\x6f\x86\x51\x2c\ \xd8\xe5\x40\x2e\x72\x17\x0a\x9d\xc4\x54\x3a\xf0\xaf\x87\x7e\x8c\ \x73\xcf\x39\x17\xf7\xff\xed\x7e\xf9\x28\x9e\x0a\xac\x44\xc5\x00\ \x94\x7c\x50\xe5\x67\xcb\xcf\xca\x4f\xbf\x77\xa7\x52\xd8\xd8\xde\ \x26\xe3\xba\x2a\x79\x06\x9f\xb9\x7d\x5f\xd2\x23\x6d\xbc\xa2\x32\ \x7a\x9b\xe7\x01\xd4\x54\x56\xa2\xbe\xb6\x16\xf9\x37\xde\x24\x00\ \x28\xa1\xb1\xa1\x0e\x75\x55\x55\xf0\x79\xb8\xab\x70\x23\x72\x91\ \xcb\x11\xe8\xfc\x0f\x29\x05\x16\x85\x67\x57\x40\x73\x7c\x7d\x38\ \x20\xa0\x3b\x81\x40\x97\xbd\x59\x9d\xcb\x50\x6c\x59\x49\xcf\xe9\ \xf4\x5f\x11\x7a\x21\x0f\xcb\x1f\xb6\xb3\x0a\xd9\x16\x94\xf2\x05\ \xbc\xf4\xe2\x2b\xc4\x38\xb2\x48\x26\xe3\x38\xe9\xa4\x93\x11\x8e\ \x44\xa4\x75\xb8\x12\xc5\x00\x94\x6c\x47\xf9\x35\x51\xfe\xa4\x58\ \x7e\x4e\xf5\x35\x33\xed\xe7\x3c\x7f\x24\xba\xfd\x40\x92\x05\xf1\ \xf5\x63\xb1\x98\x00\x47\x0f\xb1\x06\x1f\xf9\xfd\xdc\x2c\x24\x93\ \x2f\xa1\xa6\xaa\x1a\x63\x46\xd5\x0b\x8b\xe0\xb1\x62\xf6\xc4\xdf\ \x02\x4a\xae\x03\x50\x0c\x7f\x9a\x94\xb8\xc3\x0e\xf6\x95\x69\x04\ \x2b\x3f\xff\xae\x95\x59\x80\xad\xfc\x66\xf7\xbb\x28\x6c\x7c\x1d\ \x26\xb1\x09\x0e\x34\x5a\x66\x09\x56\x29\x6f\x03\x88\xaf\x02\x20\ \xe5\x9f\x33\x39\x8b\x39\xd3\x3c\xd8\xd8\xdc\x85\x87\x1e\xfe\x3b\ \x7e\xfc\x93\x1f\xe3\xbd\x77\xdf\x95\xee\xc2\x5c\xcb\xa0\x44\x01\ \x80\x92\xcd\x44\x14\x83\xf3\xfb\x64\xf9\xd9\x0a\x77\x93\x02\x37\ \x73\xc0\xaf\xaa\x52\x26\xf1\x98\xd8\xde\xa0\x4e\x48\x0d\x00\xd3\ \x7e\x8d\x7e\x61\xf6\xc0\xfe\x3f\x8f\x09\x93\xd6\xdd\xf9\x1c\xb1\ \x82\x08\x6a\x89\xfe\xbb\xf5\xfe\x83\x3a\x4d\xa9\xe2\x2b\x06\xce\ \x80\xe9\x69\xb4\x73\xfc\xa2\xf0\x96\x7d\x57\x30\x13\x20\xfa\x6f\ \xb9\x1d\x17\xa0\x6b\x05\x8a\xeb\x5e\x82\x25\x95\x82\x7a\xef\xdf\ \x16\x20\x28\xd9\x19\x08\x78\x2b\x51\x53\xed\xc1\x09\xfb\x16\xd0\ \xd3\x1d\x47\x4b\x6b\x07\x56\xad\x5e\x8d\xeb\x6f\xf8\x21\xee\xbe\ \xeb\x4e\x64\x33\x19\xf8\xe8\xd8\x54\x80\x50\x01\x80\x92\xb2\x0f\ \x46\xca\xc5\x0a\x9e\x48\xd8\x3e\x7f\x9c\x18\x40\x73\x7b\xbb\x50\ \x75\xa6\xfd\xdb\x1b\xf9\x6b\x3a\xca\x5f\x55\xc9\xca\x6f\xd2\x67\ \x24\x64\x5a\x8f\xdf\x99\xd2\xcb\x03\x40\x39\x83\x10\xf0\x7b\xe1\ \x96\x32\xe2\xcd\x3f\xab\x08\x43\x9b\x46\x2c\xe0\x54\x80\x27\x06\ \x99\xce\x70\x10\xa7\x0e\xc0\xe2\x5c\x3f\xd7\x07\xb5\x2f\x45\x61\ \xc3\xab\x76\xb2\x40\x77\xf7\xc5\x0a\xb8\x24\x91\x63\x12\xc2\x04\ \x8a\x74\x1e\x6e\xb8\x2b\xaa\xb0\x70\xdf\x2c\x0e\x99\x03\xbc\xb7\ \xaa\x09\xf1\xce\x2e\xa9\x4f\xb8\xfb\x9e\xbb\x71\xfd\xf5\x3f\xc0\ \x6b\xaf\xbe\x22\xc7\xa4\x62\x03\x0a\x00\x76\x79\xca\xcf\x4a\xc0\ \xbe\x71\x9c\x95\x9f\x53\x7d\x64\xbd\x9b\x3b\x3a\xc8\xe7\xaf\x46\ \x4c\x46\x74\x63\xbb\x01\x3f\x6e\xdd\x5d\x4d\x96\xdf\x12\xe0\xe8\ \x11\xab\x1f\x08\x04\x91\x64\xe5\x2f\x94\x44\x3f\x7d\xb4\x8f\x4b\ \xdb\x56\xf7\x5e\x7b\x39\x70\xd1\xfb\x69\x58\x81\x3d\x88\xc2\x93\ \x2b\x60\x95\x9c\x03\xf4\x0b\x28\x58\x2d\x2f\xc2\x68\x5d\x66\x57\ \x08\x96\xd7\x08\x70\xb1\x90\xe3\xb2\xf4\xa3\x02\xc2\x0e\x74\x5f\ \x18\xe3\xa6\x84\x70\xde\xc2\x2e\x4c\x6d\xd4\xb0\x7c\xe5\x5a\x74\ \x10\x9b\x09\x84\xc3\x58\xb3\x7e\x3d\x7e\xf4\xe3\x1f\xe3\x77\xbf\ \xbb\x09\x2d\x2d\x9b\xc4\x2d\xd0\x75\xe5\x16\x28\x00\xd8\xc5\x14\ \x9f\x87\x7a\x72\xb5\x1e\xe7\xea\x79\xbc\xb6\x5b\x94\x3f\x81\x16\ \xb2\xfc\x8d\x35\x35\x42\xfb\xb7\xe7\xf3\xcb\xac\x3e\xfa\x8c\x2a\ \x56\x7e\xd8\xeb\x03\x58\xf9\xed\x89\x3d\x59\x49\xfb\xb1\xf2\xfb\ \x49\xf9\xdd\xff\xb6\x93\x0f\x5b\xee\x46\x62\x01\xa7\x90\x07\xe0\ \x25\x10\xe8\x06\x4a\xc4\x06\x32\xeb\xa1\xb5\xbd\x02\x2b\xd9\xea\ \xd4\x03\xb8\x1d\x66\xc0\xab\x08\xdd\xb4\x2f\x3d\xc2\xd5\x0b\x02\ \x72\xbc\xb4\xf1\x7c\xd1\x70\x4d\x1d\xf6\x99\xa7\xe1\xa2\x63\x93\ \x88\xfa\x35\xac\x59\xbd\x01\xad\x9b\x5a\xe5\xbc\x83\x91\x30\x1e\ \x7f\xea\x49\x7c\xf7\xba\xeb\xf0\xe0\xfd\x7f\x45\x2e\x97\x11\x20\ \x50\x6e\xc1\x20\x31\x50\x75\x09\x76\xbc\xf0\xcd\x5d\x4e\xef\xf1\ \x38\xef\x6c\x26\x2d\x33\xf5\xd8\x00\xb3\x15\x6f\xed\xec\x46\x5b\ \x77\x37\x46\xf1\x88\xee\x48\xc4\x09\xd2\x6d\x47\xf9\x1d\x9f\xdf\ \x72\x7c\xfe\xf2\xac\x3e\x6e\xe0\x59\x28\x16\x65\xbd\x80\xef\x03\ \x29\x7f\xf9\x43\x4d\x14\x5c\x47\xc0\x1d\x7e\x02\x7a\xf7\x13\xd0\ \x72\x9b\x48\xe9\x03\xe2\xfb\xeb\xa1\x18\x50\xc8\x42\x33\x4a\x03\ \xa7\x07\x5b\xc4\x02\x5c\x9a\x64\x03\xca\xba\xeb\x92\xb5\x44\xb4\ \x8f\xdb\x8b\xea\xf1\x8d\x38\xea\xc0\x26\xb4\xc5\x73\xf8\xe5\xfd\ \x3e\x34\x6d\x6c\x92\x89\xc5\x91\x8a\x28\x62\x15\x31\xa4\xf3\x39\ \xfc\xe1\xe6\x5b\xf0\xf2\xcb\xaf\x60\xd1\xe2\xc5\x98\x31\x63\xa6\ \xb0\x14\x1e\x3e\xaa\x44\x01\xc0\xf0\x56\x78\x68\x7d\x55\x39\xb0\ \x07\x79\xe6\x72\x39\x14\xc9\x32\x17\x4b\x76\xb5\x9d\x4e\xb4\x9c\ \x3b\xed\xb6\x77\x27\xb0\xa9\xa3\x13\xa3\xea\x6a\x11\x65\xe5\x37\ \xb7\x1d\xf2\xb3\x27\xf6\x78\x50\x59\x19\x13\x65\xe2\x8c\x41\xc0\ \xef\x93\xf6\xdd\x89\xa4\xad\xfc\xba\xfe\x21\x95\xdf\x86\x25\xfa\ \xbc\x5a\x14\x82\xe7\xc2\x6f\xac\x03\x52\xef\xdb\x77\x86\x27\x42\ \xac\x9f\xac\x33\x29\xb4\xcb\x28\xc0\x34\x8a\x36\x08\xf4\x1e\x23\ \xbb\x02\x9a\x64\x0c\xdc\x6e\x0d\xe9\xee\x34\x3a\x7b\x48\xf9\x6b\ \x5c\x08\x55\x05\x51\x37\xa1\x0e\x9f\x3d\xa2\x05\xad\xf1\x4a\xdc\ \xf6\x94\x45\xfb\xb4\x49\x2a\xb3\x44\xee\x49\x94\x5c\x9c\x6a\x02\ \xbc\x15\xab\x56\xe1\x86\x1f\xdd\x80\xe3\x8f\x3d\x0e\xc7\xd0\x16\ \xe1\xf1\xe3\xa5\x92\x6a\x3b\xbe\xab\x03\xc0\x70\x5a\x0b\x20\xf4\ \x55\x13\xb5\x67\xc3\x28\xc1\x39\x1e\xa6\xc9\x93\x75\x78\xa2\x6e\ \xc9\x30\x85\xaa\xf3\xf9\xd8\xbb\xea\x12\x08\xe3\x20\x5d\x73\x7b\ \x07\x2a\xc2\x21\x84\x83\xc1\x5e\xdf\x7e\xdb\x96\x9f\x95\xbf\x42\ \xfe\x80\x28\x7f\xc0\x4b\xd4\x3f\x88\x78\x2a\x83\x02\x29\x0d\x2b\ \xbf\xdf\xe3\x22\xe5\xff\x28\xf5\xe7\x45\x14\xb4\xfd\x80\xc8\x97\ \xe1\xd3\x6e\x82\x96\x5c\x6e\xc7\x03\x3c\x15\xa4\xdf\x3e\x9b\x0d\ \xd0\xb9\x80\x03\x7e\x62\xa5\x4d\xbb\xf4\x98\xce\xc5\xe3\x75\x61\ \xcd\xaa\x34\xfe\xe7\xce\x18\x56\x6e\xaa\x25\x30\xf3\xe1\xe2\x53\ \x53\x58\x30\xdf\xc2\x98\x62\x01\x17\x1c\xdb\x85\xd6\xee\x1a\x3c\ \xf6\x5a\x86\x5c\x97\x2e\x39\x49\xbe\x3e\xc1\x50\x48\x80\x80\xad\ \xfe\x5d\xf7\xde\x8b\xe5\x2b\x96\xe3\xcc\x33\xce\xc2\x94\x69\xd3\ \x04\x28\x07\x30\x8e\x61\x2c\x43\xf9\x3e\x56\x0c\xe0\x23\x5b\x79\ \xbb\x29\x67\x59\xf9\xcb\x4a\x2a\x8a\x4f\x8a\x62\xca\xcd\xab\x49\ \x90\xcb\x43\x8f\x0c\x0c\x7c\x53\xf3\xd3\x9a\x13\x0b\x48\x67\x53\ \xf2\xc8\x43\x3d\xf5\xed\x68\x7f\x99\xf6\x57\x89\xe5\xb7\xa4\x4a\ \xd0\x2f\x96\x3f\x88\x1e\xa1\xfd\x76\xb4\x9f\x95\x9f\xe9\xff\x47\ \xbb\xdf\x38\x2d\xa8\x13\x08\x1c\x03\x33\x5c\x07\xbf\xfb\x0f\xd0\ \x7b\x9e\x85\x5e\x8a\x43\xf3\xc7\xec\x62\x20\xcb\x4d\x4a\xc9\xa9\ \x41\xd3\xa9\x48\xb4\xe8\xef\x59\x78\xff\xdd\x1e\x5c\xfd\x4b\x1f\ \x5e\x5f\x13\x41\xc8\x9b\xc1\xfa\x8d\x39\xac\x6d\x8a\xe1\x3f\xbf\ \xec\xc6\x81\xfb\x5a\x98\x4a\xee\xc3\x97\x4e\xee\x44\x47\x4f\x2d\ \xde\x58\x6d\x9f\xb3\x69\x46\x6c\x70\x2c\x15\x11\x0a\x05\x51\x53\ \x5b\x2b\x6c\xe0\xc6\x1b\x6f\xc4\xe9\xa7\x9f\x86\x03\x3f\x75\x90\ \xc4\x1b\x94\x4b\xa0\x82\x80\x43\x0f\x35\xc9\x1a\x7a\x7d\x7e\x09\ \x6a\x71\x4e\x9c\xd7\xe0\xb3\x05\x66\x0a\x5e\x2a\x99\x52\x89\xc7\ \xd6\xbf\x48\x37\x77\x2e\x57\x40\x36\x9f\x17\x17\x80\xab\xf1\x34\ \xe7\x3f\x59\x47\x43\x2e\x00\x2b\x36\x2b\x2f\x8f\xfa\xde\x5a\x91\ \x2f\x03\x06\x07\xfc\x84\xf6\xc3\xee\x06\xc4\x80\x11\x24\xa5\xb1\ \x47\x74\x17\x6d\xe5\x77\xdb\xca\xff\xf1\xc4\x94\x5e\x00\x25\x6b\ \x6f\x64\x02\xdf\x46\xb1\xfa\x02\x3a\x37\x37\xf2\xf1\x4d\xd0\x72\ \xdd\xd0\x4a\x69\xfa\x5b\x26\x74\x3a\x1e\xee\x2b\xe8\x62\xa7\x9f\ \xce\xf3\xb6\x87\xf2\xf8\xc7\x9b\x41\x54\x04\x8a\xc4\x3e\x48\xa1\ \x7d\x39\x74\xb4\xb5\xe1\xdb\xff\xed\xc3\x3f\x5f\xa8\x45\x60\x42\ \x2d\xe6\xcc\xf5\xe3\xab\x9f\xed\xc2\xc4\x7a\x1d\x9b\xda\x7a\x90\ \xcd\xa6\x91\x49\xa7\xa5\x68\x29\x91\x48\x22\x95\x4c\xc9\x3c\xc2\ \x1c\xb9\x19\x37\xfd\xf6\xb7\xb8\xf7\x9e\xbb\x50\xa2\xeb\xa9\xd2\ \x85\x0a\x00\x86\x94\x78\xb8\xa2\x4d\x72\xf7\xa6\x58\x74\x4e\xe3\ \x95\x78\x23\x2b\xcc\x8f\xf9\x52\x41\x80\xa0\x58\xe4\xc7\x82\xac\ \xcf\x67\x75\x97\x40\xa0\xe3\x26\xc8\xb2\x5d\xb2\xa0\x21\x7f\x00\ \x41\x02\x92\x32\x60\x98\x5b\x59\xdd\xe7\xf5\x92\xe5\xaf\x8a\x49\ \x17\xdf\x44\x3c\x8e\x10\x47\xfb\x43\x01\x19\xd4\xc9\x81\xc4\x32\ \xed\xff\xe4\xfa\xf6\xdb\x55\x82\xa6\x59\x0f\x33\x70\x29\xee\x78\ \xfa\x30\x1c\x7d\x5e\x0a\xdf\xfa\x51\x12\x4f\x3d\xbc\x09\x9b\x56\ \xae\x23\x40\x68\xa7\x53\x28\x49\x2a\xd0\xa2\xe3\xea\xe8\x26\x06\ \x82\xf2\xec\x00\xe1\x37\xf0\x79\x2d\x74\x92\x7b\x73\xcd\x4f\xbd\ \x78\xfa\xf9\x06\x84\x26\x36\xe2\x80\x7d\x74\x5c\xb9\xb8\x1b\x95\ \x21\x0d\x2d\x6d\x71\xb9\x76\xf9\x6c\x4e\x66\x10\x26\x89\xd5\x24\ \xe2\x09\x78\x5c\x9c\x29\x88\xe0\xae\x25\x4b\x70\xf3\x9f\xfe\x48\ \x40\x91\x55\x20\xa0\x00\x60\xf0\x7d\x38\xa6\xad\x3e\xbf\x5f\x2e\ \x19\x2b\x38\xa7\xda\x8a\x85\x92\x58\xf9\xa2\x61\x48\xe0\x8a\x1f\ \xb9\x20\xc6\x28\xf2\xf3\x36\x75\x65\xa5\xd0\x1c\xc5\xe7\x8d\x57\ \xe7\x95\x3f\x93\x2b\x00\xb9\xce\xdf\x23\x8b\x6d\x9c\x75\x38\x9a\ \xb3\x3f\xa7\xf1\xfc\xde\x5e\xda\x1f\xef\xe6\x54\x9f\x53\xe4\xc3\ \xca\x5f\x2c\x0e\xa0\xfd\x9f\xbc\x14\x09\x90\x7c\xf0\x54\x1e\x8b\ \xb5\xf1\xc9\xb8\xe9\x81\x0a\x5c\x72\x63\x14\x37\xfe\x31\x88\x57\ \xfe\xd9\x81\x8e\x35\xeb\x61\xe4\xb3\xd0\xc3\x41\x1c\xb9\x9f\x07\ \x85\x6c\x37\xb1\x11\xbb\x36\xa8\xec\x24\xf9\x09\x04\xe2\x9d\xed\ \xb8\xe6\xbf\xbd\x78\xea\xf9\x51\x88\x4e\x6e\xc0\xe1\x07\x18\xb8\ \x72\x11\x9d\x8b\x47\x43\x5b\x7b\x5c\x5c\x80\x62\xbe\x80\x14\xb1\ \x81\x24\xb1\x01\x76\x6f\xf8\x5a\x56\x56\x56\xe2\xb1\x27\x9f\xc4\ \x1f\x7e\xff\x3b\x64\x32\x69\x05\x02\x3b\x48\x5c\xd7\x5e\x7b\xed\ \x90\x3a\xa0\xf7\xde\x7b\x8f\x2d\xc3\xe7\x76\xdf\x7d\xf7\xf1\xd2\ \xe4\x62\x90\x85\xad\x32\x5b\x7c\x2e\x61\x65\x4b\x5d\x22\xab\xce\ \x37\x28\x53\x7d\xd3\xb0\xe9\xbe\x3c\x96\x6c\x0b\x2e\x3f\xf3\x7b\ \x74\xdb\xe2\x97\xe3\x05\x76\xe1\x8e\x87\x14\x38\x28\xcc\xc0\x76\ \x04\x20\xa3\xb6\xbd\xd2\x95\xd7\xae\xe7\xe7\xcc\x00\x57\xed\x31\ \xd8\x70\x56\x40\x52\x7d\x4e\x9e\x9f\x47\x74\x97\x53\x7d\x3b\x56\ \xf9\x1d\xe0\xa3\x73\x9b\x34\x61\x2c\xc2\x21\x1d\x71\xb2\xfa\xe9\ \xbc\x86\x67\xdf\x2c\x60\x6d\x4b\x18\x95\xee\x0c\x62\xbe\x6e\x3a\ \x26\x2f\xa6\xef\x51\x89\x42\x22\x8e\x47\x9f\x2f\x20\x12\x0d\xdb\ \x41\x48\xe7\xcc\xe9\x10\x91\x49\xa5\xf1\xdc\x1b\x11\x4c\x18\x1b\ \xc1\x8c\x39\x06\x46\x07\xbb\xe1\x25\xe6\xf0\xd2\x0a\x2f\x32\xd9\ \x02\x9d\x9b\x4f\xae\x50\xd1\x89\xfe\xcb\x35\x27\xc0\x0d\x47\x23\ \x78\x97\xee\x87\xce\xb6\x56\xcc\x9a\x35\x5b\xbe\x03\x73\x18\x06\ \x06\xb9\xce\xe1\xe6\x9b\x6f\x5e\xbd\x7e\xfd\xfa\x77\xe9\xd7\xb5\ \xb4\x75\x9e\x77\xde\x79\xc6\x84\x09\x13\x54\x10\x70\xa8\x5b\x7e\ \xb6\x3c\x1c\x7d\x67\x8a\x5f\x60\xeb\x4e\x56\xde\x34\x2c\x19\x9f\ \xcd\x29\x2d\x01\x00\xde\x2c\x3b\x35\xc6\xd6\xdb\xad\xf5\xe5\xc6\ \xcb\xea\xc9\x37\x34\xef\xc3\x3e\xaf\xf4\xf0\x13\x73\xef\xdc\xec\ \xa4\xf4\x2e\xdd\x5e\x2c\xc3\x75\x01\x6e\xba\x61\xbc\x6e\x2f\x4a\ \x46\x49\xa6\xf4\x72\x9e\xdf\x47\xee\x42\x77\x22\x25\x2c\x83\xd9\ \xc8\x27\xe3\xf3\x7f\x80\xf3\xa7\x73\x3f\xfd\xb4\x33\xd1\xd2\xd2\ \x86\xb7\x96\xbd\x4d\xa0\xe4\xc7\x8b\x2b\x9b\xd0\x1a\xaf\xc6\x85\ \x64\xad\x8f\xca\x6f\xc4\xe8\xdd\xea\x71\xcd\x55\xa3\x51\x32\x9b\ \xf0\xbf\x77\xb4\x61\xc2\xf8\x06\x3a\x1f\xc3\xa9\x64\xd4\xc4\x1d\ \x48\x11\x80\x5c\xfb\x3f\xb5\xc8\x5e\x32\x09\xc7\x2d\x28\x62\x71\ \xbe\x85\x5c\x18\x1d\xbf\x7c\x20\x80\xae\xae\x38\xaa\x6b\x2a\x25\ \xbb\x91\xc9\x64\xe5\xba\x32\xf8\x70\x90\x90\x17\x38\x3d\xff\xd2\ \x4b\x02\xc2\xe7\x9f\x7f\x21\xbc\x0c\xc4\x2a\x30\xa8\x00\x60\x67\ \x59\x7e\x56\x7e\xf6\xb5\xb9\x80\xc7\xe0\xcd\xb2\x2d\x3e\x2b\xb3\ \x28\xbe\x69\x47\xc3\x59\xa9\xb9\x55\xb7\xab\x9f\x53\x25\xc1\x3e\ \xfa\x1c\x9f\xcf\x2b\x16\x9d\xa3\xf5\x9a\x56\xea\x05\x16\x8e\x13\ \x58\xce\x12\x5f\x4d\xe2\x02\xa6\x54\x08\x6a\x64\x09\xd3\xec\x1f\ \xe7\xf3\x62\xf9\x7d\x3e\x3f\x9a\x5b\x3b\xe4\xc6\xe7\xba\x7e\x9f\ \x7b\xe7\x0d\xea\x94\xbf\x49\xcc\xe3\xcc\x33\xce\xc4\xf5\x37\xfc\ \x80\xac\x99\x4f\x5c\x96\x55\xef\xaf\xc7\x7f\x2d\x09\xa3\xbd\xc7\ \x23\xca\x3c\x61\x46\x11\xd7\x7e\xb3\x91\xae\xd3\x26\xfc\xe2\xae\ \x16\x4c\x99\x54\x4f\x00\x65\xc2\x3e\x3d\x8d\xde\x67\xa1\xa7\xab\ \x1d\x3f\xfc\x75\x3d\xf9\x09\xd3\x71\xdc\x9e\x45\x9c\x56\xe8\x44\ \x22\xa3\xe3\x4f\x8f\xf9\xa0\x75\xc6\x51\x55\x5d\x29\xcc\x26\x97\ \xcd\x3a\xa0\x6a\x09\x28\x44\xa3\x51\x3c\xff\xaf\x7f\x49\xbd\xc3\ \x59\x67\x9f\x23\xc1\x47\x05\x02\x0a\x00\x76\xb8\xcf\x2f\xca\x4f\ \xfe\x29\x53\x53\x43\xf2\xfa\x46\xaf\xd2\x1b\x96\xe1\xe4\xc1\x6d\ \xaa\xaf\x43\x43\x7f\x83\x5c\x2e\x06\xe2\xd7\x58\xf9\x93\x99\x0c\ \x36\x36\x35\x93\x35\xf4\x0a\xd5\x67\xe5\xe6\x00\xde\xa8\xfa\x7a\ \x09\x12\x4a\x01\x10\x37\xde\x75\x02\x88\x70\x5c\x86\x00\x59\xff\ \x75\x4d\x2d\xe4\xf7\xa7\x89\x8a\x07\xa5\xc8\xc7\xe3\xd2\x77\x6a\ \x6e\x99\x83\x75\x13\x26\x4e\xc4\xe2\x93\x17\xe1\xb7\xff\xf7\x7b\ \x34\x8e\x19\x25\xec\x65\xdd\xfa\x66\xfc\xe6\x01\x9f\xb0\x81\xcf\ \x65\xba\x88\xde\x97\xf0\xbd\xab\x6b\x09\xc4\x3a\xf0\xeb\xbb\x5b\ \x31\x65\x72\xbd\xa4\x09\xed\xe0\xa6\x0d\x02\xa9\x78\x1b\x7e\x7c\ \x53\x3d\xf4\x4b\x66\xe2\x98\xd9\x6f\xe2\xfc\x52\x37\x31\xab\x4a\ \xdc\xfa\x04\x5f\xcb\x38\x2a\xab\x79\x49\xb3\x2e\xd7\x87\x01\xb1\ \xdc\x00\x25\x10\x0e\xe1\xa9\x67\x9e\xa1\x6b\x10\xc6\x29\x8b\x16\ \x3b\xa9\x44\x35\x9d\x48\x01\xc0\x0e\x01\x00\x5e\x44\xe3\x95\xe0\ \x94\x44\xf4\x85\xf6\x1b\xbd\xfe\x3e\xca\x51\x7d\xbd\x4c\xf1\xb7\ \xae\xfc\x70\x7c\x7f\x56\x68\x0e\x0c\x56\xc7\x2a\xe1\x27\x36\x90\ \x4e\xa7\xe1\x8f\x84\x51\x53\x55\x25\x37\x39\xbb\x05\xdc\xb9\xc7\ \x74\x0a\x85\xca\x9d\x79\x43\xa1\x10\x36\xb5\x75\x60\x53\x6b\x2b\ \x42\xc1\x10\xa2\xec\x0a\x10\x28\x0c\x46\x61\x09\x03\xd3\x81\x07\ \x1d\x8c\x57\x5e\x7d\x0d\x6f\xbc\xb5\x14\xf5\xf5\x0d\x42\xef\x5b\ \x36\xb5\xe0\xce\xa7\x81\x4d\x5d\xb5\xf8\x52\xb6\x03\xf3\xe7\x97\ \x70\x3d\x81\x80\x85\x4e\xfc\xfa\x1e\x02\x81\x89\x75\x70\xbb\x34\ \xa7\x99\x89\x46\xec\xc1\x42\xa2\xbd\x15\x3f\xfa\x0d\x01\xdf\xc5\ \xb3\x70\xf4\xbc\x37\x71\x91\xd9\x45\x2e\x56\x25\x6e\x7b\x86\x63\ \xac\x71\x49\x79\x72\xbb\x91\x42\xbe\x60\x57\x56\x95\x83\x8a\x01\ \x3f\x1e\x7a\xe4\x61\x44\xe8\xda\x1d\x7d\xec\xf1\xaa\x71\xac\x02\ \x80\x1d\x40\xfd\x49\xc9\x3d\x44\x73\xd9\xff\xce\x39\xd4\x9f\x23\ \xd5\x86\x73\xb3\x49\x60\xcf\xb2\x33\xf9\xe5\xd8\xfe\x40\xe5\xc7\ \x16\x33\x32\x0a\xf9\xa2\x7c\xae\xcf\x6b\xbb\x13\x41\xa2\xd4\xa3\ \x1a\xea\x91\x24\xab\xbe\x6a\xdd\x7a\x44\xc9\xaa\x85\x02\x41\x72\ \x07\xfa\x68\x2d\xd7\xf6\xf3\xdf\x5f\xb5\x76\x83\x44\xd6\x63\x91\ \x10\xed\xe3\x1f\xb4\x1b\x9e\x8f\x9f\xfd\xef\xc5\x8b\x17\x61\xc5\ \x8a\xe5\xd0\xdd\x2e\x54\xc6\xec\xb6\xe4\x1e\x57\x07\xfe\xf1\x66\ \x06\x9d\xc9\x5a\x7c\x35\xdd\x85\x83\xf7\x6f\xc1\xf5\xdf\xa8\x25\ \xc5\x8f\xe3\x97\x77\xb5\x61\xe2\xf8\x06\x52\x7c\x73\x00\x08\xc4\ \x09\x04\x6e\xf8\x4d\x1d\xac\x8b\x66\xe3\x98\x3d\x97\xe2\x62\x83\ \x40\xc0\xac\xc2\xdd\xff\x84\x0c\x2d\x89\x55\x56\x48\x11\x55\xb1\ \x98\x47\x3a\x65\x39\x60\x6a\x49\xa3\x93\x7b\xef\xbb\x0f\xd1\x8a\ \x18\x0e\x38\xf0\x20\x09\xa8\x42\x81\xc0\x47\x16\x95\x06\xdc\x8c\ \xfa\xb3\x7f\xc9\x0a\x9d\x2b\xe4\xed\x74\x9f\xe4\xf2\x6d\xab\xef\ \xb2\x1d\x75\x09\xda\x79\x39\x2d\x65\x61\x2b\xca\xbf\xb9\x6f\x6e\ \x17\xfd\xf0\x7b\xba\x13\x09\xa4\x32\x69\xb2\xe6\x41\x24\x93\x29\ \xac\x5a\xb3\x56\x9a\x77\xf0\x92\x5e\xa3\x9f\xf2\xf3\x3a\x01\x3f\ \x3d\xbf\x66\x7d\x13\x12\xc9\x1e\xa2\xbd\x01\xd9\x67\xb0\x6f\xf4\ \x22\x01\xd2\xa4\xc9\x53\x70\xcc\xd1\x47\x23\x1e\x8f\x23\x52\x11\ \x41\x38\x1c\x46\x75\x4d\x2d\x1a\xea\xa2\x78\x67\x8d\x85\x6b\x6f\ \xae\xc6\x83\x8f\x5b\xe8\x5a\xdb\x82\xef\x7e\x25\x84\x2f\x9d\x9a\ \xc6\xba\x0d\xad\xe4\x46\xa1\x37\x2b\xc2\xd7\x48\x40\xa0\xa3\x15\ \xd7\xff\xc6\x8b\x07\x97\xce\xc5\xac\x79\x31\x5c\xf2\xe9\x6e\x9c\ \x72\x60\x91\xce\xb9\x80\xee\xee\x04\x01\x46\x49\x98\x10\xb3\x0f\ \x66\x4d\xe9\x54\x8a\xc0\x34\x4f\xe0\x6c\xe0\x2f\xb7\xfd\x05\xef\ \xbc\xfd\xa6\x44\xd8\x95\x8c\x30\x06\x30\x58\x73\x01\xc4\xc2\x93\ \xa2\xe6\x88\x7a\xe6\x73\xce\xc2\x1d\x58\x7d\x4d\x73\xb9\xe3\x2e\ \xf9\xe1\x9c\xe3\xe7\xd7\xb8\x28\x27\xcf\x69\x41\x8e\xcc\x6b\xfa\ \x56\xa6\x63\x39\x85\x3f\x5c\x48\xeb\x72\xa1\xae\xba\x5a\x02\x82\ \x5c\x1d\x98\x27\x80\xa9\x20\x2a\x1b\xe3\x8e\x3f\x8e\x2f\x6b\xf3\ \x0a\xb2\xa8\xc4\x14\xd2\x99\x1c\x56\x6f\xd8\x00\x0f\x59\xc1\x7a\ \x72\x15\x18\x40\x0c\x63\xf0\x7d\x5e\x66\x44\x47\x1e\x75\x14\x5e\ \x7e\xf5\x15\xb4\xb4\xb5\x91\x25\xae\x70\xe2\x22\x06\x5c\x6e\x1d\ \x1b\x5b\x7a\xf0\xbd\xbf\x54\x22\x91\xe9\xc1\x89\x87\x75\xe0\xda\ \x2f\x55\xc1\xe3\x49\xe1\xbf\x6f\xb7\x30\x76\x54\x1d\x01\xa7\xd6\ \x1b\x13\x60\x10\x48\x76\x11\x08\xfc\x96\xdd\x81\xb9\x38\x7a\xfe\ \xeb\xb8\xd8\xe4\xb5\x02\x55\xb8\xef\x79\x66\x1d\x71\x54\x55\x55\ \x08\x28\xf3\x42\xaa\xb4\x95\x16\xf0\x88\x10\xe8\x70\x4c\xe5\x0f\ \x7f\xfa\x03\xbe\xf4\xc5\x2f\x61\xec\xb8\xf1\x43\xba\xe7\xe0\x50\ \x76\x55\x14\x03\xd8\x2c\xf0\xc7\xca\x9c\xcb\xe5\x85\xf6\xdb\xb6\ \xdb\x12\xc3\xcb\x16\x39\x1c\x0e\xc9\xca\xbd\x27\xff\xf5\x12\x1e\ \x7c\xea\x1f\x78\x7d\xc5\x4a\x59\xd0\xc3\x5d\x78\x78\x55\xdc\xc0\ \x52\x5e\x6d\xa0\x3b\xe0\xf4\xf1\xe7\xcf\xe6\xc9\xbe\x49\xb2\x68\ \x59\x02\x01\xb1\xfc\x9a\xbd\x77\xb9\x8e\xc0\x4f\x56\x6d\x43\x73\ \xb3\x34\x0a\x89\x91\x95\x65\xa0\x18\x2a\x01\x2f\x83\x5c\xa3\x58\ \xac\x12\x27\x9f\x78\xb2\xc4\x48\xb8\x23\x11\xc7\x2a\xfc\xbc\x24\ \x99\x5d\x9b\xc6\x0a\x74\x93\x9e\xfe\xd7\x3d\x51\xdc\xf6\x90\x1f\ \xeb\x57\x74\xe0\xea\x8b\x7d\xb8\xe2\xd4\x14\xd6\x37\xb5\xa3\x68\ \x0c\x2c\x16\x62\x10\x48\x77\x93\x3b\xf0\x5b\x2f\x1e\x5b\x31\x17\ \xb3\xf7\x0e\xe3\x82\xe3\x3a\x71\xea\xc1\x36\x08\xf3\x6c\x03\xfe\ \x9b\x7c\x7d\x38\x15\x9b\x65\x26\x40\x1b\x67\x4f\x5a\x5a\xdb\x71\ \xfb\xed\xb7\x23\x45\xcc\x40\xf5\x1b\x54\x00\xf0\xf1\x00\xc0\xe6\ \xde\xc8\x92\x82\x72\x75\x9f\x3d\x5c\xcb\x92\x4c\x40\x94\x14\x30\ \x4b\x16\xe6\xd5\xb7\x97\xe1\xc5\x37\xde\x42\x36\x9b\xc3\xf8\xd1\ \x8d\xa8\x21\x1f\xb8\xa9\xb5\x15\xef\xae\x5d\x2f\x2b\xfe\x58\x71\ \xed\xd4\xdf\x40\xe5\xd7\xfa\x51\x03\x66\x13\xd5\x95\x31\x7b\xa8\ \x27\x59\x4f\x59\x4c\x64\xd9\x69\x47\x8e\x0f\x30\x88\xf0\xcf\xeb\ \x9a\x5b\x24\x17\xce\x83\x40\x74\x19\x0c\x3a\x74\xae\x15\x53\xf2\ \x79\x7b\xcd\xc7\x82\xbd\xf7\x46\xbc\x3b\x8e\x10\x01\x63\x40\xd2\ \x95\x3e\x89\x13\x34\xd4\xc7\x90\xcd\x03\x3f\xff\x5b\x18\xb7\x3c\ \x14\xc2\xea\xe5\x5d\xb8\xfa\x42\x0f\xbe\xb4\x38\x89\xb5\xeb\xdb\ \xc9\xd7\xd7\xb7\x00\x81\x04\x31\x81\x1b\x7e\xe7\xc7\x53\xab\xe6\ \x62\xee\x3e\x61\x9c\xb5\xb0\x0b\xa7\x1d\x5c\x14\xcb\xdf\xd1\x19\ \x97\x98\x0c\x5f\x3c\xae\xc0\x4c\xa7\x33\x52\x5c\xc4\x80\xfd\xe6\ \xb2\x65\xb8\xe7\xee\xbb\x04\x20\xd5\x1c\x02\x15\x04\xfc\xc8\xca\ \x2f\xd6\x9f\xe8\x2d\x53\x49\x4e\xf7\x71\x85\x1e\x2f\xb5\xe5\x45\ \x3e\x1c\x88\x5b\xdf\xb2\x49\x5e\x1b\x5d\x57\x8b\x89\x63\x47\xa3\ \xa1\xb6\x9a\x68\xbd\x5b\xaa\x02\x9b\x5a\x5a\xb1\x72\xf5\x1a\xa1\ \xa6\xe3\x1a\xeb\x09\x08\x3c\x52\x34\xa4\x59\x03\x15\xbf\x7c\xc3\ \x73\x30\x8c\x7f\x67\x70\x29\xbb\x16\x92\xfe\xa3\xcf\xe2\x85\x3e\ \x9c\xf2\x5b\xdf\xbc\x89\x00\xa6\xc2\xee\xfa\x33\xc4\xd2\x5d\x52\ \xc7\x40\xe7\x78\xe2\x49\x27\x61\xd9\x8a\xe5\x02\x5c\x11\x02\x01\ \x5e\xec\xc4\xd9\x0e\x3e\xa7\xba\xba\x4a\xb4\x93\xe2\xde\xf4\x50\ \x00\xdc\x33\xf4\x4c\xa2\xf3\xd7\x5c\x1c\x23\xe5\x4f\xe1\x7f\xef\ \xd2\x30\x69\x7c\x2d\xdc\x7a\xbf\x3a\x01\x02\x81\xee\xb6\x56\xfc\ \xe8\xb7\x75\xd0\x3f\x3f\x07\x9f\xda\x7b\x29\x81\x44\x37\x82\x9e\ \x0a\xdc\xf2\x94\x86\xf6\x8e\x04\x6a\x6a\x22\xf4\xbd\x78\x25\x0e\ \x90\x76\x00\x9b\xd9\xc7\x33\xcf\xfe\x03\xe3\xc6\x8d\xc3\xa1\x87\ \x1f\x21\xaf\x29\x51\x0c\xe0\xc3\xdd\xd0\xdc\xa4\x82\x2c\x38\x5b\ \x7f\x4e\xf7\xb1\x9f\xcf\xed\xb5\x5a\xba\xe2\x78\xfb\xdd\xf7\xd1\ \x44\x37\x66\x8c\x94\x7b\xee\xee\xd3\xb1\xcf\x9c\x3d\x30\xba\xbe\ \xd6\xa6\xa4\xb2\xba\x0f\xc4\x06\x46\x61\xde\x8c\xdd\x25\xc8\xf5\ \xfa\xb2\x95\xd8\xb0\xa9\xd5\xa9\x0b\xd0\xfa\x29\xbf\xd6\x4b\x09\ \xb4\x7e\x6e\x81\x28\xbf\xc4\x14\x0c\x29\x02\x62\x20\xea\x88\xc7\ \xe9\x58\x72\xc2\x14\x38\x6d\x68\x0e\x41\xff\x91\x57\xea\x4d\x98\ \x38\x09\x9f\x39\xe1\x04\xa4\xc8\x55\x71\x4b\xcd\x42\x50\xea\x16\ \x5c\x4e\xdb\xb3\xda\x9a\x18\x34\x97\x07\xbf\x7d\x38\x88\x5f\x2f\ \xa9\xc0\x7b\xcb\x12\xf8\xce\xc5\x2e\x7c\x71\x51\x12\xab\xd7\x6d\ \x85\x09\xb8\x4c\x74\xb4\xb4\xe1\x87\xbf\x0e\xe1\x1f\x6b\xe6\x62\ \xce\x82\x30\x16\x1d\x16\xc7\xc5\x47\x67\x10\x70\x15\xd1\xd2\x92\ \x20\x10\xce\xcb\x75\x65\x45\x67\x16\xc0\x9d\x86\x39\x36\x72\xdf\ \x5f\xff\x8a\x15\xcb\x97\xa9\xa0\xa0\x02\x80\x0f\x2f\xac\x90\xe5\ \x95\x75\x42\xf7\xc9\xb7\x7d\x6f\xc3\x46\x34\x13\xbd\xe7\xe5\xba\ \xd3\x27\x8c\x17\xe5\x1f\xd7\xd0\x20\xc1\x3c\xbe\xe1\xca\x41\x1d\ \xfe\x97\xe3\x06\xbc\xdf\xcc\x29\x93\x08\x08\x76\x43\x82\x7c\x52\ \x0e\xe2\xb9\x74\xbd\x9f\xf2\x0f\x64\x02\xe5\x5a\x01\xa6\xae\x45\ \xa2\xb7\xbc\xa4\xb8\x64\xda\x0b\x84\xda\x3b\xbb\xa5\x24\xb8\x8e\ \x2b\xe3\x86\x30\xad\x65\xc6\x74\xe8\xa1\x87\x63\xef\xbd\xe6\x21\ \x1e\xef\xb6\x5d\x81\x60\x08\x7e\x02\x50\xe9\x7d\x48\x0c\xa9\xa6\ \x3a\x06\x8f\xcf\x85\x9b\x1f\xf7\xe3\x17\xf7\x54\x60\xe5\x3b\x09\ \x7c\xfb\xf3\x3a\xbe\xe8\xb8\x03\x45\x43\xdf\x2c\x3b\xc0\x20\xd0\ \x82\xeb\x7f\x1d\xc0\x13\x2b\xe7\x62\xd6\x82\x18\x4e\x3c\xb4\x07\ \x97\x1e\x9b\x46\x5d\xd4\xc0\x26\x02\x81\x1c\x29\x3d\x5f\xf7\x3c\ \x01\x36\x67\x53\xd8\x25\xeb\xec\xee\x96\x78\x40\x77\x57\xa7\x5a\ \x38\xa4\x5c\x80\x0f\x0b\x00\x1a\x82\x7e\x2f\xd2\xa4\xf8\x9b\xc8\ \xea\x73\xa3\x4e\xee\xb1\x3f\x86\xe8\x3e\x5b\xe1\x00\x59\x61\xd6\ \x77\x63\x3b\x54\x9c\x01\xa1\xe4\xb0\x07\x06\x01\x43\xda\x80\xe5\ \x07\xa6\x09\xb5\x2d\xde\x44\xd4\xbf\x24\x0c\xc4\xb6\xf2\xf6\xda\ \x02\xae\x0f\xe0\xde\x80\xd5\xb1\xd8\xbf\x9d\x06\x34\x98\xc2\x91\ \x7f\xb6\xfa\xa7\x9e\x76\x3a\xd6\x6f\xdc\x28\x91\xf9\x48\x24\x24\ \xcf\xb3\xdb\x92\x49\xdb\x33\x02\x6b\xaa\xb8\xc4\x37\x8e\xdb\x9f\ \xf1\xd0\x6b\x31\x7c\x9e\xdc\x81\x6f\x5d\x18\x25\x30\x4d\xe2\xe7\ \x77\x59\x18\x37\xba\x96\xac\x7f\xbf\xec\x80\xc7\x42\x17\xb1\xae\ \x1f\xfc\xba\x1e\xc6\x45\x73\x70\xec\xde\xef\xd0\x73\x1d\x88\x86\ \x4c\xfc\xe9\xf1\x30\x56\x34\xa5\x50\x55\x65\x22\x1c\x26\x17\x8d\ \x98\x52\x92\xae\x1b\xd7\x05\xbc\xbf\x66\x35\x96\xdc\x77\x1f\xce\ \x39\xe7\x5c\xe9\x54\x64\x59\xaa\x52\x50\x31\x80\x0f\x7a\x21\x78\ \x01\x8f\x65\x2b\x65\x75\x34\x82\x49\x63\x46\x61\x4c\x7d\x1d\x02\ \x44\x29\xa5\xde\xff\x03\xd2\x70\xbb\xa4\xd7\x2e\x18\xd2\xf5\xad\ \xd0\xfe\x7e\xd6\x9f\x01\xc3\x70\x56\xbf\x19\x86\x6d\xfd\x39\xe2\ \xcd\xf5\x07\x15\x04\x00\xdc\xef\x6f\xa8\x57\xba\x71\xec\x62\xdc\ \xb8\xf1\x38\xf3\xf4\x33\xc4\xff\x67\xbc\xe2\xda\x80\x80\x2c\x60\ \xf2\x4b\x28\x95\x41\xa0\x8a\x40\x20\x12\xf1\xe0\xce\x7f\xfa\xf0\ \xdb\xbf\xc6\xb0\xec\xad\x1e\x7c\xe3\x73\x3a\xbe\x72\x5a\x12\x1b\ \x9b\xdb\x90\x37\xd0\xaf\x33\xb0\x1d\x18\xec\xe9\x20\x26\xf0\x1b\ \x37\x1e\x58\xba\x07\xa6\xce\xaf\xc7\xa1\xfb\xe6\xf1\xa5\xcf\x24\ \x70\xd0\xee\x45\xf4\xc4\x53\xe8\xea\xea\x21\xd6\x64\x48\xc5\x60\ \x4f\x22\x21\x6e\x1c\xc7\x03\x9e\x7d\xf6\x59\x49\xb7\x2a\x51\x0c\ \xe0\x43\x05\xb6\xc2\xa4\x70\x41\x9f\xb7\x77\x4d\xfe\xc7\xf1\xbd\ \xed\x51\x5f\xb6\x15\xda\x9a\xf2\xb3\x85\x2c\x39\xae\x84\x29\x0c\ \xc0\x44\x90\x57\x00\x4a\x67\xa1\x02\xd1\xff\x7a\x3b\xb5\x35\x0c\ \xaa\xdc\xb8\x54\x7a\x9f\x7d\xf7\x43\x6b\x4b\x2b\x6e\xbf\xfb\x4e\ \x54\x10\x6b\x0a\x85\xc2\x36\xb3\xe1\x6e\x49\xbc\xee\x81\xae\x45\ \x55\x65\x25\xd9\xea\x6e\xdc\xf3\x9c\x07\x3e\x4f\x05\xce\x30\x13\ \xf8\xfa\x39\x11\xba\x3e\x49\xfc\xf4\x36\x60\xec\xe8\xba\x2d\x98\ \x40\xaa\xbb\x0d\x37\xfc\xaa\x0e\xda\xa5\x33\x70\xdc\x82\x77\xe1\ \xf5\xb7\x13\x13\x88\x63\x54\x4d\x14\xf7\xbf\x04\xb4\xb7\x1b\x04\ \x2e\x21\xc9\x9e\x24\xe3\x09\x44\x63\x15\xb8\xef\xaf\xf7\x61\xca\ \x94\x29\x18\x3d\x7a\x34\x86\xc2\x92\x72\x05\x00\xc3\x05\x04\x80\ \x81\x7d\xee\x3f\xa6\x5b\xc1\x99\x84\x7c\xc1\x70\xd4\xbe\xdf\xfa\ \x60\x5e\xf4\x53\x32\x7b\xad\xbf\xe9\x14\x8a\x70\x4e\x3d\x5f\x28\ \xca\x20\x0f\x76\x01\x38\x86\x60\x0c\x83\x05\x2f\x0c\x66\x7c\x94\ \x47\x1f\x7b\x2c\xda\x3b\xda\xf0\xc4\xd3\x4f\x13\x08\x54\xd9\x0b\ \xa8\x1c\x46\x54\x94\x18\x8b\x2e\x53\x8c\x3a\x8d\x1e\x72\x07\x98\ \x7e\x56\xe0\x34\x10\x08\x9c\xcb\x95\x90\x29\xfc\xf4\x2f\x1a\x26\ \x8c\xab\x95\x1e\x02\xe5\xec\x00\x33\x81\x54\x77\x3b\x7e\xf4\x9b\ \x3a\x7a\xff\x54\x1c\xb3\x9f\x5b\x40\x20\x12\x4e\xa0\xb1\x32\x8c\ \xbb\x9e\x05\x36\xb6\x26\xc9\x55\x2b\x0a\xe0\x30\x68\x36\x11\x80\ \x2e\x59\x72\x2f\x2e\xbd\xf4\x32\xf9\x1e\xd4\x7a\x01\x05\x00\x83\ \xe0\x1f\x9b\x72\x33\xda\xdd\x80\x34\xf4\xd7\xff\xa2\x61\x2f\x2b\ \xd6\x2c\xa7\x91\x28\x2f\x02\xa2\xe7\xb9\xbc\x98\xfb\xe3\x71\x24\ \xdb\x6e\x92\x31\xbc\xce\xd7\xed\xf1\xe2\xd4\xd3\xce\x90\xee\x3e\ \x2f\xbe\xfc\x0a\x2a\x24\x85\x69\x83\x5b\x9a\x83\x9d\x45\x6e\x1b\ \xc6\xee\x40\x94\xe8\x7b\x02\x7f\xf9\x07\x2f\xba\x8a\xd2\x73\x3d\ \xb8\xea\xfc\x28\x5d\x97\x24\x7e\x7e\x3b\x30\x69\x3c\x2f\x20\x32\ \x07\x80\x40\x4f\x47\x2b\x7e\xfc\xeb\x7a\x68\xfa\x44\x1c\x7d\x80\ \x1b\x81\x48\x37\xa2\xd1\x04\xc6\xd4\xe5\x71\xe7\x3f\x2a\xf0\xca\ \xaa\x1c\x92\xe9\x82\x9d\x92\x8c\x86\xf1\xd8\xe3\x8f\xe1\xc0\x03\ \x0e\xc4\x9e\xf3\xe6\xa9\xc9\xc4\x0a\x00\x06\xc7\xa5\xe0\x68\x74\ \xb9\xd0\xa7\x4c\xff\xa5\xff\x9f\x69\x2f\x73\x2d\x5b\x7e\x53\xdc\ \x04\x4d\x16\x0b\x65\xf3\x39\x04\x02\x7e\xe9\x03\x30\xdc\x2c\x17\ \xc7\x2f\x42\xe4\xff\x9f\x7f\xc1\x85\x52\x13\xf0\xca\x1b\xaf\x23\ \x5a\x51\x69\x57\x48\xd2\xff\xe9\x54\x5a\x3a\x2a\xb9\xdc\x0c\x02\ \x11\x74\x74\xf6\x48\x8e\xdf\xed\xe2\xde\x0b\x09\x7c\xe7\x12\x5e\ \x5c\x94\xc4\xcf\xee\x00\x26\x4f\xa8\x93\xe7\x7b\x17\x10\x79\x4c\ \x74\x75\xb4\xe0\x47\xbf\x6c\xa0\xe7\xc6\xe0\xd8\x43\x3c\x98\x1a\ \x09\xa1\xb2\xa6\x1d\x93\x46\x77\xe0\xd1\x97\x23\x78\xe4\xb5\x00\ \xd6\xb6\xa5\xd0\xdc\x92\x14\x97\x63\x43\x53\x3b\xe6\xef\xad\xc2\ \x5c\xc3\x0e\x00\x06\x6b\x2d\xc0\x27\x2d\xb6\x1b\xe0\x16\x3f\x94\ \xd7\xb8\x9b\x92\x29\xe8\x6b\x7b\x65\xf5\x73\x01\xbc\x5c\xed\x67\ \xda\x99\x04\x5e\x63\xc0\xcb\x91\xcd\x61\x78\x0d\xf8\x5c\xc3\xe1\ \x08\x2e\xb8\xe8\x62\x68\xbf\xff\x1d\x5e\x23\x10\x08\x86\xc2\xbd\ \x95\x91\xbc\xb2\xaf\xc4\x6e\x8e\xcb\x8b\x9a\xea\x0a\xb4\xb5\x27\ \x08\x04\xfc\x08\xf9\x4b\x74\xad\xe2\xb8\xf6\x8b\xe4\x3a\x20\x85\ \x5f\xdc\x69\x61\xf2\xf8\x7a\x02\x01\x38\x20\xa0\xd3\x35\x22\x10\ \xe0\xa5\xc4\xbf\xac\x83\x59\x6a\xc0\xf1\x87\xb7\xa2\x31\x10\x44\ \x45\x4d\x07\xc6\x8d\x4f\xe0\xd0\xf9\x19\xbc\xb8\x2c\x84\x95\x1b\ \xc9\x4d\x70\x67\x31\x63\xd4\x0a\x72\xb5\x8e\x76\xc2\x28\xd6\xa0\ \xde\xcf\x0a\x00\x76\x61\x37\x40\x16\x15\x59\x90\x00\x9f\x69\x95\ \x01\xae\x2f\xbe\x27\xfd\x07\xbc\x5e\x27\x1b\x60\x4a\xf3\x4f\xdd\ \x99\xbc\x3b\x1c\x85\x41\x20\x12\xad\xc0\x05\x17\x5c\x84\xc0\xad\ \x37\xe3\x85\x97\x5f\x96\x75\x02\x65\x49\x27\xd3\xd2\x23\xc1\xed\ \xf6\xa2\xae\x36\x8a\x4d\xad\x09\xfc\xf1\xf1\x30\x42\x3e\x62\x02\ \x9e\x6e\x7c\xf7\x3f\xd8\xfa\x67\xf0\xb3\xbf\xb4\x60\xfc\xb8\x06\ \x02\x43\x07\x04\xc8\xaa\x7b\x3d\xf6\x2a\xc2\x1f\xfe\xaa\x9e\x58\ \x46\x2d\x3e\xb3\xb0\x0d\x41\x54\x13\x6b\xd2\x50\x3f\x2a\x8f\xbd\ \xe7\xe7\x60\x14\x75\xf8\x42\x01\xb8\x46\xbd\x87\x9e\x52\x07\xfd\ \xc5\x0a\xe6\x27\xea\x86\x54\x00\x30\x18\x7e\xb1\x07\x5a\xa1\xe0\ \x28\xbf\xe5\xac\x31\x70\x5e\xe7\xbc\xbf\x83\x04\x7e\xf2\xf9\x19\ \x28\xd8\x63\xe0\x49\x41\x1c\x30\x1b\xce\x0c\x88\x2b\x05\xc3\x91\ \x08\xce\x39\xef\x7c\x84\x42\x11\x3c\xf9\xf4\xd3\xd2\xd0\xc3\x4e\ \x81\x10\x08\xa4\x2d\x59\xdc\xc3\x20\xc0\x4b\x89\x9b\x9a\x13\xf8\ \xd3\x93\x61\x84\x83\x06\x3c\xde\x4e\x5c\xfb\xb5\x06\x52\xf6\x38\ \x7e\x7e\xdb\x26\xd4\x37\x34\xc0\xdf\x6f\x15\x21\x77\x16\x4a\x76\ \x3b\xfd\x04\x50\x8f\x13\x0f\x6f\x23\xd4\x89\xc0\x6d\xd1\x7b\x19\ \x2d\x3c\xf4\x77\x82\x63\x61\xb8\x0c\xb8\xf0\x1e\xa9\xfe\x02\x76\ \xbe\xd4\x0d\xb9\x15\x51\x0e\xd2\x8e\xbc\xb8\x64\xfd\xb9\x72\x90\ \x17\xfc\x31\xb5\x17\x85\xe6\xa8\xb8\x53\xf8\x23\xff\x31\x48\xd0\ \x3e\x01\x02\x0a\x6e\x00\xc2\x01\x40\xff\x08\x29\x67\x65\xd0\xe3\ \x66\xa6\xa7\x9d\x7e\x06\x4e\x38\xfe\x78\x89\x0b\x78\x7d\x5e\x02\ \x86\xb0\xb8\x09\x1e\x29\xb0\xb2\x88\xfa\xfb\xd0\x58\x1f\xc1\xaa\ \x16\x1d\xb7\x3d\x1d\xc5\x6b\xaf\x5b\x68\x59\xd9\x8e\x6f\x5e\x59\ \x8b\x6f\x7f\x3e\x87\xf6\xd6\x16\xe4\x8a\x76\x07\xa6\xf2\x6d\xeb\ \xf3\x6a\xc8\x24\xda\xf0\xa3\x9b\x3c\x78\xf2\x85\x18\xb4\xb0\x0f\ \xa6\x1e\xb2\xfb\x36\xf2\x10\x96\x5c\x12\x56\x31\x4e\x00\xd0\xe6\ \xac\xea\x54\xa2\x00\x60\x27\xfa\xfe\xac\xc8\xbc\x86\x9f\xab\xfa\ \x0a\xa5\x42\x6f\xb4\xdf\x28\x2b\xbe\xf8\xfe\x90\x6c\x40\xc0\xeb\ \x11\x57\xa1\xbc\xb4\x78\x24\xd5\xb3\xcb\x34\x24\xd2\xdc\xcf\x9c\ \x74\x32\x4e\x5d\xfc\x59\xb8\xa4\xfd\xb9\x4b\x8a\x85\x78\x21\x8f\ \xc7\xeb\xb6\x3b\xfd\xd0\x79\xd7\xd5\x84\xf1\xca\xfb\x3a\x1e\xf8\ \x57\x14\xcb\xdf\xca\xa3\x7b\x55\x07\x2e\xbd\xbc\x11\xdf\xbc\x20\ \x8b\x96\x96\x16\xba\x3e\xba\x53\x5c\x65\x07\x14\xe8\xb2\x21\x19\ \xef\xc2\xed\x7f\xf3\x20\xd9\x03\xb8\x82\x21\xba\xa3\x3d\x36\xdd\ \x37\x73\xb6\xd5\xb7\x4a\x83\xea\xff\x2b\x17\x60\x17\x53\x7c\x8e\ \xfc\x33\x7d\xb7\x87\x87\xe4\x25\xaf\xcf\xae\x80\x51\x5e\x3b\xd0\ \x2f\xf8\xc7\xd6\x9f\x53\x81\x21\xbf\x5f\x16\x02\x59\xf4\x7e\xae\ \xfe\xe3\xfa\x81\x91\x94\xbb\x2e\x57\x47\x1e\xb9\xf0\x28\x44\xc8\ \xf2\xdf\x7e\xd7\xed\x88\x27\x92\x02\x02\x7c\xcd\x78\x51\x0f\xa7\ \xea\x42\x4e\xb3\x95\x47\x97\x66\x50\x17\xab\x40\x38\x1a\xc7\xac\ \x48\x10\x5f\xb8\x62\x0c\xf2\xf9\x0d\xf8\xe1\x1f\x5b\x31\x7a\x34\ \xb9\x03\x5e\x53\x2a\x27\xb9\xd0\xca\xed\x26\xb6\xd0\x6e\x20\xd1\ \x55\x42\x64\x1c\x01\xa7\xdb\xcf\x5d\x4c\x6d\x47\x4b\x35\x0d\x55\ \x00\xb0\xd3\x2e\xa4\xdb\x2d\x56\x5c\x9a\x56\x10\x05\xe5\x9b\x5e\ \x5a\x89\x1b\x4e\x3e\xbb\x1c\xfc\x73\xd6\xfb\x8b\xff\x4f\xaf\x71\ \x96\x80\x97\x00\xe7\xc9\x45\x60\x57\x20\x48\x66\x8d\xcb\x88\x47\ \x9a\xcd\x92\xb5\x12\xc4\x06\xf6\x3b\xe0\x00\xd4\xd4\xd6\xe0\xe6\ \x3f\xdf\x82\x75\x1b\x36\x48\x93\x15\x29\xd6\x49\x26\xa5\xa4\x37\ \x1a\x0d\x09\x68\xfe\xf5\x45\xa0\xb1\x2a\x84\x58\x45\x2b\xa6\x44\ \x42\xf8\x8f\xaf\x8d\xa5\x6b\xba\x8e\x40\x00\x18\x35\xba\x9e\x40\ \x53\x93\xe1\x2c\xa9\x9c\x1b\x7b\x8c\x6d\x43\x6d\x84\x2c\x7d\x89\ \x94\xdf\xe5\x73\x7a\xac\x8b\x0f\x46\xa0\x1a\xa6\xbf\xad\x43\x53\ \xb7\xa8\x72\x01\x76\x84\xb0\xd2\xfb\x1c\xca\x9e\xce\x66\x44\xf9\ \x79\x0d\x8a\x51\x32\x7a\x03\x7f\xe5\xb5\x04\x96\x13\xf4\x93\xd2\ \x5f\xc3\x92\x32\xe1\x28\x47\xab\x39\x55\x48\x37\xb3\xdf\xe3\x91\ \x55\x80\x23\x55\xf8\x1a\x30\x33\x9a\x3a\x6d\x3a\x2e\xff\xc2\xe5\ \xd8\x6b\xee\x5c\x7b\x46\x62\x30\x28\xbd\xff\xb9\x99\x88\xae\xb9\ \x50\x5d\x19\x41\x57\x46\xc7\x5d\xcf\x45\xf0\xf6\x72\x17\xba\xd6\ \xb5\x00\x45\x17\xbe\xf6\xf5\xb1\xf8\xc6\xe7\x92\x68\xd9\xb4\x01\ \x6b\x9a\x92\x68\xea\xc8\xe1\x90\x59\xcd\xb8\xec\xb3\x49\xf8\xc2\ \x01\xbb\x65\x9a\xb4\x66\x73\x89\xf2\x9b\x7a\x94\x9c\x80\x31\x2a\ \x06\xa0\x18\xc0\x0e\x40\x4e\x5d\x17\xab\xcf\xb7\x16\x17\xef\x94\ \x9c\x59\x80\x6c\x7d\x64\x5e\x20\x37\xc7\x70\xd2\x7d\x26\xec\x62\ \x1f\x48\x21\x90\xad\xf8\xbc\x3f\x2b\x7f\x65\x24\x22\x43\x40\xb8\ \x38\x48\xa6\x02\x71\xf4\x7f\x24\x5f\x38\x06\x01\x3a\xdf\xda\xba\ \x3a\x5c\x74\xe1\xc5\xf8\xfb\xdf\x1f\xc2\xa3\x8f\x3f\x2e\x2c\xa9\ \x82\xce\x9d\x17\xf5\x68\x39\x0b\x35\x55\x61\x2c\x6f\x4a\xe3\xfe\ \x17\xab\x30\x61\x6c\x07\xa2\x75\x71\x78\x2a\x2a\xf1\xb5\xaf\x8c\ \xc1\x9c\xdd\x5a\xf1\xd4\x8b\x6d\x68\xa8\x71\xe3\xb4\x63\xbc\xa8\ \x9b\x54\x05\x23\x5f\x2e\xb8\xd2\x6c\x10\x70\x07\x61\xba\xa6\xd1\ \x77\x30\x01\x2a\x05\x38\xcc\x00\x60\x28\x17\x02\x95\xfd\x7c\x0e\ \x6c\x31\x55\x95\x06\x15\xb0\xab\xfc\x4a\x4c\x73\x79\x44\xb8\xc9\ \xa5\xbe\xe8\x5d\x4c\x24\xfe\x3e\x8f\x13\xe3\x49\x39\x9c\x0d\x20\ \x2c\x88\x92\xbf\x5b\x5f\x5d\x49\xd4\xdf\x44\x86\x7b\x07\x38\xa3\ \xbe\x76\x95\xba\x75\x06\x01\xb6\xf8\x27\x9e\x74\x32\x1a\x1b\x1b\ \x71\xef\x5f\x97\xa0\xad\xad\x1d\xb1\xca\x2a\x99\x82\xcc\x53\x87\ \xa3\xe1\x02\x9e\x79\xc7\x8d\x7d\xa6\x07\x30\x6e\x72\x17\xaa\x43\ \x51\xba\x3e\x6e\x1c\x79\xfc\x28\x1c\x79\x6c\x11\x72\x91\x0d\x2f\ \xcc\x7c\xb9\xa8\x42\xb3\x95\xdd\x45\xae\x80\xaf\x01\x39\xed\x50\ \x62\x5b\x9c\x7a\x2c\x0c\xfa\xfd\xac\x00\x60\xc4\x50\x7e\xb7\xa4\ \xf1\x32\xd9\xb4\x34\x0e\x61\xcb\xcd\x55\x7e\x96\x65\xd8\xf9\x7d\ \xd3\xb6\xf8\x56\x39\xf8\xe5\x3c\x9a\x76\x05\x90\x04\xf8\x2a\x2b\ \xa2\xb4\x85\x91\x2d\x96\x10\x4f\xa7\xc5\x65\xe5\x91\x62\xfa\x2e\ \xe6\xa8\xf2\x62\x21\x06\xd4\xfd\xf6\x3f\x40\x56\xee\xdd\x76\xc7\ \x1d\x78\xfb\x9d\xb7\x11\x8b\x55\xa0\xa7\x47\x17\x17\x6a\x63\x53\ \x02\x4f\x2c\x0d\xe3\xd0\x05\x9d\xa8\x1e\x95\x80\xe5\x8a\xc0\x4c\ \xf1\x6a\x4d\x4f\xef\xaa\xca\x7e\xaa\x46\x17\xbb\x04\x2d\x50\x8d\ \xbc\xf7\x50\x14\xcd\x59\xe0\x29\xc7\x4a\x14\x00\x7c\x3c\x04\x87\ \xdd\xdd\xdf\x1e\xdd\x55\x20\xe5\xcf\x49\x97\x60\x1e\xdd\x95\xcc\ \x64\xe9\x46\xb6\x9b\x88\x5a\x4e\x9a\xaf\x7f\x80\x45\x46\x82\x13\ \x5b\xe0\xa6\x22\xe1\x60\x80\xac\x5a\x50\xd8\x43\x3c\x95\x41\x32\ \x9b\x95\xd7\xf9\x35\x29\x05\xde\x8a\xa5\xd0\x36\xff\xc1\xea\xfb\ \xd9\xb2\xfa\x5e\xfa\x28\x36\x46\xdb\xca\x70\xd1\x8f\x62\xad\xb4\ \x6d\xfe\xb2\xf9\x13\xd6\x16\x0f\x96\xe3\x12\x70\x6b\xef\x2f\x5c\ \xf6\x05\x3c\xf2\xc8\xc3\x78\xe4\xd1\x87\x1d\x70\x00\x12\x89\x1c\ \x96\xaf\xcb\x63\x7d\xab\x17\xd3\xb3\x3d\xd0\x3c\x74\xad\x5d\x21\ \xda\x7c\xe8\xdf\x66\xcd\x0e\xbc\x64\xe9\x8e\x0e\xa0\x10\x3c\x12\ \x19\xeb\x64\x09\xfe\x01\xa5\xad\x9e\xa7\x12\x05\x00\xdb\xa4\x6b\ \xe5\x7e\x00\x72\x7b\xc9\xba\x7e\xad\x57\x61\xb8\xfd\x77\x67\xa2\ \x07\x9b\x3a\xc9\x22\x45\xa3\x32\xae\xcb\xe3\xb8\x04\xe5\xae\x3e\ \xe5\x15\x80\xd2\x16\x4b\x62\x05\x2e\xa7\x01\x88\x89\x1e\xa2\xfb\ \x99\x7c\x4e\xd8\x82\xd7\xeb\x41\x24\x10\x40\x88\x1b\x7f\xf4\x57\ \x3e\xa7\x76\xdd\x9e\xae\xdb\x57\x33\xbc\x5d\xe5\xec\x37\x8a\x7c\ \x80\x2b\xb5\x99\x1a\x32\x1b\x29\x2f\x91\x2d\xa7\xe7\x7a\xcf\x4d\ \xd3\x06\x9e\x6b\x3f\xc5\x91\xa0\xba\xa6\x95\xa1\x70\x80\x22\x7f\ \x38\xf8\xb1\x27\x29\x69\xf6\x3f\xfd\x86\xa9\x68\xa8\xae\x0e\xe0\ \xdc\x73\xcf\xc3\xdc\xb9\x73\x71\xcb\x2d\x37\xe3\xad\xb7\xde\x26\ \x90\xd5\xd0\xde\x6d\x20\x57\x30\x05\x51\xad\x42\x86\xfe\x61\x45\ \x67\x06\xe0\x11\x7f\x5f\xde\xed\xa2\xcf\x0a\xc4\x50\x8a\x1c\x8b\ \xa2\x7e\x29\xdc\x16\x8f\x5d\xcb\xd1\xbe\x9e\x3e\x37\xac\xdf\xf9\ \x96\xbf\x67\x05\x00\x4a\x06\x58\x44\x1e\xc9\x25\xdd\x7a\x45\x49\ \x30\xe0\x86\x31\x9d\x7d\xc6\x8d\x1e\x03\xa3\xa9\x19\xeb\x5a\x5b\ \x65\xb2\x4f\x2c\x1a\x91\x15\x7c\x9c\x0d\x90\xd9\x7d\xa6\x1d\x8d\ \x36\x9d\xa8\xb7\x45\x16\x8e\xdf\xcb\xb1\x01\x8e\x72\x73\xe6\x20\ \x93\x4a\xc1\xa0\x9f\x35\x4e\x65\xa5\xd2\x92\xd3\xe6\xc2\x21\x29\ \x74\x91\x7d\xec\x5e\x79\x0c\x38\xbc\xb2\xcd\xfe\x59\x2f\xab\x90\ \x7d\xd3\x6b\x5a\xef\x2c\x32\x4d\xeb\xaf\x5c\xfd\x3a\x10\xe8\x7d\ \xe3\xcb\x74\x47\xf1\x75\xe7\xdc\xca\xca\x6b\x39\xfe\xb3\xad\xf4\ \x7d\xec\x82\x7f\x36\xcb\xc0\xd3\x0b\x4a\x5a\x6f\xab\x2d\xd3\x01\ \x28\xcb\x29\x67\xee\xbf\xe6\xa6\x0f\xcc\xb8\x57\x40\x1f\x68\xc8\ \x75\x2c\x99\x42\xef\x0d\x27\x55\x6a\x96\x47\xae\xcb\x88\x75\x13\ \x75\x8d\x63\xf0\xb9\x0b\x2f\xc1\x03\x7f\x5d\x82\x67\x9f\x7b\x11\ \xd3\x8c\x6e\xcc\x9c\xbd\x1e\x18\x5b\x0b\x3d\x41\x00\x50\x48\xdb\ \x39\x7e\x3e\x56\xbf\x97\x90\x34\x82\x92\x36\x0e\x79\xd7\x89\x30\ \xdd\x27\xd2\xf3\x01\xb8\x35\x2e\x00\xf2\xf7\x82\x96\xa6\x59\x7d\ \x6c\xc9\x61\x72\x79\xd5\x41\x58\x01\xc0\xe6\xc2\xca\xcf\x0a\x6a\ \x6a\x8e\x3f\x4f\x37\x27\x5b\x6e\xa3\x3c\x0a\x9c\x1e\xdb\x3b\x3a\ \xb1\x61\xdd\x7a\xbc\xff\xfe\x6a\x99\xde\x93\xa7\x9b\x38\x5c\x11\ \x41\x5d\x6d\x8d\xf4\xa9\xe3\xd5\x7c\x1c\xe0\x72\x91\x22\x97\x41\ \x80\x17\xc8\x24\xba\xe3\x58\xb7\xbe\x09\x2d\x04\x1e\x19\xf2\xfd\ \x99\x39\xb0\x2b\xc1\x55\x70\x21\x62\x12\xa1\x50\x00\xe1\x50\x48\ \xfa\xea\x45\x22\x11\x49\x8d\x55\xd0\xc6\x9f\x1d\xa5\xdf\xb9\xed\ \x38\x1f\x9f\xe5\xe8\x35\x83\x46\x19\x04\x5c\x7c\x93\xeb\x8e\xe2\ \xdb\xda\x2e\x37\xbb\x6e\x69\xc2\x42\x4c\x47\x39\xcb\x29\x72\x89\ \x3b\xf4\x1b\xa6\xd1\x07\x76\x8e\x42\x6b\x70\xea\x15\x9c\xe7\xcd\ \x72\x40\xb3\xbf\x15\x45\xef\x8a\xc5\xde\x05\x4e\x1a\x7a\x47\x9e\ \x5b\x4e\xc6\xa3\x6c\x81\xf9\x78\x58\xe9\xba\xe2\x71\x74\x75\x76\ \xa1\xbb\xbb\x1b\xf1\x78\x52\x22\xff\x89\x9e\xa4\x34\xf8\xe4\x5e\ \x02\x9c\x4e\xe5\xe9\xdf\x7c\x3e\xde\x68\x2d\x8a\xf9\x00\xbe\x77\ \x97\x1b\x07\xb4\xb8\x31\x75\x4a\x04\xb5\x81\x12\xbc\xba\x89\x78\ \x8e\xd8\x41\x8f\x1b\xeb\xd6\x54\xa2\xbd\x6b\x06\xea\x1b\x62\x98\ \x3c\xe9\x5d\x4c\x9c\xd8\x20\xd7\x8f\x81\x93\xcf\x5d\x26\x3d\xbb\ \xec\xc7\xf2\x75\xe3\xe3\xca\xe5\x72\xbb\x3c\x0b\x50\x00\xb0\x19\ \x65\x4e\x26\x93\x4e\x47\x5b\x97\xdc\x28\xba\x33\x05\x58\xb7\xff\ \x11\xcf\xbe\xa1\xae\x1a\x41\xbf\x07\xb5\xd5\x95\x98\x30\x61\x1c\ \xda\xba\xba\xd0\x95\x48\xc2\x20\xcb\x56\xc8\x15\xe1\x61\x6a\x4a\ \x9a\xc0\xe0\xc1\xf1\x02\xbe\xe1\xe3\xdd\x49\x99\x75\xc7\x41\xc0\ \xa9\x53\x26\x21\x1c\xe4\xd6\xe3\x3e\x29\x02\xe2\x61\xa1\x41\xfa\ \xd9\x4f\xc0\xc1\xbf\x07\x82\x7e\x29\x09\xe6\x05\x42\xcc\x2a\xb8\ \x7e\x9e\x47\x8a\x73\xa1\x10\x33\x82\x5e\xf7\xa4\x9f\xc5\xd6\x9c\ \x51\xe5\xbd\x2d\xc7\xe0\x0c\x32\x75\x14\x5a\x46\x90\x5b\xf6\x7e\ \x56\xef\x38\x72\xb3\xb7\x46\x41\xce\x55\x3e\xbb\xfc\x68\x7f\x96\ \xe6\xac\x4a\x14\xb7\x81\x3f\x53\x66\x9e\xeb\xbd\x85\x4d\xae\xde\ \xa0\x84\xd9\xeb\xb2\x94\x99\x80\x0d\x0e\xae\x3e\x46\x60\x41\xba\ \x27\x7b\x3c\x5e\x54\x56\x54\x90\x02\x36\x22\x9b\xcd\x22\x9b\xc9\ \x92\xe2\x67\xec\x81\x1f\xf4\x7b\x3a\x43\x8f\x99\x3c\xd1\xfe\x9c\ \xdd\x32\x9d\x00\x38\x95\xd5\xb1\x62\x8d\x85\xae\x94\x17\x13\x46\ \x05\x10\xab\xf0\x21\x91\x02\x36\x6e\x2a\x22\x12\xaa\xc2\x5e\x13\ \xab\x30\xa6\x31\x86\x1a\xfa\x4e\x82\xe1\x90\x64\x54\x7a\xbb\x01\ \x59\xf4\x19\x85\x92\x03\x52\x36\xeb\xb0\x9c\x1e\x0c\x8a\x01\x0c\ \x61\x65\x1c\xac\xf4\x09\x07\xa0\x4a\x32\x17\x10\x03\x7d\xe2\xb2\ \xab\x40\x0a\xc0\xe3\xba\x78\x68\xc7\x6e\xd3\x26\xf7\xbe\x56\x6e\ \xee\x61\x4a\xf5\x9f\x35\xc0\xbf\xd6\x9d\x1b\x52\x77\xba\x04\x6d\ \x1e\x26\xb3\x36\x0b\xc2\xf5\x4f\x85\x4a\x6c\x81\x2d\x2f\xdf\xb8\ \x9b\x45\x06\xcb\xc1\xc9\xad\x06\xf3\x9c\x0f\xb6\x36\x8b\x21\x58\ \xdb\x89\x29\xf4\x3f\xdf\xad\x3d\x6e\x3d\x78\xe8\x50\x6c\x6b\xfb\ \xd1\x80\x32\x54\xf8\xc9\xaf\x0f\x78\x49\x89\xa3\xa1\x01\xe3\xd5\ \xad\x7e\xd7\x42\xdb\xec\x98\x74\x69\xa1\xae\x09\x33\x30\x4c\x9b\ \xca\xb8\x5c\xf6\xf3\xba\x66\xe7\x5d\xf8\xba\xf3\xa2\xab\x12\xd7\ \x65\x38\x2e\x49\x7f\xb6\x52\x3e\xba\x9d\xad\xf8\x2a\x0d\x38\x4c\ \xe3\x01\xd8\x46\x40\x8d\xef\x42\x06\x89\xcd\x5b\x4d\x7d\xe8\x1b\ \xcb\xb2\x76\x58\xd1\x4f\xaf\x22\x6d\xe7\x98\xb6\xf7\xda\x07\x01\ \x8b\x8f\x9a\x2d\xb0\xb6\x1b\xc7\xfc\xa0\xd7\xd0\x92\x89\x43\xfd\ \x5d\x98\xed\x9d\xd3\x87\xfb\x6c\xc5\x00\x94\x7c\x04\x90\xf8\x08\ \x1f\xb0\x43\x6f\x49\x6d\x28\x9d\xeb\x27\x7e\x5c\xda\x56\x14\x5c\ \xc9\x87\x15\xb5\x16\x40\x89\x12\x05\x00\x4a\x94\x28\x51\x00\xa0\ \x44\x89\x12\x15\x03\x18\x6c\x19\x29\x5d\x81\x95\x28\xe9\x7f\x3f\ \x2b\x00\xf8\x40\x07\x64\xd0\x56\x32\x7c\x2e\xa0\xe4\x52\x37\x8f\ \x92\xe1\x2f\x7c\x2f\x5b\xc5\x2c\xaf\x49\xe6\xd2\xc3\x0c\x3f\x7a\ \xb4\xa1\xd1\xad\x48\x1b\x0c\x64\xba\x79\x69\xfe\x27\xef\x76\x96\ \xe6\x79\x5d\x5b\x5e\x85\xce\xce\x4e\x5e\x5c\x33\xaf\xb6\xa6\x26\ \x26\x0d\x1e\x94\x28\x19\xe6\xc2\x65\xdd\x6f\xbc\xb1\xb4\x2b\x91\ \x48\x74\x40\xd3\xe2\xa4\x76\x99\xb9\x73\xe7\x9a\xb1\x58\x0c\x05\ \xc3\xd2\x2f\x9a\x17\xb8\x62\x7c\x4c\x5f\xba\xcb\x30\x80\x77\x3b\ \x8c\xfd\x5f\x69\x2e\xee\xcb\xad\x9e\xb7\x38\x20\x77\x95\xe4\x74\ \x9a\x5a\x4b\x2a\x44\xa1\x64\xc4\x88\x7f\xd2\xbe\x55\x21\x5d\xaf\ \x2a\xff\xbe\x2e\x9b\xc5\xea\xe6\x22\x72\x25\x0b\xa7\xed\xe1\xaf\ \xde\xa5\x5c\x00\x8f\x0b\x59\x2f\x29\xbf\xd7\xbd\xb5\xe4\xad\x21\ \x95\x22\xba\xa2\xff\x4a\x46\x90\x18\x85\xec\x80\xbe\x44\xdc\x1d\ \xd9\xc5\xb3\x0e\x20\xcb\x36\x8c\x5d\x0a\x00\x4c\xa7\x2e\xdd\x1c\ \xc1\x31\xbe\xd2\x66\xe7\x66\xf7\x05\xc0\x76\x6b\x65\xf9\x66\xd8\ \xfc\x9a\xb8\x34\x55\xbf\x36\x92\xa5\xbc\xa2\x72\x97\x02\x80\xf2\ \xe2\x32\x73\x84\x46\xf9\xb9\x2a\xad\xca\xcb\x2b\xf4\xcc\x5e\xed\ \x2f\x9a\x1a\x12\x45\x7d\x9b\x0d\x2a\xf9\xd9\x00\xb1\x9e\x90\xdb\ \x1a\xd0\xe9\xa3\x87\xde\x53\x30\x87\x17\x08\xf0\xd1\x97\xe8\x98\ \xbd\x2e\x35\x9a\xfb\xdf\xdc\x29\xbd\x1d\xa3\x77\x2d\x06\xe0\x2c\ \x1a\x19\x89\xad\x1a\xf9\xdc\x42\xba\x85\x2b\xe6\xbb\x31\x3a\xca\ \xf9\x0c\x0b\x3e\xf2\x79\x5e\x79\xbf\x13\xd7\xfd\x33\x85\xaa\xfa\ \x31\xd2\x3e\x6c\x73\xc9\x97\x80\x83\x46\x03\x9f\x9b\xed\xa1\x9f\ \xed\x3b\xc2\x47\x14\xf1\xaa\x25\xab\xf0\x3e\x46\xc9\xb8\xf0\xa1\ \xac\x4c\xe5\xb5\x07\x05\x3a\x35\x0f\x31\x9d\x09\x51\xf2\x73\x7b\ \x8c\xde\x1e\x06\x4a\xb6\x76\xcd\x9c\xe5\xd6\xd8\xd5\x00\xc0\xa1\ \xc8\xee\x11\x68\x1c\xca\xcd\x40\x2b\xfc\x1a\xaa\xc3\x6e\x14\xe9\ \x09\x0f\x37\x0a\x29\xf5\x20\xd9\xb6\x09\x95\x8d\xe3\x60\x96\x8c\ \xad\xbe\xcf\x4b\xc0\x11\x0b\xf3\x30\x51\x27\x56\x42\x9a\x94\x69\ \x5d\x83\x42\x55\xad\x34\x2a\x19\xca\x00\xc0\x16\x9f\x95\x7f\x7a\ \x25\x70\xce\x6c\x02\xab\x64\x1b\xfe\xe3\xa1\x2e\xd4\x4e\x98\x02\ \xcb\x50\x5d\x79\xb7\x77\xbf\xec\x7a\x00\xe0\xb8\x00\x23\x31\xcb\ \x27\x8d\x6a\xa5\xfd\x97\xd5\xbb\x79\xb8\x57\xa0\x69\xc9\xf9\x1a\ \xdb\x18\x58\x23\xaf\x71\xfc\x53\xde\xe3\x00\x80\x6e\xf5\xee\xcf\ \x8f\x43\x55\xff\xf9\x9c\xab\x7c\xc0\x09\x93\x75\x1c\x37\xd5\x85\ \x68\xd8\x8b\xa7\x5f\xea\x41\x3a\xde\x81\x6a\x6b\x1a\x1d\xbf\x02\ \x80\x6d\xd1\x26\xd3\x1a\xdc\xef\xd5\x3d\x68\x4a\xe2\x6c\x23\x12\ \x00\xfa\x35\xeb\xec\xef\x17\x9b\xbd\x0c\x61\x1b\xcc\x61\x1b\xfe\ \x74\xf9\x33\x87\x2a\x00\x64\x8b\xc0\x19\x73\x34\x7c\x7a\x86\x1b\ \xf9\x02\x9c\x65\xce\x9a\xb4\x02\x33\x46\x78\xb0\xf7\xe3\xba\x4d\ \x83\xad\x03\x83\xc6\x00\xd8\x22\x96\x46\xe0\x1a\xce\x32\x03\xe8\ \xdf\x2a\x0b\x4e\x1b\x2d\x3e\xef\x92\xd9\xd7\xce\x6e\x73\x06\xd0\ \xbf\xb5\x96\x28\x7f\x79\x9c\xb8\xb5\x6d\x4b\xa1\x6d\x06\x12\x65\ \xe1\x8e\x38\x6e\xfd\xc3\xdd\x5d\x72\x6c\xfd\x28\xa9\xb4\x14\xe3\ \x19\x1b\xe5\xc6\x22\xdb\x78\x1f\x3f\xef\x71\x71\xaf\x3f\x9b\xb1\ \xf4\x3f\xdf\xed\x31\x3d\xd3\xf9\x9b\x76\xe3\x0e\x38\x7d\x0b\x77\ \x9d\xcc\x07\x9f\xaf\x0c\x8a\xd9\x35\x01\x80\xb6\x11\x12\x1f\xd2\ \xb6\xe2\xde\x58\x03\x7a\xe5\x59\x03\x15\xc2\xda\x92\x1d\x94\xca\ \x96\x72\x33\x00\x60\xb0\x28\x3a\x5b\x7f\x00\xd0\x9c\xbf\x95\x33\ \xec\x9f\xeb\xfd\x16\x62\x7e\xa9\xb1\x90\xb8\x43\x3c\x6b\xa1\x25\ \x6b\xb7\xef\xe2\x82\xab\xed\x65\x1f\x72\x25\xfb\x33\x6a\xe9\x33\ \x2a\x7d\x96\x44\xef\x21\xcf\x5b\x48\xe4\x2c\xb4\xe7\xe8\xdd\xda\ \x96\x9f\xc3\x7b\xf1\xdf\x4f\x17\xe0\x04\x2e\xfb\x8e\x9d\xab\x38\ \x93\x79\x03\x3d\xf4\x9a\x46\x88\xc8\x01\x4d\x69\xc3\xd5\x2f\x5e\ \x10\xf2\x00\x0d\x01\x4b\x1e\x59\xf1\xb9\xa5\x7a\x3a\x6f\xa1\x23\ \x07\xa4\x0c\x97\xd4\x89\xb0\x1b\xd4\xff\xd0\x47\x12\x99\xd0\xac\ \xc1\x77\xed\x06\x07\x00\xd8\xfa\xd3\xe6\x1a\xca\x31\x00\xeb\x83\ \x69\xbd\xb6\x19\x08\x88\x92\x6b\xd6\x56\x3f\x44\x5e\x33\x9d\xd9\ \x80\x56\x9f\xe5\xb3\x1c\x1a\x5d\xdc\x0a\x1f\xe4\xe7\x92\x39\x13\ \xa6\xc7\xb4\xdb\x5a\x3b\xcf\xe7\x0d\xfb\xe3\x0f\x1f\xab\xe1\xf8\ \x29\x3a\xa6\x57\xeb\x88\x7a\xfb\x00\xa0\x87\x14\x77\x45\x47\x09\ \x7f\x5b\x91\xc3\x63\x4d\x3a\x34\xb7\x4f\x82\x8c\xbd\x9d\xb1\x1c\ \xff\x93\xbf\x87\x43\x46\x69\x38\x79\x37\x1d\xbb\x55\x93\xff\xee\ \xed\x0f\x00\xa4\xc4\xa4\xc0\xef\x77\x19\xb8\x6f\x79\x16\x4f\x36\ \xeb\xd0\x3d\x5e\x62\x04\x76\x83\x4f\x4e\x4f\xfe\xbf\x05\x6e\xcc\ \xa8\xd1\x30\x2a\x64\x49\x26\x43\x5c\x82\x7c\x11\x7b\x4c\x1e\x85\ \x5b\xce\xaf\x45\xa4\x42\xc3\x5b\x1b\xb2\xf8\xc9\xbf\xb2\x88\xc4\ \xaa\xe4\x33\xeb\x09\xa8\x4e\x98\x06\xec\x3f\xd6\x85\xda\x80\x0d\ \x04\xd2\x81\x98\x8e\x25\x5d\xb0\xd0\x49\x00\xf0\xd2\xc6\x02\xee\ \x5f\x65\x60\x53\xde\x87\x00\xa7\x15\xfa\x75\x4f\xb2\x3e\xe4\x77\ \x34\x94\x0d\x47\x69\x57\x64\x00\x76\x40\xcc\x0e\x90\x0d\x49\x6b\ \xae\x6d\xfe\xdc\xd6\x07\x68\x94\xad\x30\xfa\x29\x32\x9f\x92\xa7\ \xdc\x41\xb8\xdc\x8f\xcf\xb2\x27\x01\x77\xa7\x0d\x78\x32\x26\x8c\ \xa2\xd9\xdb\x3c\xd3\x79\x19\x19\x02\x80\x8c\x33\xe2\xaa\x7f\xcb\ \xee\x7c\x89\xbb\xdf\x1a\x28\x79\x0c\x87\x5a\x93\x82\xd1\x8f\xa3\ \x49\x71\xbe\x75\x80\x1b\xc7\x4c\x75\x83\xc7\x0e\x14\xcd\x3e\x37\ \xc1\x43\x96\x33\xec\xd7\x30\xbe\xca\x8d\x23\x26\x7b\x71\xd7\x1b\ \x71\x5c\xf7\x5c\x06\x9d\x7a\xc4\x5e\x98\xe2\xfc\x5d\x0e\x36\x5e\ \x31\xcf\x85\x2b\x48\x89\xf9\x3d\x45\x01\x64\x97\x93\xba\x23\x20\ \xa0\xf3\xa8\x08\x02\x13\xe9\x73\x0e\x9b\xe4\xc1\xef\x9e\xef\xc0\ \x75\x2f\x66\xe0\x0e\x45\xa1\xd3\xb1\x64\x49\xe1\xa7\x55\xba\xb0\ \x0f\x81\x50\x36\x67\xcf\x3d\xb4\xad\x3f\xb1\x91\x48\x10\x07\x55\ \x6a\xd0\xbd\x3a\x52\xcd\x6d\x68\x59\xdb\x82\xec\xf4\x05\x98\x1a\ \x36\x71\xe3\x21\x6e\xcc\xac\xd7\xe5\xef\x19\x96\xdd\xf6\xdc\x6e\ \xc3\x6e\xc2\x4f\x00\x54\x17\x05\x66\x37\xb8\x71\xf8\xb8\x0c\xbe\ \xf1\x68\x07\x96\x67\x2a\x11\xf4\xba\x7a\xd9\x87\xbe\x9d\xf6\x5e\ \xd6\xe6\x74\xc1\x1a\xba\xac\x81\xcf\xa3\x64\x0e\x6e\xcf\xc0\x41\ \x72\x01\x6c\x85\x30\x77\x72\x0c\xa0\x7f\xf3\x4d\xed\xdf\x18\x7e\ \x6b\x3b\x74\xc0\x42\xd9\xc7\xef\xa3\xfc\xe5\xc2\x26\xbe\xa9\x35\ \x97\x29\x33\xec\xfa\x53\x7f\x9f\xd7\x8d\xba\xa0\x8e\x0a\x14\x60\ \xe9\x25\x99\x7d\x57\xee\x51\x2f\xd6\x96\xb6\xb0\x4b\xef\x6b\xc3\ \xed\x3c\xb2\x52\xf1\xe4\xe0\x82\xdc\x29\xa6\x7c\x7e\xad\x0f\xf8\ \xf9\x11\x5e\xec\x37\xde\x8d\x14\x59\x4c\x66\x03\xfc\xf9\x3e\xa7\ \x83\xaf\xcd\x10\x4c\xb2\xa6\x76\xe7\xdb\x33\xf6\xa9\xc2\xd8\x50\ \x27\x2e\x78\xa0\x0d\x3d\xfe\x5a\x78\xe8\x6f\x33\xe0\x2c\x9e\xaa\ \xe3\xeb\xfb\xbb\x85\xc6\x17\xe9\xf7\xa0\xcf\x83\x54\x2a\x85\x78\ \x22\x25\x5d\x90\x6b\xab\x49\x13\x75\x0f\x7d\x8e\x21\x9d\x82\x2f\ \xf9\x54\x2d\xd6\xb7\xad\xc2\x2f\xde\x05\xa2\xd1\xb0\x1c\x97\xed\ \xb8\xf3\x6d\x64\xf4\xb6\x00\x2f\x2b\xa2\x26\xf5\xdc\x1e\xb9\xda\ \x49\xa2\x38\x51\x42\x9c\xef\xec\xaf\x8b\xf2\x27\xf3\x96\xb4\x45\ \xe7\x38\x45\x7b\x47\x97\xcc\x59\x8c\x86\x03\xa8\x88\x46\x88\x0d\ \x99\xc8\xd1\x79\x8c\xaf\x0b\xe3\x3f\x0f\xca\xe3\x8c\xbb\x37\x22\ \x11\x19\x2b\x0c\x46\xd7\xca\x2d\xd1\xed\x38\xc7\xc7\x31\xfe\xfd\ \x9b\x8f\x0e\x86\x0a\x72\x0b\x75\x63\x90\x8d\xe0\x20\x01\x80\xe9\ \x6c\x83\xc3\xd1\xfa\x1a\x66\x6e\xe5\x4b\xe9\xf5\xd3\xb7\x54\xf0\ \x5e\x3f\xbe\x1c\xb4\xc3\x40\xf4\x96\x81\x13\x9c\xcf\x77\x9b\xce\ \x5c\x40\x1b\x00\x32\xb9\x02\x66\x11\x25\x7e\xe8\xf2\x5a\xa7\x1e\ \xd8\xb3\xe5\x2d\x4a\xfb\x79\x89\xea\x66\x8b\xd6\xc0\x46\x9c\xce\ \xb5\xb2\x9c\x8d\x9b\x15\x7f\xe3\x20\x0f\x29\xbf\x8b\x68\xbe\xad\ \x70\x41\xbf\x17\xcb\xdf\x5b\x8b\x07\x9e\x5f\x89\xf6\x8c\x85\x29\ \xa3\x6b\xf0\x99\x7d\x27\xa3\x86\x14\x38\x5f\x24\x3f\x3c\xa3\xe1\ \x53\x33\xaa\x71\x65\x73\x02\x57\xbe\xd0\x09\xbd\xa2\x0a\x01\x02\ \xa9\xb3\xf7\xf0\xda\x60\x6c\x6a\x12\xb3\xff\xdf\xdb\x9f\xc0\xed\ \x2f\x36\x23\xe5\x8e\x42\xf3\xf8\x30\xb9\xda\x8f\xeb\x4e\x9e\x81\ \xe9\xe3\xab\xed\xef\xca\xe3\xc6\xe5\x07\xd7\xe1\x81\x95\xeb\xd0\ \x5a\x9a\x48\xcc\x43\xc7\x13\xcb\x3b\xb1\x76\x59\x13\xf6\x9c\x3e\ \x06\xe3\x1b\x6b\xa4\x2b\x2f\x4f\x42\x6a\x69\x8f\xe3\x99\xd7\xde\ \x93\x71\x68\x6f\xae\x6e\x85\xe1\x0a\xe1\xa0\xd1\x16\xe6\x8f\x72\ \x91\xf2\x9b\xd2\xe2\x7c\xe5\xea\x8d\xb8\xfe\xd6\x7f\x62\x65\x92\ \x8e\xc3\x1b\x92\xe9\xc8\x67\xec\xd3\x80\x4b\x17\x4e\xe7\x55\x61\ \x04\x29\x1a\x76\x9b\x52\x87\xd3\xa6\x6c\xc2\x0d\xef\x74\x92\x3b\ \x11\xe3\xe5\xab\x72\xe9\x74\x27\x40\xa9\xa3\x0c\x08\x5a\x2f\x38\ \xf4\x07\x08\xbd\x77\x50\xca\x40\x25\x2f\x7f\x6d\x83\xe9\x85\x6a\ \x56\x9f\x21\xd9\xe5\x62\x00\x32\x68\xc3\xf8\x64\x01\xc0\xda\x06\ \x8d\xdf\x3c\xe0\x66\x59\x7d\xca\x3b\xf0\x77\x27\x4f\xef\x0c\xc4\ \x28\x53\xea\xb2\xf2\x97\x53\x71\xdb\xfb\xbe\x4a\x92\x05\x30\x07\ \x06\xae\x78\x28\x28\xdd\xdc\xb5\x95\xee\xed\x46\x7c\xb6\x56\x1e\ \x5d\x1e\xe1\xc5\x1b\xbb\x03\x0b\xea\xc8\xe7\x9f\x46\x96\x3f\x6f\ \x03\x45\x30\xe0\xc5\x43\x4f\xbd\x82\x2f\xfc\xdf\x4b\x68\xab\x9c\ \x01\x6f\xac\x01\xc6\x86\x12\x6e\x5f\xf9\x3e\x7e\x73\xda\x44\x4c\ \x6c\xac\x10\xf6\x90\x22\xa5\x3b\x7d\xbf\x51\xb8\xfb\xad\x65\x78\ \x36\x13\xc2\x8c\x2a\x17\xc6\x45\x2d\xf2\xe3\x35\xb1\xee\xa9\x44\ \x0f\x6e\xfa\x47\x13\xde\x09\xef\x8d\x50\x75\x8d\x54\xf3\xad\xe4\ \xde\xfc\x8f\x24\xf0\xbb\x93\x74\x74\xf7\xa4\xf0\x5e\x53\x37\xd6\ \x37\x77\xc2\x4c\x96\x60\xfa\xc6\x90\xc2\x7a\xf1\x5f\x2f\x15\x10\ \xdf\x94\xc3\x9f\x4e\x2f\x62\xda\x18\xdb\xad\xf0\x11\x00\x2c\x27\ \xca\x7f\xfe\xff\x2d\x43\x70\xe2\x1e\xa4\x88\x15\x08\xd6\x8f\xc6\ \x9c\xca\x92\x0c\xf5\xe4\xe3\xf6\xba\x75\x3c\xbb\x74\x35\xee\x58\ \x13\x85\x7f\xb7\x7d\xe4\x77\xa6\xf8\xdf\x79\xb5\x07\x8d\x35\xed\ \xe2\x72\xac\xd8\xd8\x85\xf5\xad\x71\xbc\xfb\x5e\x3b\xcc\xcc\x04\ \x14\xc2\x15\x3c\xa9\x65\x0b\x30\xd7\x7a\x15\xbf\x4f\xe1\xf5\x32\ \x48\x94\xe7\x3a\x68\x7d\xfb\xf6\xce\x54\xe8\xf7\xfb\x56\xb9\x9e\ \xf5\xef\x19\xe3\xc7\xcd\x02\x88\xab\xb8\xcb\xad\x05\x30\x9d\xde\ \xf9\x3b\xc8\x05\xd8\xd6\xe5\x34\x7b\x95\xdc\xea\x4d\x9b\x95\x03\ \x72\xbd\x8a\xff\x31\x23\xce\xb6\xd1\x36\x37\xcb\x00\xd8\xd6\x4a\ \x28\xb1\xb5\x5d\x64\xb4\x67\xf7\xf5\x53\x7e\xab\x3c\xd3\x8e\xb6\ \x22\x59\xf3\x13\xa7\xf9\x10\xf6\x11\xa5\x2e\xd8\x93\x86\x9b\xc9\ \xbf\xfe\xc6\x9f\x5f\x46\xf7\xf8\x43\x51\x4d\x4a\x66\x39\x0a\xf2\ \x32\x71\xfc\xef\x3f\x4d\x4a\xbd\x38\x28\x43\x32\x39\xde\x12\x09\ \xf8\x71\xd2\x34\x0f\x9e\x78\x96\x14\x2a\x56\x2f\xdf\x01\x7f\x3e\ \x4f\x3e\x0a\x47\xc2\xf8\xdd\x97\x17\x62\x09\xd1\xfb\x17\x5a\x4d\ \x6c\xe8\x21\x65\xf6\xfa\xf1\x5c\xc2\x8b\x85\x37\xad\x41\xaa\x75\ \x3d\x5a\x0b\x3e\x68\xc1\x4a\x02\x88\x7a\xa2\xee\x3c\xf8\xa4\x08\ \x7f\x30\x84\x8a\x09\x33\xe0\x0e\xba\xa4\xe0\xa7\x7c\xcc\xec\x42\ \xf8\x1b\x27\x20\x36\x71\x26\x2c\xda\x2f\x9d\x2f\xc1\x28\x95\x7a\ \x5f\xcf\xe4\x8a\x58\x74\xc4\x3c\x84\x1a\x92\x78\x60\x83\x86\xf7\ \xbb\x4d\xac\x4f\x11\x83\x0a\x54\xe2\xca\x67\x12\xa8\xb8\xef\x2d\ \x34\x75\x67\x91\x26\x36\xe2\xaf\x18\x87\x60\x55\x0d\x2c\x99\xd5\ \xb0\x75\xe7\xcc\xd8\x8e\x0b\x20\x60\x40\xff\xb8\xb4\x81\x3f\xcb\ \xa6\x3b\x63\xd3\x3e\x66\x4c\xf8\xa3\x02\x80\x31\xc8\xa5\x80\x83\ \xb4\x18\xc8\xfa\x68\x2e\x80\x85\x2d\xb8\x5c\x7f\x0c\x29\xff\xdc\ \x97\x7f\xb6\x06\x50\xf8\xb2\xe2\x5b\xe8\xa3\xf7\x7d\x53\x6c\xb6\ \x16\xfc\xfb\x88\x00\x60\x0d\x04\x00\xb6\x36\x3c\x21\xa8\x65\x6d\ \x87\x33\xad\x67\xeb\xd7\x84\x47\x82\x55\x57\xc5\xb6\x18\x0e\xc2\ \x6e\x00\x33\xa6\x08\xb9\x16\xb3\xea\x74\x3b\x5b\xc0\x56\x94\x28\ \xf8\xd3\xaf\xbe\x87\xf7\xb4\xd1\xa8\xae\x6d\x80\x59\xcc\xf5\x7e\ \x5e\xd8\xab\xe1\x1f\x6d\x5e\xac\x68\x2d\x60\xf7\x46\xbf\xa4\xe9\ \xf8\x7d\xb3\xc6\x46\x10\x2b\x6c\xc4\xba\x64\x2d\x56\x77\x15\x31\ \x8a\x58\x49\x81\xdc\x0e\xc2\x13\xcc\x9e\x50\x89\xbd\x26\x5a\x48\ \x10\x78\xac\x8d\x9b\x78\xa7\xad\x88\x97\x9b\x4c\x3c\xdf\x3c\x0a\ \xdd\xae\x46\x62\x31\x7e\x89\xc8\x6b\x66\x3f\x7f\x5f\x26\x72\x93\ \x62\x9b\xbe\x2d\x53\x9f\xa4\xf8\x66\xa9\x20\x8f\x7c\x1a\xaf\x6e\ \xe2\x79\x80\x86\xcc\x17\xe4\xe8\x77\x80\x5c\x97\x33\xf7\xad\xc1\ \x67\xf7\x2a\xa1\xb5\xc7\xc0\xf2\x4e\x03\xef\xb4\x14\xf1\xcc\x46\ \x72\x1b\x5c\x7b\x20\x17\xf3\x20\xe2\xf3\x82\xbb\xe7\x08\xb0\x59\ \x1f\xbc\xa2\xb0\x3f\xb5\x97\xb4\xab\x33\x6a\x4c\x00\xa1\x6c\xf9\ \x9d\x19\x8a\x65\x20\xe8\xef\x42\xf4\x07\x8c\xfe\x41\xde\xfe\x71\ \x9b\x8f\x9d\x75\xe8\x37\x8e\x6d\x17\x73\x01\x9c\x81\x90\xff\x86\ \x01\x58\x5b\xbb\xb6\xda\xc0\xc0\x8d\x65\x6e\x49\xeb\xcb\x05\x2d\ \x7d\x00\xd0\x07\x04\x9b\x07\x7e\xb4\xed\xc0\xfc\x47\x67\x00\xd6\ \x00\x10\x08\xf8\x3c\xf8\xd7\x9b\xab\x70\xd6\x7f\x3f\x83\xc8\xa8\ \x09\x9b\xcd\xb4\x77\x52\x67\x05\x03\x17\x1d\x30\x06\x57\x2f\xae\ \xa4\x9f\xcd\x01\x31\x00\x5e\x3c\x54\x34\x4a\x18\x1d\x34\x51\x17\ \xe0\x88\x7f\x99\x19\x18\x58\xd9\x94\x80\x9b\x68\xbf\x65\x16\x07\ \xd0\x63\xbe\xc9\x3b\x0b\xc0\x2a\xb2\xac\x33\x1b\xed\xfd\x79\xc4\ \x56\x5d\xd4\x8f\x06\x6f\x0e\xef\xe6\x8b\xf8\xcd\x4b\x69\xec\x3d\ \xc6\x0d\x1f\x51\x79\x8e\x15\xc8\xc6\x11\x0a\xaf\x1b\x33\x1a\x80\ \x59\x8d\x5e\x9c\x3e\x07\xe8\xce\x94\xf0\xf2\x86\x1c\x6e\x79\x23\ \x8d\x47\xd6\x5b\x70\xf3\xdc\xc3\x7e\x57\x47\x66\x01\x5a\x9b\xb3\ \x1e\x27\x6e\xc1\x0a\x4f\x1b\x91\x16\x3c\xb5\xbe\x88\x27\x96\x25\ \x70\xcc\xec\x6a\x24\x72\x86\x04\x82\x53\x86\x4d\xc7\x6b\x2a\x3c\ \x38\xbc\xd2\x83\x23\xa6\xfa\x71\x19\x7d\x81\x6b\x3a\x8b\x78\x70\ \x45\x06\x7f\x7c\x33\x81\xa6\xbc\x87\x80\xc7\xf5\xb1\x12\xe6\x72\ \x6f\x18\x5b\x82\x43\xf9\x1e\xd0\x37\x73\x23\xca\x00\xe0\xd6\xb7\ \x74\x17\xfa\xbb\x0d\x96\xf5\x6f\xee\xd7\x0f\xc0\x00\x76\xcd\x18\ \x00\x4f\xd7\xd1\x3f\x9e\x0b\xd0\xdf\xaa\xdb\x75\xf6\xe5\x9f\xad\ \xed\x2a\xb1\xb5\x03\xa9\x5d\x39\xd7\x3f\x80\x01\x58\x76\x24\xbf\ \x33\x34\x0e\x46\xe3\x5e\x0e\x95\x1d\x28\x19\xb2\xc2\xd9\xb0\xdb\ \xb1\xae\x56\x3f\x36\x61\xd9\x80\xc9\xae\x01\xdd\xc1\x2e\x98\x03\ \x94\x8c\x53\x71\x3c\x2a\xdb\x24\x80\xd8\x62\x91\x01\xed\x93\x2d\ \x1a\x03\x8e\x85\x2d\x1d\x88\x29\xf8\xb4\x12\x1e\x5c\x6b\xe1\xab\ \x77\xaf\xc5\x55\x47\xd4\x62\x54\x5d\x8c\x3e\x59\x97\x78\x01\x5b\ \xe9\x5c\x3f\x63\xeb\xf7\xba\x70\xe4\xf4\x30\x0e\x9b\x12\xc0\x2f\ \x9f\x69\xc1\xf7\x5e\x24\xa6\x11\x08\xf7\xa6\xe5\x6c\x37\x6a\x20\ \x00\x88\x75\x93\xe3\x36\x7a\xdd\x92\x8c\xa9\xe3\x2b\x0f\x77\xa1\ \x90\x4d\xe1\x88\xd9\xf5\xf0\xfa\xfc\xc2\x4a\x8a\x74\x2f\xf0\xf5\ \x29\xfe\x7f\xf6\xae\x3d\x46\xae\xaa\x8c\xff\xe6\xce\x9d\xf7\xec\ \xce\xec\xce\x6e\xb7\x5b\xb6\xed\x52\xba\x65\xdb\x42\x6d\x4b\x01\ \x41\x4c\x45\x7c\x03\x82\x31\xc1\x10\x35\x24\x04\x12\x13\xd1\x48\ \x9a\xa8\x91\x18\x05\xf5\x0f\x0d\x88\x09\x6a\x48\x8c\x51\x21\x5a\ \x40\x4b\x83\x36\xb5\x40\x79\x75\xcb\xab\x2f\x4a\xcb\x62\xbb\xbb\ \xdd\x2e\xbb\x2d\xfb\x7e\xcd\xec\xcc\xdc\x3b\xf7\xe5\x77\xce\xbd\ \x77\x76\x66\x77\x8b\x15\x85\x99\x9d\x39\xbf\xe4\x64\xe7\x79\xf7\ \xdc\x33\xdf\xf9\x9d\xdf\xf7\x9d\xef\x9c\x93\xef\x18\x1e\x5c\xd8\ \xe0\xc7\xb6\xad\x01\x5c\xdf\x36\x83\x6f\xec\x1c\xc2\x9b\x69\x72\ \x05\x7c\x1f\x4c\xe6\x98\x35\x87\x14\x0a\xad\xd2\x2b\xcd\x2a\x04\ \x16\xbf\x2d\x54\x0b\xff\x17\x17\xa0\x1a\x63\x00\xcc\x28\xce\x49\ \x00\x56\xb1\x9c\xf7\x14\x48\x3a\xb3\xc0\x4f\x67\x1d\x5e\x2f\x18\ \xe1\x0b\x55\xc0\xff\x22\xe1\xff\x77\xf7\x86\x8a\x64\xcd\x3f\xdb\ \x0f\xec\x20\x4d\xea\xc0\xbc\x83\xcf\x27\x00\x2f\x27\x0a\xa9\xe8\ \x4c\xc1\x59\xff\xdf\xe0\x2b\xea\x74\x7e\x50\xe6\xec\x09\xbe\xac\ \xb0\xce\xc9\xd4\x14\x5f\x71\x37\x87\x00\x0c\x92\xfd\x2c\x03\x0f\ \xf9\x6b\x5a\xf6\xd9\x79\x8c\x80\xe8\x2f\x8b\xba\x3f\x7a\xca\x8f\ \x17\x7b\xba\x70\x7d\xab\x85\xeb\xd6\x35\x90\x1b\x90\x40\xa2\xae\ \x16\x12\x9b\x92\x24\xa9\x9e\xd3\xed\xd3\x91\xd9\x48\xcd\x0c\xff\ \x5b\x9f\x58\x8a\x63\xbd\x6f\xe2\x6f\xc3\x1e\x84\x43\x41\xfb\xda\ \x6c\x14\x33\xad\xf9\x0a\xc0\x51\x7a\x70\x56\x03\xb2\xb9\x8f\x41\ \x23\x82\xdb\xff\x31\x8e\x2b\x3b\x06\x70\x63\x7b\x14\x57\x5f\xdc\ \x88\x95\x4b\xe3\xfc\x74\x64\x36\x31\xca\x09\x81\xfe\xa7\x42\x84\ \xa8\x10\x23\x5c\xdc\x52\x8b\x9f\x6d\x9d\xc6\x2d\x4f\x0c\x22\x57\ \xdb\x5c\xa4\x3c\x3e\xb0\xdf\xb0\x30\xb6\x60\x14\x8f\xfa\xae\x42\ \x90\x1d\x42\x70\x55\x83\x57\x9a\x3f\xa5\x68\xfd\x87\x08\x22\xcf\ \x23\xd1\x4b\xbb\xc8\xa3\x74\x41\x40\x6e\xd4\xf3\x9d\x6e\xf7\x15\ \x37\x45\xd2\xcd\x85\x37\x2c\x3b\x7b\xd0\x9a\xe3\xdb\x7f\xd8\x81\ \x9b\xf3\x51\x00\xf3\x3b\x83\x95\x8f\x7b\xb0\xd1\x15\x0b\xac\x8e\ \x73\x8f\x1e\xb7\xe6\x12\x00\x58\xac\xc4\x80\x44\x65\x30\xa5\x61\ \x38\xad\xa3\xb9\xce\xcd\x31\xf0\x60\x4d\x4b\x02\xc6\xf1\x19\xfa\ \x7e\x63\xd1\x75\x59\xfb\x25\xfc\x16\xda\xea\xbd\x79\x97\x81\x19\ \xea\xe0\x58\x12\x43\xd3\x2a\xac\x04\xcb\xd8\x23\xff\xdc\x2b\xa3\ \x5b\x6f\xc6\x83\x6f\xa7\xf1\xf0\xb1\x11\xac\x0e\xbf\x83\x8d\x4b\ \x24\x5c\xb6\x22\x8a\x4b\x56\xd4\x63\xed\x8a\x04\x22\x35\xf6\x9c\ \x3f\x0b\x24\x5a\x3e\x92\xe9\xab\x83\x78\xec\xe4\x30\xcc\xe0\x0a\ \xfe\x3f\xe7\xd6\xbd\xf0\x7e\x4d\xe7\x7e\xd9\x1d\xb1\xce\xcd\xf8\ \x4b\xf1\xc7\xb1\x67\x32\x8c\x3d\xcf\x4d\xa1\x65\x5f\x37\x56\x47\ \x73\xf8\xd8\xca\x10\xd6\xb6\xc4\xf0\x91\x95\x09\x2c\x5f\x96\x80\ \x0e\xc9\x3e\xad\x39\xab\xe1\xd2\xd6\x3a\x5c\xe4\xef\xc2\x1b\x4a\ \x1d\x42\xfe\x0f\xdf\x64\x17\xb2\x23\xd7\x65\x70\xd5\x80\xad\x14\ \x3c\x45\xb3\x0d\x85\xf1\x83\x85\x2e\xc2\x42\x60\xa6\x61\x55\x61\ \x22\x10\x1f\x19\x74\x52\x00\xd2\xbc\x66\x76\xb3\xcd\x75\xb3\x60\ \x09\xad\x93\x10\x33\x1b\x34\x2c\xdf\x8c\x70\x2b\x9f\xee\x6b\x38\ \xd3\x77\x56\xfe\x2f\xef\x08\x26\x93\xea\xfa\x02\xa4\xc8\x3e\xe7\ \x9d\xfd\x2c\xec\xd3\x70\x6d\x32\xd1\x49\x1d\xe8\x98\xce\x99\x38\ \x76\x36\x83\x4d\x17\xf8\xf9\x67\xb2\x9a\x8e\x6b\xd6\x35\xa3\xed\ \xa5\xe3\x38\xa5\xa8\x88\xf8\x66\x13\x81\x58\x2a\xf0\xe7\x2e\x0e\ \x60\x55\x9d\x04\x25\x67\x77\x40\x26\x5f\x5f\xef\xec\xc3\x94\x27\ \x8c\x35\x11\x3b\xa1\x28\x10\x90\x70\x31\xf9\xdf\xb5\x44\x04\x7f\ \x3c\x2e\xe3\xa4\x21\xe3\xc4\x88\x82\x3f\xf7\x25\x11\xd6\x4e\x63\ \x6d\x5d\x2f\x7e\xf5\xd5\x0d\x58\x47\x64\xc0\xd4\x00\x0b\x46\x26\ \xa2\x3e\x18\xa9\x31\x58\x4d\x2d\xfc\x5e\x78\xdd\xad\xe2\xfb\x65\ \xaa\x81\xfd\xc6\x16\x57\x7b\x3a\x42\xf4\xcf\x57\xc7\x25\x84\x03\ \x1e\x24\x42\x5e\x6c\x48\x44\x71\x60\xc0\x83\x67\xcf\xc6\x31\x4a\ \x9f\xed\xe8\x9c\x01\x0e\x4e\xa0\x51\x3e\x8b\xdb\x2e\x5f\x82\xef\ \xdd\xbc\x9e\x9f\xf0\xcb\xc4\x4a\x94\x94\x46\xd8\x60\xc7\xaf\x67\ \x88\x80\xa2\x76\xe0\xa7\xc4\x30\x9c\xa2\xc1\x8d\x0f\x58\x0e\x19\ \x78\x78\xdc\x80\x3d\x66\x2a\xc1\x39\xa0\x7d\x01\x29\x60\xf1\x6f\ \x1a\x66\x69\xb7\x04\x29\x11\x01\xd8\xc7\x38\x5b\x5e\xab\x60\x56\ \xc0\x95\xf9\x76\xa7\xd7\xf3\x89\x38\x56\x51\x04\xb6\xdc\x91\x0f\ \x02\x3a\x53\x7a\x6e\x87\xb0\xf2\x45\x5f\x50\x01\xd8\xdf\x31\x16\ \x20\x00\x83\x07\x01\xdd\x28\xf8\xae\x13\x29\xdc\xba\x31\xca\x47\ \xff\x1c\x11\xc2\x92\x86\x18\xee\xbb\x7e\x05\xee\x7e\x66\x02\xef\ \x6a\xb5\x5c\x8a\xb2\xef\x5f\xde\xe4\xc3\xf7\xae\x89\xe6\xb3\x09\ \xd9\xd6\xd4\xd3\xd3\x49\xec\x78\xad\x0f\x88\x6c\xc2\x35\x4d\x16\ \x7e\xf9\x85\x7a\x72\x57\x98\xa1\x4a\x44\x30\x26\x4e\xf7\x9d\xc6\ \x13\x03\xe4\x6b\xd3\x88\x2f\x07\x42\x50\xcc\x26\x1c\x4c\x2b\x38\ \x3d\x65\xe2\x92\xe5\xba\xe3\xeb\x5b\x98\x9c\x9a\xe6\xf7\xe1\xde\ \x8b\x1b\x04\x74\xeb\xce\x7c\xfa\xda\x20\xcb\x4c\x24\x22\xca\xa8\ \xa8\x91\x2d\xde\x41\xee\xbf\xae\x0e\x9b\x96\x07\xb9\x8f\xcf\x76\ \x49\xda\x47\xca\x65\xdf\xbf\xce\x42\xa9\xbd\x00\xfe\x68\x0c\x56\ \x34\x8e\xa1\x8c\x8e\x97\xc6\x2c\x6c\xd3\x34\x98\x3c\x6c\xef\x41\ \x26\xa3\x20\x93\x4e\x03\x7e\xa7\xfd\xca\x6c\x5d\xb4\x3b\xc0\x73\ \x77\x81\x85\x58\x3c\xf6\xd4\xa2\xec\xb8\x06\x2c\xa0\x58\x98\xb0\ \xe4\xe6\x9f\x70\x02\x70\xa6\x62\xab\x8e\x00\x4c\x27\xf0\xe3\x4e\ \xc1\xe9\x8e\x71\x99\x05\x9d\xbf\x1c\x24\xfd\xfb\x72\x01\xa4\x62\ \x9f\xd8\x3c\x87\x4f\x5c\xf4\x3d\xe3\x1c\x2e\x80\xe5\xe4\x4c\xd0\ \x28\x1a\xa0\xeb\xbe\xd8\xa7\xe1\x9f\x6f\x4d\xe0\xa6\x4d\x8d\x98\ \xce\x1a\xc8\xa8\x3a\x3e\xbd\xb1\x05\x3b\x1a\x93\x78\xba\x2b\x83\ \xd1\x8c\x1d\x40\xbb\x61\x6d\x14\x0d\x35\x32\xf9\xd1\x26\x37\xc6\ \x48\xc0\x87\x5f\xff\x75\x2f\x0e\x4d\x04\x11\x58\x13\xc7\x0b\xbd\ \x29\xf4\x4f\x84\xd0\xd2\x10\x26\xb5\xa0\xc3\x47\xc3\xd6\x8f\x6f\ \x6e\x43\xe4\xf9\x11\x1c\x1c\xd7\x78\x42\x4f\x30\xe0\xc5\x17\xaf\ \xa8\xc5\xd6\xb6\x1a\x64\x34\x7b\x1d\x02\xfb\x81\xf6\xbf\x79\x9a\ \xa4\x43\x82\x4f\xff\x71\x17\x80\xea\x3e\x99\xca\xe5\xeb\xce\x5c\ \x8b\x75\xab\x9a\xf1\x9b\x5b\x89\xa4\x7c\x41\xa8\xaa\x8a\xbb\x9f\ \x1a\xa2\xfa\x49\xd8\xb2\x32\x88\xa4\x6a\x62\x86\xc8\x6b\x73\xdb\ \x12\xfc\xfa\x46\x1d\xbf\x3b\xa6\x60\x32\x27\xf3\xce\xb1\x72\x99\ \x0f\xdb\xae\x8e\xf1\xf5\x08\x06\xd9\x07\x9b\x2a\x3c\xd9\x35\x80\ \xde\x31\x15\xf2\x0a\xd9\x0e\x76\x96\xa9\x21\xcc\xcd\x49\xd0\x1c\ \x12\x90\x24\x3b\x2b\x31\x1f\x3c\x74\xdd\x04\xf7\x77\xaf\xbe\x59\ \x00\x16\x58\xd2\xb8\x7c\x9a\x8d\xde\x5b\x15\xb1\x71\x84\xab\x00\ \x4c\xab\x58\x01\xb0\xe7\xff\xc9\x05\x58\x58\x01\x98\xb3\xa3\xad\ \x65\xef\xa1\x70\xef\xde\x11\x5c\x44\xd2\x7e\x5d\x6b\x82\x7c\x64\ \x9d\x27\xd9\xac\x5a\x1a\xc5\xb7\x97\xd9\x23\x3e\xeb\xf1\x39\x32\ \xac\x2c\xcf\xe1\x97\x50\x13\xf6\xe3\xc9\x3d\x2f\xe3\x67\xbb\xba\ \x20\xb7\x6d\x85\xdf\xa3\xa3\x2f\x69\xe0\x27\x7b\xce\xe0\x37\xb7\ \xb4\x52\xe7\xf7\xf1\x29\xc0\xfa\x58\x04\x0f\x7c\xb9\x15\x13\x29\ \x8d\xe7\xe3\xd7\x86\x64\xfa\xae\x4d\x22\x6c\xba\x2a\x56\x13\x46\ \xc7\xab\x47\xb1\xfd\xd0\x30\x02\x6d\xed\x24\x48\x72\x76\x10\x90\ \xea\xdb\x43\x1d\x54\xf2\xd8\xf7\x6a\x07\x71\x25\x7c\xe9\x8a\x16\ \xbe\x88\xe7\xd0\xdb\x7d\x88\xe5\x86\xf0\xdb\x03\x61\x7c\xb4\xd9\ \x83\x4f\x5e\xda\x84\x24\x91\x17\x9b\xc1\xb8\xe9\xf2\x16\x7c\x76\ \x83\x86\xc9\xb4\xce\xeb\xca\x48\x8b\xd5\x5f\xa1\xfa\xf8\x65\x7a\ \x4c\x76\xf2\xe0\xe3\x2f\x61\x58\x5e\x8a\x28\xdb\x64\xd4\xd0\x17\ \x8f\x2d\x50\xc9\x15\xc5\x0c\x3c\xb3\xc1\x43\xc7\x5d\xb0\x0f\xbf\ \xa9\x32\x05\xa0\xd1\xc8\xa1\xa8\x1a\x2c\x59\xca\xa7\xdd\x5a\x56\ \x65\x6c\x02\xe1\x12\x40\x90\xfc\x71\xb6\xb8\xc6\x4b\x6e\x0e\xfb\ \x1b\xf0\xc9\x0e\x01\x9c\x3b\x08\xe8\xf5\xb0\xcf\xca\xa4\x20\xec\ \xd7\x58\xe7\x61\x9d\xca\x26\x00\xc3\x4e\xfe\xa1\xf7\x7a\x32\x32\ \x6e\xfb\x4b\x2f\xee\xbb\x6e\x0a\xd7\x6e\x68\x21\xb9\xee\xe7\x01\ \xb6\xac\xb3\xca\x90\x47\xab\xc9\xca\xc2\x41\x2f\xb4\x9c\x8a\xdf\ \x3f\xf1\x2c\x7e\xf8\xe4\xdb\xc8\xae\xfc\x28\xf9\xfc\x41\xe2\x1f\ \x0d\x21\xd9\x83\x1d\x3d\xf4\xf7\xf1\x13\xb8\xe7\xf3\x2b\xb0\xb4\ \x91\x9f\x52\x03\x1a\x9c\x11\x8d\xf8\x51\xe3\x6c\x6a\x62\x2f\x34\ \xf2\x71\xa3\x7d\xe1\xe5\xc3\xf8\xce\xef\xf6\x21\xbd\x64\x13\x82\ \xd4\x39\xdd\xce\xc8\x62\x0b\xbb\xbb\x53\xb8\x63\x30\x82\xd5\xcb\ \x62\xa4\x4a\x6c\xc2\xe3\xea\xc3\x2b\xa3\x2e\x12\x44\x4c\x56\xd1\ \x4f\x1f\xbf\xeb\xa9\x41\xfc\x22\x93\xc5\x67\x36\x5d\x40\xef\xf9\ \x90\xd3\xa9\xbe\x74\xad\x86\x98\xcc\xeb\xae\x5b\xac\x83\x10\x69\ \x85\x24\x4c\x91\xab\xf1\xa3\x3f\xec\xc6\xdf\x4e\x51\x5b\xb6\xad\ \x84\xa5\x6b\x58\xac\x3b\x02\xe8\xce\x88\x6f\x38\x6e\x80\x1d\x23\ \xa0\xd7\xf5\x2a\x74\x01\x58\x4a\xab\x92\xcb\x41\xb2\xbc\x8b\x4e\ \xe2\x9f\xd7\xfd\xd1\xaf\xfc\xca\xc9\x11\x9c\x7e\x27\xcb\x3b\x66\ \x90\x3a\xff\x91\x93\x03\x7c\x14\xe0\x9d\x66\x81\x51\x8c\xed\x7b\ \xd1\x3f\xa9\xe0\x99\x43\xbd\x50\x94\x2c\x1f\x05\x83\x64\x21\x13\ \xc9\x0c\xa4\x80\x65\x7f\xcf\x31\x94\x20\x5d\xa8\x47\x8d\xe0\xb6\ \x1d\x43\xf8\xd4\xcb\xfd\xb8\x79\x63\x23\x2e\x5d\x1e\x47\x22\x1e\ \xe1\x6b\x0e\x34\x4d\xc7\x74\x2a\x83\xa3\xdd\x67\xf0\xc8\x73\x6f\ \x61\xdf\x59\x09\x72\xeb\x55\xf0\x47\x6a\x60\x69\xb9\xfc\xff\x64\ \xa4\xf4\x48\x97\x81\x83\x7d\xc7\xf0\x95\x4b\x42\xb8\xa6\xbd\x11\ \xcd\x75\x11\xbe\x03\x31\x1b\x8d\xd9\xb4\xe3\x4c\x3a\x8b\xae\xfe\ \x51\xec\x39\x70\x12\x4f\x1c\x19\xc5\x4c\xd3\x06\x84\xe2\x8d\x74\ \x9d\xd9\xce\xe8\x23\xd3\xee\x4f\x99\xb8\x73\x7b\x0f\xbe\xff\xf1\ \x38\xd5\x25\x86\x48\x38\xc8\xbf\x3f\x3c\x94\xc1\x2b\x47\xbb\xe9\ \xf7\xd6\x48\x79\x18\x18\xd4\x43\xb8\xfd\xc9\x21\xdc\x70\x70\x00\ \x37\x6e\x48\x60\x7d\x4b\x1d\x6a\xa2\x41\x9b\x20\x09\x19\x45\xc5\ \xd8\xe4\x0c\x0f\x56\x6e\xdf\xd7\x85\xc3\xa9\x18\x82\x17\x6e\x74\ \x94\x86\xb6\xb8\x07\x87\x02\xf7\x80\x11\x81\x41\x2a\x89\x29\x2f\ \xab\x84\xd2\xb7\x24\x67\x03\x7e\xf6\xa1\x37\x9e\x7f\xa6\x73\xec\ \x5a\xe6\x63\x56\x26\x48\xc2\x4e\x8f\x03\x53\x43\xb3\xb2\x80\x46\ \xb9\x60\xe3\x72\xea\xbd\x91\x05\x83\x58\x2c\x20\xa4\x51\xe7\xd4\ \x47\xcf\x90\x6e\xcc\xb8\x2b\x45\x20\xc7\xea\xe1\xab\x6b\x86\x35\ \x27\x6b\x92\x8f\x26\x2c\x71\x47\x55\x80\xd4\x04\x96\xfa\xb2\x68\ \x0c\x1a\x90\xad\x1c\x27\x00\x96\xbd\x77\x36\x4d\xed\x1b\x5f\x86\ \x40\xfd\x12\x2e\x37\xad\x85\xa2\xe7\xcc\x5d\xa0\x51\xc8\x9c\x99\ \x46\x8d\x39\x8d\xa5\x81\x1c\xc2\x5e\x93\x4f\x3b\xb2\x0e\x9c\x52\ \x74\xf4\x27\x49\xa5\x85\x1b\xe0\x6b\x68\x86\xec\x0f\xe6\x13\x7b\ \x8a\x2f\xe3\xe1\xb3\x0d\x52\x7a\x1c\x17\x05\x67\x10\x95\x54\xe8\ \x44\xf2\xe3\x33\x54\x0f\xc5\x0b\xdf\x92\x0b\x21\x87\x63\xbc\x1b\ \xb0\x55\x7e\xb9\x2c\xd5\x3b\x3d\x81\x96\x40\x16\x31\x9f\x0e\x3f\ \xec\xfd\x0e\x32\x44\x14\xa3\x33\x06\x26\x72\x21\x20\xb1\x0c\xc1\ \x58\x3d\x9c\x9c\xd9\xca\xb3\x12\x0f\x9b\x8a\x35\xb0\x6f\xdb\xe5\ \x9f\xf8\xf8\xea\xf8\x4b\x55\xa3\x00\xf8\xbe\xf8\x5c\x0e\xa3\x62\ \x11\xa8\x8d\x53\xe7\x4b\xcc\xf1\xf3\x8d\x05\x47\x7f\x77\x74\x60\ \x91\x7a\xef\xb2\x0b\x8b\x17\x38\x38\x99\x80\x0b\xa5\x29\xb3\x13\ \xa5\x58\x34\x1d\x0d\x4d\x18\x25\xa5\x31\xa4\x39\xe9\xc0\x24\xef\ \xa5\x7a\x19\x81\x26\xd9\x9e\x86\x22\x17\xe2\xbd\x9a\x9a\xcd\x1e\ \x7a\x6a\x63\x50\x10\x43\x0f\x91\x47\x5e\x6d\x90\xb6\xf7\xd4\x7a\ \xe1\x4f\xf8\x9c\xe8\xb5\xc9\x73\xfb\xcf\x55\x7f\x3f\xcb\xd6\x8d\ \x35\xa0\x5b\x8b\xdb\xd7\xa0\xe7\xbc\x1e\x7e\xd9\xb9\x0f\x3d\x4f\ \x5e\x81\xa0\x0f\x08\x2d\xc5\xbb\x44\x3e\x67\xb8\x2a\x72\x7c\xe1\ \x00\xa9\x95\x88\x6c\xbb\x18\xce\x7a\x82\x4a\x85\x65\x47\x7f\xab\ \x73\x35\xa0\x3b\x7f\x5c\xd1\x78\x3f\xc6\x6b\xbe\x8f\x20\x97\xc9\ \xfb\x1a\x3f\x6b\x8e\x1c\xea\x3c\x71\x30\x9f\xf9\x7c\x8d\xcb\x9d\ \x66\xf5\xf1\xac\x16\x6f\xd1\x1b\x7c\x31\xcf\x7f\x61\xa4\x45\xd7\ \x70\xea\x71\x2e\x07\x8f\x53\x14\x4f\xba\x2f\xfc\x9f\x8c\x68\x54\ \x54\x05\x0c\xa3\xfa\x32\x01\x51\x05\x0a\x40\x40\xe0\xfc\xc8\xdb\ \xa8\xce\x54\x60\x9b\x00\xc4\xb1\x97\x02\x82\x00\xaa\x6e\x53\x50\ \xcb\x12\x04\x20\x20\x50\xbd\x0a\x20\xbf\xce\x5d\xf8\x00\x02\x55\ \x0e\xab\x0a\x13\x81\x20\x14\x80\x80\xc0\xac\x02\xa8\x36\x17\xc0\ \xde\x62\x45\x9a\xdd\xa3\xa9\xe8\x3d\xe2\x87\x9c\xbe\xf0\x09\x9a\ \x02\x02\x8b\x72\x94\x07\x4b\xa7\xcc\x9f\xb7\x50\x7c\xc4\x93\x54\ \x7d\x04\x60\x0d\xbc\x61\xe0\xc4\x5b\xb0\x42\x81\xf9\x6f\xe6\x72\ \xb8\xf7\xae\x5b\xb0\xa5\xbd\x15\xd9\x9c\x26\x8c\x47\x60\xd1\x23\ \x14\x08\xe0\xbb\xf7\xfe\x1c\x9d\x27\xfa\x80\xfa\x66\xc0\x1f\x46\ \x7e\x1b\xd2\xac\x0a\x2b\x7b\x19\x3d\x68\xac\x22\x05\x90\x99\x50\ \x90\x1c\x04\xf4\xe0\x02\xef\xa9\xd8\xdc\x1c\xc0\xa7\xdb\x1b\x90\ \x56\x54\x61\x3d\x02\x8b\x1e\x91\x48\x08\x75\x2a\xd9\xfb\x70\xb7\ \xbd\x3b\x69\xa8\x76\x76\xe4\xcf\xb0\xcd\x11\x4b\x37\xd2\x95\x86\ \x00\x24\x6f\x07\x24\x79\x2d\x95\x55\xf3\xde\xf3\x1a\xfc\x50\x4a\ \x76\x1a\x0d\x2b\x02\x02\x8b\x1e\x32\xf5\x71\x96\xa0\x25\xfb\x59\ \xb6\x96\x7d\x92\x92\x4d\x00\x49\x7a\x7c\x90\x9e\x0c\x57\x17\x01\ \x00\x7b\x1d\xcd\xf3\x35\x2a\x4d\xf3\x5c\x84\xc2\xcd\x25\x05\x04\ \x16\x7b\x08\x60\xe1\x3d\xc1\x58\xca\xe7\x61\x2a\x8f\x52\x19\xa9\ \x2a\x02\xc8\xaa\xb9\x4e\x92\x3e\x7f\x42\xd0\xcf\x0e\xa1\xbb\x81\ \x5e\x5a\x4b\x25\x2c\x4c\x45\xa0\x0a\xc0\xa2\xdb\x6c\xc4\xdf\x4f\ \xe5\x31\x28\xb9\x0e\xc3\x34\x67\x4a\x55\x99\x92\x84\x20\x1f\xbe\ \xe7\x4e\xe5\x0f\x0f\x7d\xff\x78\xc0\xeb\xfd\x2d\x34\xfd\x61\x7a\ \xe9\x10\x66\xf7\x4e\x10\x10\xa8\x64\x39\x30\x0a\xcb\x7c\x8a\x1e\ \x3d\x00\x35\xf7\xf7\x07\x7f\xfa\xcd\xd1\xcb\xda\x57\x95\x4c\xea\ \x96\x44\x01\x6c\x5c\xd3\xca\xcb\x5b\xbd\x67\x46\x7e\xff\xd8\x9e\ \x9d\x53\x6a\xae\x86\x94\xc0\x05\xf4\x16\x8b\x09\x88\xe4\x00\x81\ \x0a\x04\x5f\x97\x69\xc0\xd4\x8e\xc1\x34\x1e\x83\xd7\x7f\x90\xed\ \x9c\x7a\xd5\xa6\x76\x7e\x94\x7a\x55\x29\x00\x17\xf7\xdf\xfd\x75\ \x5c\xb6\xb9\x7d\x9c\x64\xd0\xd3\xf4\xf4\x49\x2a\xdd\xc2\x50\x04\ \x2a\x73\xe4\x37\x75\xe8\xb9\x6e\xe4\x32\x7b\x31\xd6\x73\x1c\xe9\ \x31\x93\x05\x04\xb3\x4a\x69\x85\xaf\x5c\xea\x76\xb1\xf7\x44\x43\ \x0f\x95\xed\x60\x51\x51\xe0\x26\x2a\x9b\x60\xaf\x70\x15\x10\xa8\ \x8c\xd1\xdf\xd0\x46\x90\x9d\x7a\x1d\x93\xea\xeb\x50\x92\x19\x44\ \x1a\xec\x65\xd0\x25\x86\x5c\x26\x2d\xc4\x68\xf0\x38\x95\x33\x44\ \x95\x67\x98\x38\xa0\x92\x10\x86\x23\x50\x31\xea\x3f\x97\xee\x83\ \x3e\xdd\x89\x54\x72\x92\x2f\x82\x29\x71\x06\x60\x59\xb8\x00\x73\ \xc0\xa6\x45\x46\xa9\xec\xa1\x06\x1a\x11\x91\x00\x81\xca\x52\x00\ \x6c\x9f\x37\x28\x4e\x1a\x70\xd9\x58\xb7\x54\x5e\xed\xc4\xb6\x49\ \x55\x86\xa9\x4c\x89\x58\xa0\x40\xe5\xc9\x80\xf2\x33\x6a\xb9\xbc\ \xda\x88\xda\x47\xcd\x58\x50\xd3\x6c\xb3\x68\x91\x08\x24\x50\x11\ \x28\x67\x3b\x2e\x39\x01\xb0\x53\x64\x90\x51\xec\x27\x2c\x4d\x32\ \x93\x86\xc7\xd4\x2c\x78\x84\x02\x10\xa8\x60\x30\xbb\xd7\x14\xe7\ \x6c\xc0\x2a\x26\x80\xab\x36\xac\x41\x88\x11\x64\xd0\x4f\x0a\xc0\ \x8b\xf1\x6e\x99\x9f\x1b\x28\x20\x50\xc9\xd8\x48\x76\x1f\x4f\xb4\ \x20\x11\xab\xa9\x6e\x02\x78\x70\xdb\x6d\x45\xcf\x9f\x7f\x6e\x2f\ \xfa\xfa\x07\x84\x85\x08\x54\x34\x1e\xfe\xc1\x1d\xb8\xf2\xaa\xab\ \x4b\x5e\x0f\xa9\xdc\x1a\x46\x21\x69\x24\xc4\xbf\x40\xa5\x83\xbb\ \xbe\x65\x00\x49\xfc\x14\x02\x02\xd5\x0b\x41\x00\x02\x02\x82\x00\ \x04\x04\x04\x04\x01\x08\x08\x08\x08\x02\x10\x10\x10\x10\x04\x20\ \x20\x20\x50\xe1\x90\xcb\xb4\x5e\x92\xd8\x13\x50\xa0\x52\x50\xce\ \x76\x5c\x96\x0a\x40\xd3\xb4\x7e\x55\x55\xd3\xc2\x74\x04\x16\x33\ \xd8\xf9\x37\x64\xcb\x66\x7f\x7f\xbf\xaa\x28\x8a\x9b\xde\x6a\x09\ \x02\x78\xaf\x0a\x49\x12\x26\x26\x26\x76\x8f\x8e\x8e\xbe\xe9\x36\ \xa2\x80\xc0\x62\x84\xd7\xeb\xc5\xcc\xcc\x8c\xbe\x6b\xd7\xae\x77\ \x87\x86\x86\xd8\x66\x37\x6c\xff\x7f\xa3\x9c\x48\x40\x2a\xc7\x46\ \x7b\xed\xb5\xd7\x3a\x0e\x1f\x3e\xfc\xcc\xd4\xd4\xd4\x18\x23\x00\ \x49\x12\xa1\x0a\x81\xc5\x35\xf2\x33\x3b\x26\x15\x6b\x1e\x39\x72\ \x64\x72\xe7\xce\x9d\xfd\x34\xa0\xb1\xad\xbf\xa7\xc1\xf6\x04\x28\ \x23\x02\x28\xbb\x18\x80\x2c\xcb\xd8\xbd\x7b\x37\x6b\xac\xe7\xa8\ \xe3\xb7\xad\x5f\xbf\xfe\x73\xf1\x78\xbc\xce\xe7\xf3\x49\xac\x51\ \x45\x5c\x40\xa0\x9c\x3b\xbe\xe3\xc2\x5a\x4c\xf2\x1f\x3d\x7a\x74\ \x6a\xc7\x8e\x1d\x03\x27\x4e\x9c\x38\xab\xeb\x7a\x3f\xbd\x35\x48\ \x85\x6d\x01\x6e\x0a\x02\x78\x6f\xbf\x49\xdb\xbf\x7f\x7f\x57\x2a\ \x95\xda\xbe\x65\xcb\x96\x99\xcd\x9b\x37\x6f\x6d\x6f\x6f\x6f\x6d\ \x6c\x6c\x0c\x12\x11\x08\x45\x20\x50\x76\x60\x03\x93\x61\x18\xc8\ \x64\x32\xd6\xa9\x53\xa7\x52\x1d\x1d\x1d\xa3\x7b\xf7\xee\x1d\xee\ \xec\xec\x3c\x93\xcd\x66\x4f\xc1\xde\xf7\xf2\xac\x20\x80\xf3\x83\ \x39\x3e\x3e\x3e\xfd\xea\xab\xaf\x1e\xa5\xc6\xf3\x27\x93\x49\xab\ \xaf\xaf\x6f\x73\x5d\x5d\x5d\x63\x38\x1c\x8e\x10\x09\xb0\x7a\xbb\ \xc1\x01\x11\x24\x10\x28\x0b\x02\xa0\x51\x5f\x27\x5b\xd5\x7a\x7b\ \x7b\x93\x07\x0e\x1c\x18\x24\x05\xd0\x4f\xf6\xdb\x4b\x6f\x9f\x74\ \x08\x80\x29\x5b\x55\xb8\x00\xe7\xd1\x9e\x4c\x49\x51\xe3\x4d\x10\ \x09\x1c\xa4\x32\x44\xcf\x5f\xa6\xd2\x4a\x65\x09\x15\xb6\x88\xda\ \x07\x91\xc7\x20\x50\x7e\x76\x6b\x3a\x9d\x7c\x8a\xca\xbb\x54\xd8\ \xe8\xdf\xeb\x3c\x4e\x97\xd3\xe8\x5f\xce\x04\x80\x82\x86\x1c\x87\ \xbd\x61\x68\xd6\x79\xcc\xce\x14\x8c\x50\xf1\x0b\x02\x10\x28\x43\ \x02\x60\x51\x7e\xc5\x21\x80\x61\xa7\xe3\x8f\x39\x9d\x5f\x47\x99\ \x4d\x03\xca\x65\xde\xa0\x2e\x09\x4c\x50\xc9\x38\x0d\x1a\x72\x46\ \x7f\xaf\x90\xff\x02\x65\x6a\xb3\x2e\x09\x64\x9c\xa2\x3a\xaf\x97\ \x5d\x04\xfb\xdf\x02\x0c\x00\x0b\x53\x81\x73\x51\x45\x40\xdb\x00\ \x00\x00\x00\x49\x45\x4e\x44\xae\x42\x60\x82\ " qt_resource_name = "\ \x00\x04\ \x00\x06\xfa\x5e\ \x00\x69\ \x00\x63\x00\x6f\x00\x6e\ \x00\x07\ \x09\xcb\xb6\x93\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x73\ \x00\x03\ \x00\x00\x78\xc3\ \x00\x72\ \x00\x65\x00\x73\ \x00\x03\ \x00\x00\x70\x37\ \x00\x69\ \x00\x6d\x00\x67\ \x00\x1a\ \x0d\x95\x42\xe7\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x62\x00\x61\x00\x63\x00\x6b\x00\x75\x00\x70\x00\x5f\x00\x64\x00\x69\x00\x73\ \x00\x61\x00\x62\x00\x6c\x00\x65\x00\x64\x00\x2e\x00\x70\x00\x6e\x00\x67\ \x00\x13\ \x09\x34\xc1\x67\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x64\x00\x6f\x00\x77\x00\x6e\x00\x6c\x00\x6f\x00\x61\x00\x64\x00\x2e\x00\x70\ \x00\x6e\x00\x67\ \x00\x0f\ \x0d\xf5\x7d\xe7\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x75\x00\x74\x00\x66\x00\x38\x00\x2e\x00\x70\x00\x6e\x00\x67\ \x00\x19\ \x01\x96\x0f\x07\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x61\x00\x70\x00\x70\x00\x6c\x00\x79\x00\x5f\x00\x64\x00\x69\x00\x73\x00\x61\ \x00\x62\x00\x6c\x00\x65\x00\x64\x00\x2e\x00\x70\x00\x6e\x00\x67\ \x00\x1c\ \x0b\x10\x37\x07\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x64\x00\x6f\x00\x77\x00\x6e\x00\x6c\x00\x6f\x00\x61\x00\x64\x00\x5f\x00\x64\ \x00\x69\x00\x73\x00\x61\x00\x62\x00\x6c\x00\x65\x00\x64\x00\x2e\x00\x70\x00\x6e\x00\x67\ \x00\x18\ \x0c\x40\x62\x67\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x65\x00\x78\x00\x69\x00\x74\x00\x5f\x00\x64\x00\x69\x00\x73\x00\x61\x00\x62\ \x00\x6c\x00\x65\x00\x64\x00\x2e\x00\x70\x00\x6e\x00\x67\ \x00\x0f\ \x08\x69\x7b\xe7\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x65\x00\x78\x00\x69\x00\x74\x00\x2e\x00\x70\x00\x6e\x00\x67\ \x00\x18\ \x0c\x12\xc4\x27\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x61\x00\x6e\x00\x73\x00\x69\x00\x5f\x00\x64\x00\x69\x00\x73\x00\x61\x00\x62\ \x00\x6c\x00\x65\x00\x64\x00\x2e\x00\x70\x00\x6e\x00\x67\ \x00\x1b\ \x06\xc3\x72\x67\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x72\x00\x65\x00\x73\x00\x74\x00\x6f\x00\x72\x00\x65\x00\x5f\x00\x64\x00\x69\ \x00\x73\x00\x61\x00\x62\x00\x6c\x00\x65\x00\x64\x00\x2e\x00\x70\x00\x6e\x00\x67\ \x00\x18\ \x0c\x81\x05\x67\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x75\x00\x74\x00\x66\x00\x38\x00\x5f\x00\x64\x00\x69\x00\x73\x00\x61\x00\x62\ \x00\x6c\x00\x65\x00\x64\x00\x2e\x00\x70\x00\x6e\x00\x67\ \x00\x1a\ \x0d\xa7\xd8\x07\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x75\x00\x70\x00\x64\x00\x61\x00\x74\x00\x65\x00\x5f\x00\x64\x00\x69\x00\x73\ \x00\x61\x00\x62\x00\x6c\x00\x65\x00\x64\x00\x2e\x00\x70\x00\x6e\x00\x67\ \x00\x0f\ \x02\xf6\x79\x67\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x61\x00\x6e\x00\x73\x00\x69\x00\x2e\x00\x70\x00\x6e\x00\x67\ \x00\x11\ \x06\x8e\xf4\xc7\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x75\x00\x70\x00\x64\x00\x61\x00\x74\x00\x65\x00\x2e\x00\x70\x00\x6e\x00\x67\ \ \x00\x10\ \x01\xda\x95\x47\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x61\x00\x70\x00\x70\x00\x6c\x00\x79\x00\x2e\x00\x70\x00\x6e\x00\x67\ \x00\x11\ \x0c\xef\x75\x47\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x62\x00\x61\x00\x63\x00\x6b\x00\x75\x00\x70\x00\x2e\x00\x70\x00\x6e\x00\x67\ \ \x00\x12\ \x04\x27\x2f\xe7\ \x00\x62\ \x00\x75\x00\x74\x00\x74\x00\x6f\x00\x6e\x00\x5f\x00\x72\x00\x65\x00\x73\x00\x74\x00\x6f\x00\x72\x00\x65\x00\x2e\x00\x70\x00\x6e\ \x00\x67\ \x00\x05\ \x00\x6f\xa6\x53\ \x00\x69\ \x00\x63\x00\x6f\x00\x6e\x00\x73\ \x00\x14\ \x0d\x75\xab\xe7\ \x00\x75\ \x00\x74\x00\x6c\x00\x5f\x00\x69\x00\x63\x00\x6f\x00\x6e\x00\x40\x00\x32\x00\x35\x00\x36\x00\x78\x00\x32\x00\x35\x00\x36\x00\x2e\ \x00\x70\x00\x6e\x00\x67\ " qt_resource_struct = "\ \x00\x00\x00\x00\x00\x02\x00\x00\x00\x02\x00\x00\x00\x01\ \x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x16\ \x00\x00\x00\x0e\x00\x02\x00\x00\x00\x01\x00\x00\x00\x03\ \x00\x00\x00\x22\x00\x02\x00\x00\x00\x01\x00\x00\x00\x04\ \x00\x00\x00\x2e\x00\x02\x00\x00\x00\x01\x00\x00\x00\x05\ \x00\x00\x00\x0e\x00\x02\x00\x00\x00\x10\x00\x00\x00\x06\ \x00\x00\x00\xc4\x00\x00\x00\x00\x00\x01\x00\x00\x12\x2c\ \x00\x00\x02\xc2\x00\x00\x00\x00\x00\x01\x00\x00\x57\x58\ \x00\x00\x02\x76\x00\x00\x00\x00\x00\x01\x00\x00\x48\xda\ \x00\x00\x03\x10\x00\x00\x00\x00\x00\x01\x00\x00\x62\xfc\ \x00\x00\x02\x9a\x00\x00\x00\x00\x00\x01\x00\x00\x50\x67\ \x00\x00\x01\xca\x00\x00\x00\x00\x00\x01\x00\x00\x33\x9e\ \x00\x00\x01\x70\x00\x00\x00\x00\x00\x01\x00\x00\x25\x54\ \x00\x00\x00\x74\x00\x00\x00\x00\x00\x01\x00\x00\x04\xfc\ \x00\x00\x00\xfc\x00\x00\x00\x00\x00\x01\x00\x00\x18\xef\ \x00\x00\x01\x94\x00\x00\x00\x00\x00\x01\x00\x00\x2c\x15\ \x00\x00\x01\x3a\x00\x00\x00\x00\x00\x01\x00\x00\x1e\x93\ \x00\x00\x02\x06\x00\x00\x00\x00\x00\x01\x00\x00\x3a\x5d\ \x00\x00\x02\xe8\x00\x00\x00\x00\x00\x01\x00\x00\x5e\x00\ \x00\x00\x00\x3a\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\ \x00\x00\x02\x3c\x00\x00\x00\x00\x00\x01\x00\x00\x41\xe9\ \x00\x00\x00\xa0\x00\x00\x00\x00\x00\x01\x00\x00\x0a\xa0\ \x00\x00\x00\x22\x00\x02\x00\x00\x00\x01\x00\x00\x00\x17\ \x00\x00\x00\x2e\x00\x02\x00\x00\x00\x01\x00\x00\x00\x18\ \x00\x00\x03\x3a\x00\x02\x00\x00\x00\x01\x00\x00\x00\x19\ \x00\x00\x03\x4a\x00\x00\x00\x00\x00\x01\x00\x00\x69\xb1\ " def qInitResources(): QtCore.qRegisterResourceData(0x01, qt_resource_struct, qt_resource_name, qt_resource_data) def qCleanupResources(): QtCore.qUnregisterResourceData(0x01, qt_resource_struct, qt_resource_name, qt_resource_data) qInitResources()
229,377
Python
.py
3,568
63.28111
129
0.738196
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,269
language.py
huhamhire_huhamhire-hosts/gui/language.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # language.py : Language utilities used in GUI module. # # Copyleft (C) 2013 - huhamhire hosts team <hosts@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # # This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import locale class LangUtil(object): """ LangUtil contains a set of language tools for Hosts Setup Utility to use. .. note:: All methods from this class are declared as `classmethod`. :ivar dict language: Supported localized language name for a specified locale tag. The default declaration of :attr:`language` is:: language = {"de_DE": u"Deutsch", "en_US": u"English", "ja_JP": u"日本語", "ko_KR": u"한글", "ru_RU": u"Русский", "zh_CN": u"简体中文", "zh_TW": u"正體中文", } .. note:: The keys of :attr:`language` are typically in the format of \ IETF language tag. For example: en_US, en_GB, etc. .. note:: The Hosts Setup Utility would check whether the language files exist in `gui/lang/` folder automatically while loading GUI. If not, the language related wouldn't be available in language selection combobox. """ language = {"de_DE": u"Deutsch", "en_US": u"English", "ja_JP": u"日本語", "ko_KR": u"한글", "ru_RU": u"Русский", "zh_CN": u"简体中文", "zh_TW": u"正體中文", } @classmethod def get_locale(cls): """ Retrieve the default locale tag of current operating system. .. note:: This is a `classmethod`. :return: Default locale tag of current operating system. If the locale is not found in cls.dictionary dictionary, the return value "en_US" as default. :rtype: str """ lc = locale.getdefaultlocale()[0] if lc is None: lc = "en_US" return lc @classmethod def get_language_by_locale(cls, l_locale): """ Return the name of a specified language by :attr:`l_locale`. .. note:: This is a `classmethod`. :param l_locale: Locale tag of a specified language. :type l_locale: str :return: Localized name of a specified language. :type: str """ try: return cls.language[l_locale] except KeyError: return cls.language["en_US"] @classmethod def get_locale_by_language(cls, l_lang): """ Get the locale string connecting with a language specified by :attr:`l_lang`. .. note:: This is a `classmethod`. :param l_lang: Localized name of a specified language. :type l_lang: unicode :return: Locale tag of a specified language. :rtype: str """ for locl, lang in cls.language.items(): if l_lang == lang: return locl return "en_US"
3,604
Python
.py
89
30.539326
79
0.556268
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,270
qdialog_d.py
huhamhire_huhamhire-hosts/gui/qdialog_d.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # qdialog_d.py : Operations on the main dialog. # # Copyleft (C) 2014 - huhamhire hosts team <hosts@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # # This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import os import shutil from zipfile import BadZipfile from PyQt4 import QtCore, QtGui from _checkconn import QSubChkConnection from _checkupdate import QSubChkUpdate from _make import QSubMakeHosts from _update import QSubFetchUpdate from qdialog_ui import QDialogUI from util_ui import _translate import sys sys.path.append("..") from util import RetrieveData, CommonUtil class QDialogDaemon(QDialogUI): """ QDialogDaemon class contains methods used to manage the operations while modifying the hosts file of current operating system. Including methods to manage operations to update data file, download data file, configure hosts, make hosts file, backup hosts file, and restore backup. .. note:: This class is subclass of :class:`~gui.qdialog_ui.QDialogUI` class and parent class of :class:`~gui.qdialog_slots.QDialogSlots`. :ivar int_down_flag: An flag indicating the downloading status of current session. 1 represents data file is being downloaded. :ivar dict _update: Update information of the current data file on server. :ivar int _writable: Indicating whether the program is run with admin/root privileges. The value could be `1` or `0`. .. seealso:: `_update` and `_writable` in :class:`~tui.curses_d.CursesDaemon` class. :ivar list _funcs: Two lists with the information of function list both for IPv4 and IPv6 environment. :ivar list choice: Two lists with the selection of functions both for IPv4 and IPv6 environment. :ivar list slices: Two lists with integers indicating the number of function items from different parts listed in the function list. .. seealso:: `_funcs`, `choice`, and `slices` in :class:`~tui.curses_ui.CursesUI` class. :ivar dict make_cfg: A set of module selection control bytes used to control whether a specified method is used or not while generate a hosts file. .. seealso:: :attr:`make_cfg` in :class:`~tui.curses_d.CursesDaemon` class. :ivar str platform: Platform of current operating system. The value could be `Windows`, `Linux`, `Unix`, `OS X`, and of course `Unknown`. :ivar str hostname: The hostname of current operating system. .. note:: This attribute would only be used on linux. :ivar str hosts_path: The absolute path to the hosts file on current operating system. :ivar str make_mode: Operation mode for making hosts file. The valid value could be one of `system`, `ansi`, and `utf-8`. .. seealso:: :attr:`make_mode` in :class:`~util.makehosts.MakeHosts` class. :ivar str sys_eol: The End-Of-Line marker. This maker could typically be one of `CR`, `LF`, or `CRLF`. .. seealso:: :attr:`sys_eol` in :class:`~tui.curses_ui.CursesUI` class. """ _down_flag = 0 _update = {} _writable = 0 _funcs = [[], []] choice = [[], []] slices = [[], []] make_cfg = {} platform = '' hostname = '' hosts_path = '' sys_eol = '' make_mode = '' def __init__(self): super(QDialogDaemon, self).__init__() self.set_platform() self.set_platform_label() def check_writable(self): """ Check if current session is ran with root privileges. .. note:: IF current session does not has the write privileges to the hosts file of current system, a warning message box would popup. .. note:: ALL operation would change the `hosts` file on current system could only be done while current session has write privileges to the file. """ writable = CommonUtil.check_privileges()[1] self._writable = writable if not writable: self.warning_permission() def check_connection(self): """ Operations to check the connection to current server. """ thread = QSubChkConnection(self) thread.trigger.connect(self.set_conn_status) thread.start() def check_update(self): """ Retrieve the metadata of the latest data file from a server. """ self.set_update_start_btns() self.set_label_text(self.ui.labelLatestData, unicode( _translate("Util", "Checking...", None))) thread = QSubChkUpdate(self) thread.trigger.connect(self.finish_update) thread.start() def fetch_update(self): """ Retrieve a new hosts data file from a server. """ self.set_fetch_start_btns() thread = QSubFetchUpdate(self) thread.prog_trigger.connect(self.set_down_progress) thread.finish_trigger.connect(self.finish_fetch) thread.start() def fetch_update_after_check(self): """ Decide whether to retrieve a new data file from server or not after checking update information from a mirror. """ if self._update["version"] == \ unicode(_translate("Util", "[Error]", None)): self.finish_fetch(error=1) elif self.new_version(): self.fetch_update() else: self.info_uptodate() self.finish_fetch() def export_hosts(self): """ Display the export dialog and get the path to save the exported hosts file. :return: Path to export a hosts file. :rtype: str """ filename = "hosts" if self.platform == "OS X": filename = "/Users/" + filename filepath = QtGui.QFileDialog.getSaveFileName( self, _translate("Util", "Export hosts", None), QtCore.QString(filename), _translate("Util", "hosts File", None)) return filepath def make_hosts(self, mode="system"): """ Make a new hosts file for current system. :param mode: Operation mode for making hosts file. The valid value could be one of `system`, `ansi`, and `utf-8`. Default by `system`. :type mode: str """ self.set_make_start_btns() self.set_make_message(unicode(_translate( "Util", "Building hosts file...", None)), 1) # Avoid conflict while making hosts file RetrieveData.disconnect_db() self.make_mode = mode self.set_config_bytes(mode) thread = QSubMakeHosts(self) thread.info_trigger.connect(self.set_make_progress) thread.fina_trigger.connect(self.finish_make) thread.move_trigger.connect(self.move_hosts) thread.start() def move_hosts(self): """ Move hosts file to the system path after making. .. note:: This method is the slot responses to the move_trigger signal from an instance of :class:`~gui._make.QSubMakeHosts` class while making operations are finished. .. seealso:: :attr:`move_trigger` in :class:`~gui._make.QSubMakeHosts`. """ filepath = "hosts" msg = unicode( _translate("Util", "Copying new hosts file to\n" "%s", None)) % self.hosts_path self.set_make_message(msg) try: shutil.copy2(filepath, self.hosts_path) except IOError: self.warning_permission() os.remove(filepath) return except OSError: pass msg = unicode( _translate("Util", "Remove temporary file", None)) self.set_make_message(msg) os.remove(filepath) msg = unicode( _translate("Util", "Operation completed", None)) self.set_make_message(msg) self.info_complete() def set_platform(self): """ Set the information of current operating system platform. """ system, hostname, path, encode, flag = CommonUtil.check_platform() self.platform = system self.hostname = hostname self.hosts_path = path self.plat_flag = flag if encode == "win_ansi": self.sys_eol = "\r\n" else: self.sys_eol = "\n" def set_config_bytes(self, mode): """ Generate the module configuration byte words by the selection from function list on the main dialog. :param mode: Operation mode for making hosts file. The valid value could be one of `system`, `ansi`, and `utf-8`. .. seealso:: Method :meth:`~gui.qdialog_d.QDialogDaemon.make_hosts`. """ ip_flag = self._ipv_id selection = {} if mode == "system": localhost_word = { "Windows": 0x0001, "Linux": 0x0002, "Unix": 0x0002, "OS X": 0x0004}[self.platform] else: localhost_word = 0x0008 selection[0x02] = localhost_word ch_parts = [0x08, 0x20 if ip_flag else 0x10, 0x40] # Set customized module if exists if (self.custom != None and os.path.isfile(self.custom)): ch_parts.insert(0, 0x04) slices = self.slices[ip_flag] for i, part in enumerate(ch_parts): part_cfg = self._funcs[ip_flag][slices[i]:slices[i + 1]] part_word = 0 for i, cfg in enumerate(part_cfg): part_word += cfg << i selection[part] = part_word self.make_cfg = selection def refresh_info(self, refresh=0): """ Reload the data file information and show them on the main dialog. The information here includes both metadata and hosts module info from the data file. :param refresh: A flag indicating whether the information on main dialog needs to be reloaded or not. The value could be `0` or `1`. ======= ============= refresh operation ======= ============= 0 Do NOT reload 1 Reload ======= ============= :type refresh: int """ if refresh and RetrieveData.conn is not None: RetrieveData.clear() try: RetrieveData.unpack() RetrieveData.connect_db() self.set_func_list(refresh) self.refresh_func_list() self.set_info() except (BadZipfile, IOError, OSError): self.warning_incorrect_datafile() def finish_make(self, time, count): """ Start operations after making new hosts file. .. note:: This method is the slot responses to the fina_trigger signal values :attr:`time`, :attr:`count` from an instance of :class:`~gui._make.QSubMakeHosts` class while making operations are finished. :param time: Total time uesd while generating the new hosts file. :type time: str :param count: Total number of hosts entries inserted into the new hosts file. :type count: int .. seealso:: :attr:`fina_trigger` in :class:`~gui._make.QSubMakeHosts` class. """ self.set_make_finish_btns() RetrieveData.connect_db() msg = unicode( _translate("Util", "Notice: %i hosts entries has " "\n been applied in %ssecs.", None))\ % (count, time) self.set_make_message(msg) self.set_down_progress(100, unicode( _translate("Util", "Operation Completed Successfully!", None))) def finish_update(self, update): """ Start operations after checking update. .. note:: This method is the slot responses to the trigger signal value :attr:`update` from an instance of :class:`~gui._checkupdate.QSubChkUpdate` class while checking operations are finished. :param update: Metadata of the latest hosts data file on the server. :type update: dict .. seealso:: :attr:`trigger` in :class:`~gui._checkupdate.QSubChkUpdate` class. """ self._update = update self.set_label_text(self.ui.labelLatestData, update["version"]) if self._update["version"] == \ unicode(_translate("Util", "[Error]", None)): self.set_conn_status(0) else: self.set_conn_status(1) if self._down_flag: self.fetch_update_after_check() else: self.set_update_finish_btns() def finish_fetch(self, refresh=1, error=0): """ Start operations after downloading data file. .. note:: This method is the slot responses to the finish_trigger signal :attr:`refresh`, :attr:`error` from an instance of :class:`~gui._update.QSubFetchUpdate` class while downloading is finished. :param refresh: An flag indicating whether the downloading progress is successfully finished or not. Default by 1. :type refresh: int. :param error: An flag indicating whether the downloading progress is successfully finished or not. Default by 0. :type error: int .. seealso:: :attr:`finish_trigger` in :class:`~gui._update.QSubFetchUpdate` class. """ self._down_flag = 0 if error: # Error occurred while downloading self.set_down_progress(0, unicode( _translate("Util", "Error", None))) try: os.remove(self.filename) except: pass self.warning_download() msg_title = "Warning" msg = unicode( _translate("Util", "Incorrect Data file!\n" "Please use the \"Download\" key to \n" "fetch a new data file.", None)) self.set_message(msg_title, msg) self.set_conn_status(0) else: # Data file retrieved successfully self.set_down_progress(100, unicode( _translate("Util", "Download Complete", None))) self.refresh_info(refresh) self.set_fetch_finish_btns(error) def new_version(self): """ Compare version of local data file to the version from the server. :return: A flag indicating whether the local data file is up-to-date or not. :rtype: int ====== ============================================ Return File status ====== ============================================ 1 The version of data file on server is newer. 0 The local data file is up-to-date. ====== ============================================ """ local_ver = self._cur_ver server_ver = self._update["version"] local_ver = local_ver.split('.') server_ver = server_ver.split('.') for i, ver_num in enumerate(local_ver): if server_ver[i] > ver_num: return 1 return 0
15,925
Python
.py
380
32.186842
78
0.585211
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,271
__list_trans.py
huhamhire_huhamhire-hosts/gui/__list_trans.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # __list_trans.py : Name of items from the function list to be localized # # Copyleft (C) 2014 - huhamhire hosts team <hosts@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # # This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" from util_ui import _translate # Name of items from the function list to be localized # __list_trans (list): A list containing names of function list items # for translator to translate. __list_trans = [ _translate("Util", "customize", None), _translate("Util", "google", None), _translate("Util", "google-apis", None), _translate("Util", "google(cn)", None), _translate("Util", "google(hk)", None), _translate("Util", "google(us)", None), _translate("Util", "google-apis(cn)", None), _translate("Util", "google-apis(us)", None), _translate("Util", "activation-helper", None), _translate("Util", "facebook", None), _translate("Util", "twitter", None), _translate("Util", "youtube", None), _translate("Util", "wikipedia", None), _translate("Util", "institutions", None), _translate("Util", "steam", None), _translate("Util", "github", None), _translate("Util", "dropbox", None), _translate("Util", "wordpress", None), _translate("Util", "others", None), _translate("Util", "adblock-hostsx", None), _translate("Util", "adblock-mvps", None), _translate("Util", "adblock-mwsl", None), _translate("Util", "adblock-yoyo", None), ]
1,956
Python
.py
44
41.295455
73
0.618125
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,272
_checkconn.py
huhamhire_huhamhire-hosts/gui/_checkconn.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # _checkconn.py: Check connect to a specified server. # # Copyleft (C) 2014 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" from PyQt4 import QtCore import sys sys.path.append("..") from util import CommonUtil class QSubChkConnection(QtCore.QThread): """ QSubChkConnection is a subclass of :class:`PyQt4.QtCore.QThread`. This class contains methods to check the network connection with a specified server. .. inheritance-diagram:: gui._checkconn.QSubChkConnection :parts: 1 .. note:: The instance of this class should be created in an individual thread. And an instance of class should be set as :attr:`parent` here. :ivar PyQt4.QtCore.pyqtSignal trigger: An instance of :class:`PyQt4.QtCore.pyqtSignal` to emit signal to the main dialog which indicates current status. .. note:: The signal :attr:`trigger` should be a integer flag: ====== ======== signal Status ====== ======== -1 Checking 0 Failed 1 OK ====== ======== """ trigger = QtCore.pyqtSignal(int) def __init__(self, parent): """ Initialize a new instance of this class. Retrieve mirror settings from the main dialog to check the connection. :param parent: An instance of :class:`~gui.qdialog_d.QDialogDaemon` class to fetch settings from. :type parent: :class:`~gui.qdialog_d.QDialogDaemon` .. warning:: :attr:`parent` MUST NOT be set as `None`. """ super(QSubChkConnection, self).__init__(parent) self.link = parent.mirrors[parent.mirror_id]["test_url"] def run(self): """ Start operations to check the network connection with a specified server. """ self.trigger.emit(-1) status = CommonUtil.check_connection(self.link) self.trigger.emit(status)
2,379
Python
.py
58
34.344828
78
0.597054
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,273
__init__.py
huhamhire_huhamhire-hosts/gui/__init__.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # __init__.py : Declare modules to be called in gui module. # # Copyleft (C) 2014 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== from hostsutil import HostsUtil __all__ = ["HostsUtil"]
563
Python
.py
13
42.153846
71
0.532847
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,274
_make.py
huhamhire_huhamhire-hosts/gui/_make.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # _make.py: Make a new hosts file. # # Copyleft (C) 2014 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import time from PyQt4 import QtCore import sys sys.path.append("..") from util import RetrieveData from util import MakeHosts class QSubMakeHosts(QtCore.QThread, MakeHosts): """ QSubMakeHosts is a subclass of :class:`PyQt4.QtCore.QThread` and class :class:`~util.makehosts.MakeHosts`. This class contains methods to make a new hosts file for client. .. inheritance-diagram:: gui._make.QSubMakeHosts :parts: 1 .. note:: The instance of this class should be created in an individual thread. And an instance of class should be set as :attr:`parent` here. :ivar PyQt4.QtCore.pyqtSignal info_trigger: An instance of :class:`PyQt4.QtCore.pyqtSignal` to emit signal to the main dialog which indicates the current operation. .. note:: The signal :attr:`info_trigger` should be a tuple of (`mod_name`, mod_num`): * mod_name(`str`): Tag of a specified hosts module in current progress. * mod_num(`int`): Number of current module in the operation sequence. .. seealso:: Method :meth:`~gui.qdialog_ui.QDialogUI.set_make_progress` in :class:`~gui.qdialog_ui.QDialogUI` class. :ivar PyQt4.QtCore.pyqtSignal fina_trigger: An instance of :class:`PyQt4.QtCore.pyqtSignal` to emit signal to the main dialog which notifies statistics to the main dialog. .. note:: The signal :attr:`fina_trigger` should be a tuple of (`time`, count`): * time(`str`): Total time uesd while generating the new hosts file. * count(`int`): Total number of hosts entries inserted into the new hosts file. .. seealso:: Method :meth:`~gui.qdialog_d.QDialogDaemon.finish_make` in :class:`~gui.qdialog_d.QDialogDaemon` class. :ivar PyQt4.QtCore.pyqtSignal move_trigger: An instance of :class:`PyQt4.QtCore.pyqtSignal` to notify the main dialog while new hosts is being moved to specified path on current operating system. .. note:: This signal does not send any data. .. seealso:: Method :meth:`~gui.qdialog_d.QDialogDaemon.move_hosts` in :class:`~gui.qdialog_d.QDialogDaemon` class. .. seealso:: :class:`util.makehosts.MakeHosts` class. """ info_trigger = QtCore.pyqtSignal(str, int) fina_trigger = QtCore.pyqtSignal(str, int) move_trigger = QtCore.pyqtSignal() def __init__(self, parent): """ Initialize a new instance of this class. Retrieve configuration from the main dialog to make a new hosts file. :param parent: An instance of :class:`~gui.qdialog_d.QDialogDaemon` class to fetch settings from. :type parent: :class:`~gui.qdialog_d.QDialogDaemon` .. warning:: :attr:`parent` MUST NOT be set as `None`. """ QtCore.QThread.__init__(self, parent) MakeHosts.__init__(self, parent) def run(self): """ Start operations to retrieve data from the data file and generate new hosts file. """ start_time = time.time() self.make() end_time = time.time() total_time = "%.4f" % (end_time - start_time) self.fina_trigger.emit(total_time, self.count) if self.make_mode == "system": self.move_trigger.emit() def get_hosts(self, make_cfg): """ Make the new hosts file by the configuration defined by `make_cfg` from function list on the main dialog. :param make_cfg: Module settings in byte word format. :type make_cfg: dict .. seealso:: :attr:`make_cfg` in :class:`~tui.curses_d.CursesDaemon` class. """ for part_id in sorted(make_cfg.keys()): mod_cfg = make_cfg[part_id] if not RetrieveData.chk_mutex(part_id, mod_cfg): return mods = RetrieveData.get_ids(mod_cfg) for mod_id in mods: self.mod_num += 1 hosts, mod_name = RetrieveData.get_host(part_id, mod_id) self.info_trigger.emit(mod_name, self.mod_num) if part_id == 0x02: self.write_localhost_mod(hosts) elif part_id == 0x04: self.write_customized() else: self.write_common_mod(hosts, mod_name)
4,984
Python
.py
109
36.816514
77
0.606517
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,275
hostsutil.py
huhamhire_huhamhire-hosts/gui/hostsutil.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # hostsutil.py : Main entrance to GUI module of Hosts Setup Utility. # # Copyleft (C) 2014 - huhamhire hosts team <hosts@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # # This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import sys from zipfile import BadZipfile from qdialog_slots import QDialogSlots sys.path.append("..") from util import RetrieveData, CommonUtil # Path to store language files LANG_DIR = "./gui/lang/" class HostsUtil(QDialogSlots): """ HostsUtil class is the main entrance to the Graphical User Interface (GUI) module of `Hosts Setup Utility`. This class contains methods to launch the main dialog of this utility. .. note:: This class is subclass of :class:`~gui.qdialog_slots.QDialogSlots` class. Typical usage to start a GUI session:: import gui util = gui.HostsUtil() util.start() :ivar int init_flag: Times of the main dialog being initialized. This value would be referenced for translator to set the language of the main dialog. :ivar str filename: Filename of the hosts data file containing data to make hosts files from. Default by "`hostslist.data`". :ivar str infofile: Filename of the info file containing metadata of the hosts data file formatted in JSON. Default by "`hostslist.json`". .. seealso:: :attr:`filename` and :attr:`infofile` in :class:`~tui.curses_ui.CursesUI` class. """ init_flag = 0 # Data file related configuration filename = "hostslist.data" infofile = "hostsinfo.json" def __init__(self): super(HostsUtil, self).__init__() def __del__(self): """ Clear up the temporary data file while TUI session is finished. """ try: RetrieveData.clear() except: pass def start(self): """ Start the GUI session. .. note:: This method is the trigger to launch a GUI session of `Hosts Setup Utility`. """ if not self.init_flag: self.init_main() self.show() sys.exit(self.app.exec_()) def init_main(self): """ Set up the elements on the main dialog. Check the environment of current operating system and current session. * Load server list from a configuration file under working directory. * Try to load the hosts data file under working directory if it exists. .. note:: IF hosts data file does not exists correctly in current working directory, a warning message box would popup. And operations to change the hosts file on current system could be done only until a new data file has been downloaded. .. seealso:: Method :meth:`~tui.hostsutil.HostsUtil.__init__` in :class:`~tui.hostsutil.HostsUtil` class. """ self.ui.SelectMirror.clear() self.set_version() # Set mirrors self.mirrors = CommonUtil.set_network("network.conf") self.set_mirrors() # Read data file and set function list try: RetrieveData.unpack() RetrieveData.connect_db() self.set_func_list(1) self.refresh_func_list() self.set_info() except IOError: self.warning_no_datafile() except BadZipfile: self.warning_incorrect_datafile() # Check if current session have root privileges self.check_writable() self.init_flag += 1 if __name__ == "__main__": HostsUtlMain = HostsUtil() HostsUtlMain.start()
4,139
Python
.py
104
32.701923
78
0.62902
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,276
qdialog_ui.py
huhamhire_huhamhire-hosts/gui/qdialog_ui.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # qdialog_ui.py : Draw the Graphical User Interface. # # Copyleft (C) 2014 - huhamhire hosts team <hosts@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # # This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import os from PyQt4 import QtCore, QtGui import sys sys.path.append("..") from util import RetrieveData, CommonUtil from __version__ import __version__, __release__ from language import LangUtil from util_ui import Ui_Util, _translate, _fromUtf8 # Path to store language files LANG_DIR = "./gui/lang/" class QDialogUI(QtGui.QDialog, object): """ CursesUI class contains methods to draw the Graphical User Interface (GUI) of Hosts Setup Utility. The methods to make GUI here are based on `PyQT4 <http://pyqt.sourceforge.net/Docs/PyQt4/>`_. .. note:: This class is subclass of :class:`QtGui.QDialog` class and :class:`object` class. :ivar str _cur_ver: Current version of local hosts data file. :ivar QtCore.QTranslator _trans: An instance of :class:`QtCore.QTranslator` object indicating the current UI language setting. :ivar QtGui.QApplication app: An instance of :class:`QtGui.QApplication` object to launch the Qt application. :ivar list mirrors: Dictionaries containing `tag`, `test url`, and `update url` of mirror servers. :ivar str platform: Platform of current operating system. The value could be `Windows`, `Linux`, `Unix`, `OS X`, and of course `Unknown`. :ivar bool plat_flag: A flag indicating whether current operating system is supported or not. :ivar object ui: Form implementation declares layout of the main dialog which is generated from a UI file designed by `Qt Designer`. :ivar str custom: File name of User Customized Hosts File. Customized hosts would be able to select if this file exists. The default file name is ``custom.hosts``. .. seealso:: :ref:`User Customized Hosts<intro-customize>`. """ _cur_ver = "" _trans = None app = None mirrors = [] platform = '' plat_flag = True ui = None custom = "custom.hosts" def __init__(self): """ Initialize a new instance of this class. Set the UI object and current translator of the main dialog. """ self.app = QtGui.QApplication(sys.argv) super(QDialogUI, self).__init__() self.ui = Ui_Util() self.ui.setupUi(self) self.set_style() self.set_stylesheet() # Set default UI language trans = QtCore.QTranslator() trans.load(LANG_DIR + "en_US") self._trans = trans self.app.installTranslator(trans) self.set_languages() def set_stylesheet(self): """ Set the style sheet of main dialog. .. seealso:: :ref:`QT Stylesheet<qt-stylesheet>`. """ with open("./gui/theme/default.qss", "r") as qss: self.app.setStyleSheet(qss.read()) def set_style(self): """ Set the main dialog with a window style depending on the os platform. """ self.setWindowFlags(QtCore.Qt.FramelessWindowHint) system = self.platform if system == "Windows": pass elif system == "Linux": # Set window style for sudo users. QtGui.QApplication.setStyle( QtGui.QStyleFactory.create("Cleanlooks")) elif system == "OS X": pass def set_languages(self): """ Set optional language selection items in the SelectLang widget. """ self.ui.SelectLang.clear() langs = LangUtil.language langs_not_found = [] for locale in langs: if not os.path.isfile(LANG_DIR + locale + ".qm"): langs_not_found.append(locale) for locale in langs_not_found: langs.pop(locale) LangUtil.language = langs if len(langs) <= 1: self.ui.SelectLang.setEnabled(False) # Block the signal while set the language selecions. self.ui.SelectLang.blockSignals(True) sys_locale = LangUtil.get_locale() if sys_locale not in langs.keys(): sys_locale = "en_US" for i, locale in enumerate(sorted(langs.keys())): if sys_locale == locale: select = i lang = langs[locale] self.ui.SelectLang.addItem(_fromUtf8("")) self.ui.SelectLang.setItemText(i, lang) self.ui.SelectLang.blockSignals(False) self.ui.SelectLang.setCurrentIndex(select) def set_mirrors(self): """ Set optional server list. """ for i, mirror in enumerate(self.mirrors): self.ui.SelectMirror.addItem(_fromUtf8("")) self.ui.SelectMirror.setItemText( i, _translate("Util", mirror["tag"], None)) self.set_platform_label() def set_label_color(self, label, color): """ Set the :attr:`color` of a :attr:`label`. :param label: Label on the main dialog. :type: :class:`PyQt4.QtGui.QLabel` :param color: Color to be set on the label. :type color: str """ if color == "GREEN": rgb = "#37b158" elif color == "RED": rgb = "#e27867" elif color == "BLACK": rgb = "#b1b1b1" else: rgb = "#ffffff" label.setStyleSheet("QLabel {color: %s}" % rgb) def set_label_text(self, label, text): """ Set the :attr:`text` of a :attr:`label`. :param label: Label on the main dialog. :type: :class:`PyQt4.QtGui.QLabel` :param text: Message to be set on the label. :type text: unicode """ label.setText(_translate("Util", text, None)) def set_conn_status(self, status): """ Set the information of connection status to the current server selected. """ if status == -1: self.set_label_color(self.ui.labelConnStat, "BLACK") self.set_label_text(self.ui.labelConnStat, unicode( _translate("Util", "Checking...", None))) elif status in [0, 1]: if status: color, stat = "GREEN", unicode(_translate( "Util", "[OK]", None)) else: color, stat = "RED", unicode(_translate( "Util", "[Failed]", None)) self.set_label_color(self.ui.labelConnStat, color) self.set_label_text(self.ui.labelConnStat, stat) def set_version(self): version = "".join(['v', __version__, ' ', __release__]) self.set_label_text(self.ui.VersionLabel, version) def set_info(self): """ Set the information of the current local data file. """ info = RetrieveData.get_info() ver = info["Version"] self._cur_ver = ver self.set_label_text(self.ui.labelVersionData, ver) build = info["Buildtime"] build = CommonUtil.timestamp_to_date(build) self.set_label_text(self.ui.labelReleaseData, unicode(build)) def set_down_progress(self, progress, message): """ Set :attr:`progress` position of the progress bar with a :attr:`message`. :param progress: Progress position to be set on the progress bar. :type progress: int :param message: Message to be set on the progress bar. :type message: str """ self.ui.Prog.setProperty("value", progress) self.set_conn_status(1) self.ui.Prog.setFormat(message) def set_platform_label(self): """ Set the information of the label indicating current operating system platform. """ color = "GREEN" if self.plat_flag else "RED" self.set_label_color(self.ui.labelOSStat, color) self.set_label_text(self.ui.labelOSStat, "[%s]" % self.platform) def set_func_list(self, new=0): """ Draw the function list and decide whether to load the default selection configuration or not. :param new: A flag indicating whether to load the default selection configuration or not. Default value is `0`. === =================== new Operation === =================== 0 Use user config. 1 Use default config. === =================== :type new: int """ self.ui.Functionlist.clear() self.ui.FunctionsBox.setTitle(_translate( "Util", "Functions", None)) if new: for ip in range(2): choice, defaults, slices = RetrieveData.get_choice(ip) if os.path.isfile(self.custom): choice.insert(0, [4, 1, 0, "customize"]) defaults[0x04] = [1] for i in range(len(slices)): slices[i] += 1 slices.insert(0, 0) self.choice[ip] = choice self.slices[ip] = slices funcs = [] for func in choice: if func[1] in defaults[func[0]]: funcs.append(1) else: funcs.append(0) self._funcs[ip] = funcs def set_list_item_unchecked(self, item_id): """ Set a specified item to become unchecked in the function list. :param item_id: Index number of a specified item in the function list. :type: int """ self._funcs[self._ipv_id][item_id] = 0 item = self.ui.Functionlist.item(item_id) item.setCheckState(QtCore.Qt.Unchecked) def refresh_func_list(self): """ Refresh the items in the function list by user settings. """ ip_flag = self._ipv_id self.ui.Functionlist.clear() for f_id, func in enumerate(self.choice[self._ipv_id]): item = QtGui.QListWidgetItem() if self._funcs[ip_flag][f_id] == 1: check = QtCore.Qt.Checked else: check = QtCore.Qt.Unchecked item.setCheckState(check) item.setText(_translate("Util", func[3], None)) self.ui.Functionlist.addItem(item) def set_make_progress(self, mod_name, mod_num): """ Start operations to show progress while making hosts file. .. note:: This method is the slot responses to the info_trigger signal :attr:`mod_name`, :attr:`mod_num` from an instance of :class:`~gui._make.QSubMakeHosts` class while making operations are proceeding. :param mod_name: Tag of a specified hosts module in current progress. :type mod_name: str :param mod_num: Number of current module in the operation sequence. :type mod_num: int .. seealso:: :attr:`info_trigger` in :class:`~gui._make.QSubMakeHosts` class. """ total_mods_num = self._funcs[self._ipv_id].count(1) + 1 prog = 100 * mod_num / total_mods_num self.ui.Prog.setProperty("value", prog) module = unicode(_translate("Util", mod_name, None)) message = unicode(_translate( "Util", "Applying module: %s(%s/%s)", None) ) % (module, mod_num, total_mods_num) self.ui.Prog.setFormat(message) self.set_make_message(message) def set_message(self, title, message): """ Show a message box with a :attr:`message` and a :attr:`title`. :param title: Title of the message box to be displayed. :type title: unicode :param message: Message in the message box. :type message: unicode """ self.ui.FunctionsBox.setTitle(_translate("Util", title, None)) self.ui.Functionlist.clear() item = QtGui.QListWidgetItem() item.setText(message) item.setFlags(QtCore.Qt.ItemIsEnabled) self.ui.Functionlist.addItem(item) def set_make_message(self, message, start=0): """ List message for the current operating progress while making the new hosts file in function list. :param message: Message to be displayed in the function list. :type message: unicode :param start: A flag indicating whether the message is the first one in the making progress or not. Default value is `0`. ===== ============== start Status ===== ============== 0 Not the first. 1 First. ===== ============== :type start: int """ if start: self.ui.FunctionsBox.setTitle(_translate( "Util", "Progress", None)) self.ui.Functionlist.clear() item = QtGui.QListWidgetItem() item.setText("- " + message) item.setFlags(QtCore.Qt.ItemIsEnabled) self.ui.Functionlist.addItem(item) def warning_permission(self): """ Show permission error warning message box. """ QtGui.QMessageBox.warning( self, _translate("Util", "Warning", None), _translate("Util", "You do not have permissions to change the \n" "hosts file.\n" "Please run this program as Administrator/root\n" "so it can modify your hosts file." , None)) def warning_download(self): """ Show download error warning message box. """ QtGui.QMessageBox.warning( self, _translate("Util", "Warning", None), _translate("Util", "Error retrieving data from the server.\n" "Please try another server.", None)) def warning_incorrect_datafile(self): """ Show incorrect data file warning message box. """ msg_title = "Warning" msg = unicode(_translate("Util", "Incorrect Data file!\n" "Please use the \"Download\" key to \n" "fetch a new data file.", None)) self.set_message(unicode(msg_title), msg) self.ui.ButtonApply.setEnabled(False) self.ui.ButtonANSI.setEnabled(False) self.ui.ButtonUTF.setEnabled(False) def warning_no_datafile(self): """ Show no data file warning message box. """ msg_title = "Warning" msg = unicode(_translate("Util", "Data file not found!\n" "Please use the \"Download\" key to \n" "fetch a new data file.", None)) self.set_message(unicode(msg_title), msg) self.ui.ButtonApply.setEnabled(False) self.ui.ButtonANSI.setEnabled(False) self.ui.ButtonUTF.setEnabled(False) def question_apply(self): """ Show confirm question message box before applying hosts file. :return: A flag indicating whether user has accepted to continue the operations or not. ====== ========= return Operation ====== ========= True Continue False Cancel ====== ========= :rtype: bool """ msg_title = unicode(_translate("Util", "Notice", None)) msg = unicode(_translate("Util", "Are you sure you want to apply changes \n" "to the hosts file on your system?\n\n" "This operation could not be reverted if \n" "you have not made a backup of your \n" "current hosts file.", None)) choice = QtGui.QMessageBox.question( self, msg_title, msg, QtGui.QMessageBox.Yes | QtGui.QMessageBox.No, QtGui.QMessageBox.No ) if choice == QtGui.QMessageBox.Yes: return True else: return False def info_uptodate(self): """ Draw data file is up-to-date message box. """ QtGui.QMessageBox.information( self, _translate("Util", "Notice", None), _translate("Util", "Data file is up-to-date.", None)) def info_complete(self): """ Draw operation complete message box. """ QtGui.QMessageBox.information( self, _translate("Util", "Complete", None), _translate("Util", "Operation completed", None)) def set_make_start_btns(self): """ Set button status while making hosts operations started. """ self.ui.Functionlist.setEnabled(False) self.ui.SelectIP.setEnabled(False) self.ui.ButtonCheck.setEnabled(False) self.ui.ButtonUpdate.setEnabled(False) self.ui.ButtonApply.setEnabled(False) self.ui.ButtonANSI.setEnabled(False) self.ui.ButtonUTF.setEnabled(False) self.ui.ButtonExit.setEnabled(False) def set_make_finish_btns(self): """ Set button status while making hosts operations finished. """ self.ui.Functionlist.setEnabled(True) self.ui.SelectIP.setEnabled(True) self.ui.ButtonCheck.setEnabled(True) self.ui.ButtonUpdate.setEnabled(True) self.ui.ButtonApply.setEnabled(False) self.ui.ButtonANSI.setEnabled(False) self.ui.ButtonUTF.setEnabled(False) self.ui.ButtonExit.setEnabled(True) def set_update_click_btns(self): """ Set button status while `CheckUpdate` button clicked. """ self.ui.ButtonApply.setEnabled(True) self.ui.ButtonANSI.setEnabled(True) self.ui.ButtonUTF.setEnabled(True) def set_update_start_btns(self): """ Set button status while operations to check update of hosts data file started. """ self.ui.SelectMirror.setEnabled(False) self.ui.ButtonCheck.setEnabled(False) self.ui.ButtonUpdate.setEnabled(False) def set_update_finish_btns(self): """ Set button status while operations to check update of hosts data file finished. """ self.ui.SelectMirror.setEnabled(True) self.ui.ButtonCheck.setEnabled(True) self.ui.ButtonUpdate.setEnabled(True) def set_fetch_click_btns(self): """ Set button status while `FetchUpdate` button clicked. """ self.ui.Functionlist.setEnabled(False) self.ui.ButtonApply.setEnabled(False) self.ui.ButtonANSI.setEnabled(False) self.ui.ButtonUTF.setEnabled(False) def set_fetch_start_btns(self): """ Set button status while operations to retrieve hosts data file started. """ self.ui.SelectMirror.setEnabled(False) self.ui.ButtonCheck.setEnabled(False) self.ui.ButtonUpdate.setEnabled(False) self.ui.ButtonApply.setEnabled(False) self.ui.ButtonANSI.setEnabled(False) self.ui.ButtonUTF.setEnabled(False) self.ui.ButtonExit.setEnabled(False) def set_fetch_finish_btns(self, error=0): """ Set button status while operations to retrieve hosts data file finished. :param error: A flag indicating if error occurs while retrieving hosts data file from the server. :type error: int """ if error: self.ui.ButtonApply.setEnabled(False) self.ui.ButtonANSI.setEnabled(False) self.ui.ButtonUTF.setEnabled(False) else: self.ui.ButtonApply.setEnabled(True) self.ui.ButtonANSI.setEnabled(True) self.ui.ButtonUTF.setEnabled(True) self.ui.Functionlist.setEnabled(True) self.ui.SelectMirror.setEnabled(True) self.ui.ButtonCheck.setEnabled(True) self.ui.ButtonUpdate.setEnabled(True) self.ui.ButtonExit.setEnabled(True)
20,730
Python
.py
511
30.363992
78
0.580559
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,277
qdialog_slots.py
huhamhire_huhamhire-hosts/gui/qdialog_slots.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # qdialog_slots.py : Qt slots response to signals on the main dialog. # # Copyleft (C) 2014 - huhamhire hosts team <hosts@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # # This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import shutil import time from PyQt4 import QtCore, QtGui from language import LangUtil from qdialog_d import QDialogDaemon from util_ui import _translate import sys sys.path.append("..") from util import RetrieveData class QDialogSlots(QDialogDaemon): """ QDialogSlots class provides `Qt slots` to deal with the `Qt signals` emitted by the widgets on the main dialog operated by users. .. note:: This class is subclass of :class:`~gui.qdialog_d.QDialogDaemon` class and parent class of :class:`~gui.hostsutil.HostsUtil`. :ivar int ipv_id: An flag indicating current IP version setting. The value could be 1 or 0: ====== ========== ipv_id IP Version ====== ========== 1 IPv6 0 IPv4 ====== ========== .. seealso:: :meth:`~gui.qdialog_slots.QDialogSlots.on_IPVersion_changed`. in this class. :ivar str make_path: Temporary path to store generated hosts file. The default value of :attr:`make_path` is "`./hosts`". :ivar int mirror_id: Index number of current selected server from the mirror list. """ _ipv_id = 0 make_path = "./hosts" mirror_id = 0 def __init__(self): """ Initialize a new instance of this class. """ super(QDialogSlots, self).__init__() def reject(self): """ Close this program while the reject signal is emitted. .. note:: This method is the slot responses to the reject signal from an instance of the main dialog. """ self.close() return QtGui.QDialog.reject(self) def close(self): """ Close this program while the close signal is emitted. .. note:: This method is the slot responses to the close signal from an instance of the main dialog. """ try: RetrieveData.clear() except: pass super(QDialogDaemon, self).close() def mouseMoveEvent(self, e): """ Allow drag operations to set the new position for current cursor. :param e: Current mouse event. :type e: :class:`PyQt4.QtGui.QMouseEvent` """ if e.buttons() & QtCore.Qt.LeftButton: try: self.move(e.globalPos() - self.dragPos) except AttributeError: pass e.accept() def mousePressEvent(self, e): """ Allow press operation to set the new position for current dialog. :param e: Current mouse event. :type e: :class:`PyQt4.QtGui.QMouseEvent` """ if e.button() == QtCore.Qt.LeftButton: self.dragPos = e.globalPos() - self.frameGeometry().topLeft() e.accept() def on_Mirror_changed(self, mirr_id): """ Change the current server selection. .. note:: This method is the slot responses to the signal argument :attr:`mirr_id` from SelectMirror widget while the value is changed. :param mirr_id: Index number of current mirror server. """ self.mirror_id = mirr_id self.check_connection() def on_IPVersion_changed(self, ipv_id): """ Change the current IP version setting. .. note:: This method is the slot responses to the signal argument :attr:`ipv_id` from SelectIP widget while the value is changed. :param ipv_id: An flag indicating current IP version setting. The value could be 1 or 0: ====== ========== ipv_id IP Version ====== ========== 1 IPv6 0 IPv4 ====== ========== :type ipv_id: int """ if self._ipv_id != ipv_id: self._ipv_id = ipv_id if not RetrieveData.db_exists(): self.warning_no_datafile() else: self.set_func_list(0) self.refresh_func_list() def on_Selection_changed(self, item): """ Change the current selection of modules to be applied to hosts file. .. note:: This method is the slot responses to the signal argument :attr:`item` from Functionlist widget while the item selection is changed. :param item: Row number of the item listed in Functionlist which is changed by user. :type item: int """ ip_flag = self._ipv_id func_id = self.ui.Functionlist.row(item) if self._funcs[ip_flag][func_id] == 0: self._funcs[ip_flag][func_id] = 1 else: self._funcs[ip_flag][func_id] = 0 mutex = RetrieveData.get_ids(self.choice[ip_flag][func_id][2]) for c_id, c in enumerate(self.choice[ip_flag]): if c[0] == self.choice[ip_flag][func_id][0]: if c[1] in mutex and self._funcs[ip_flag][c_id] == 1: self._funcs[ip_flag][c_id] = 0 self.refresh_func_list() def on_Lang_changed(self, lang): """ Change the UI language setting. .. note:: This method is the slot responses to the signal argument :attr:`lang` from SelectLang widget while the value is changed. :param lang: The language name which is selected by user. .. note:: This string is typically in the format of IETF language tag. For example: en_US, en_GB, etc. .. seealso:: :attr:`language` in :class:`~gui.language.LangUtil` class. :type lang: str """ new_lang = LangUtil.get_locale_by_language(unicode(lang)) trans = QtCore.QTranslator() from hostsutil import LANG_DIR trans.load(LANG_DIR + new_lang) self.app.removeTranslator(self._trans) self.app.installTranslator(trans) self._trans = trans self.ui.retranslateUi(self) self.init_main() self.check_connection() def on_MakeHosts_clicked(self): """ Start operations to make a hosts file. .. note:: This method is the slot responses to the signal from ButtonApply widget while the button is clicked. .. note:: No operations would be called if current session does not have the privileges to change the hosts file. """ if not self._writable: self.warning_permission() return if self.question_apply(): self.make_path = "./hosts" self.make_hosts("system") else: return def on_MakeANSI_clicked(self): """ Export a hosts file encoded in ANSI. .. note:: This method is the slot responses to the signal from ButtonANSI widget while the button is clicked. """ self.make_path = self.export_hosts() if unicode(self.make_path) != u'': self.make_hosts("ansi") def on_MakeUTF8_clicked(self): """ Export a hosts file encoded in UTF-8. .. note:: This method is the slot responses to the signal from ButtonUTF widget while the button is clicked. """ self.make_path = self.export_hosts() if unicode(self.make_path) != u'': self.make_hosts("utf-8") def on_Backup_clicked(self): """ Backup the hosts file of current operating system. .. note:: This method is the slot responses to the signal from ButtonBackup widget while the button is clicked. """ l_time = time.localtime(time.time()) backtime = time.strftime("%Y-%m-%d-%H%M%S", l_time) filename = "hosts_" + backtime + ".bak" if self.platform == "OS X": filename = "/Users/" + filename filepath = QtGui.QFileDialog.getSaveFileName( self, _translate("Util", "Backup hosts", None), QtCore.QString(filename), _translate("Util", "Backup File(*.bak)", None)) if unicode(filepath) != u'': shutil.copy2(self.hosts_path, unicode(filepath)) self.info_complete() def on_Restore_clicked(self): """ Restore a previously backed up hosts file. .. note:: This method is the slot responses to the signal from ButtonRestore widget while the button is clicked. This method would call .. note:: No operations would be called if current session does not have the privileges to change the hosts file. """ if not self._writable: self.warning_permission() return filename = '' if self.platform == "OS X": filename = "/Users/" + filename filepath = QtGui.QFileDialog.getOpenFileName( self, _translate("Util", "Restore hosts", None), QtCore.QString(filename), _translate("Util", "Backup File(*.bak)", None)) if unicode(filepath) != u'': shutil.copy2(unicode(filepath), self.hosts_path) self.info_complete() def on_CheckUpdate_clicked(self): """ Retrieve update information (metadata) of the latest data file from a specified server. .. note:: This method is the slot responses to the signal from ButtonCheck widget while the button is clicked. """ if self.choice != [[], []]: self.refresh_func_list() self.set_update_click_btns() if self._update == {} or self._update["version"] == \ unicode(_translate("Util", "[Error]", None)): self.check_update() def on_FetchUpdate_clicked(self): """ Retrieve the latest hosts data file. .. note:: This method is the slot responses to the signal from ButtonUpdate widget while the button is clicked. This method would call operations to .. note:: Method :meth:`~gui.qdialog_slots.on_CheckUpdate_clicked` would be called if no update information has been set, .. note:: If the current data is up-to-date, no data file would be retrieved. """ self.set_fetch_click_btns() self._down_flag = 1 if self._update == {} or self._update["version"] == \ unicode(_translate("Util", "[Error]", None)): self.check_update() elif self.new_version(): self.fetch_update() else: self.info_uptodate() self.finish_fetch() def on_LinkActivated(self, url): """ Open external link in browser. .. note:: This method is the slot responses to the signal from a Label widget while the text with a hyperlink which is clicked by user. """ QtGui.QDesktopServices.openUrl(QtCore.QUrl(url))
11,695
Python
.py
286
31.293706
78
0.58
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,278
_checkupdate.py
huhamhire_huhamhire-hosts/gui/_checkupdate.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # _checkupdate.py: Check update info of the latest data file. # # Copyleft (C) 2014 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import json import socket import urllib from PyQt4 import QtCore from util_ui import _translate class QSubChkUpdate(QtCore.QThread): """ QSubChkConnection is a subclass of :class:`PyQt4.QtCore.QThread`. This class contains methods to retrieve the metadata of the latest hosts data file. .. inheritance-diagram:: gui._checkupdate.QSubChkUpdate :parts: 1 .. note:: The instance of this class should be created in an individual thread. And an instance of class should be set as :attr:`parent` here. :ivar PyQt4.QtCore.pyqtSignal trigger: An instance of :class:`PyQt4.QtCore.pyqtSignal` to emit signal to the main dialog which indicates current status. .. note:: The signal :attr:`trigger` should be a dictionary (`dict`) containing metadata of the latest hosts data file. .. seealso:: Method :meth:`~gui.qdialog_d.QDialogDaemon.finish_update` in :class:`~gui.qdialog_d.QDialogDaemon` class. """ trigger = QtCore.pyqtSignal(dict) def __init__(self, parent): """ Initialize a new instance of this class. Retrieve mirror settings from the main dialog to check the update information. :param parent: An instance of :class:`~gui.qdialog_d.QDialogDaemon` class to fetch settings from. :type parent: :class:`~gui.qdialog_d.QDialogDaemon` .. warning:: :attr:`parent` MUST NOT be set as `None`. """ super(QSubChkUpdate, self).__init__(parent) self.url = parent.mirrors[parent.mirror_id]["update"] + parent.infofile def run(self): """ Start operations to retrieve the metadata of the latest hosts data file. """ try: socket.setdefaulttimeout(5) urlobj = urllib.urlopen(self.url) j_str = urlobj.read() urlobj.close() info = json.loads(j_str) self.trigger.emit(info) except: info = {"version": unicode(_translate("Util", "[Error]", None))} self.trigger.emit(info)
2,667
Python
.py
62
36.112903
79
0.620996
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,279
_pylupdate4.py
huhamhire_huhamhire-hosts/gui/pyqt/_pylupdate4.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # _pylupdate4.py : Tools to update the language files for UI # # Copyleft (C) 2013 - huhamhire hosts team <hosts@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # # This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE. # ===================================================================== import os for root, dirs, files in os.walk('.'): for f in files: if f.endswith('.pro'): os.system('pylupdate4 %s' % f)
819
Python
.py
20
38.65
71
0.583438
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,280
_pyuic4.py
huhamhire_huhamhire-hosts/gui/pyqt/_pyuic4.py
#!/usr/bin/python # -*- coding: utf-8 -*- # # _pyuic4.py : Tools update the UI code from UI design # # Copyleft (C) 2013 - huhamhire hosts team <hosts@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # # This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE. # ===================================================================== import os PROJ_DIR = '../' for root, dirs, files in os.walk(PROJ_DIR): for f in files: file_path = os.path.join(root, f) out_path = os.path.join(PROJ_DIR, f.rsplit('.', 1)[0]) if f.endswith('.ui'): os.system('pyuic4 -o %s.py -x %s' % (out_path, file_path)) print("make: %s.py" % out_path) elif f.endswith('.qrc'): os.system('pyrcc4 -o %s_rc.py %s' % (out_path, file_path)) print("make: %s_rc.py" % out_path) else: pass
1,190
Python
.py
29
36.344828
71
0.552677
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,281
conf.py
huhamhire_huhamhire-hosts/doc/dev/conf.py
# -*- coding: utf-8 -*- # # huhamhire-hosts documentation build configuration file, created by # sphinx-quickstart on Tue Jan 14 10:49:55 2014. # # This file is execfile()d with the current directory set to its # containing dir. # # Note that not all possible configuration values are present in this # autogenerated file. # # All configuration values have a default; values that are commented out # serve to show the default. import sys import os sys.path.insert(0, os.path.abspath('../../')) extensions = [ 'sphinx.ext.autodoc', 'sphinx.ext.pngmath', 'sphinx.ext.viewcode', 'sphinx.ext.graphviz', 'sphinx.ext.inheritance_diagram', ] # Add any paths that contain templates here, relative to this directory. templates_path = ['_templates'] # The suffix of source filenames. source_suffix = '.rst' # The encoding of source files. #source_encoding = 'utf-8-sig' # The master toctree document. master_doc = 'index' # General information about the project. project = u'Hosts Setup Utility' copyright = u'2011-2014, huhamhire-hosts team' # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the # built documents. # # The short X.Y version. version = '1.9.8' # The full version, including alpha/beta/rc tags. release = '1.9.8 beta' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. #language = None # There are two options for replacing |today|: either, you set today to some # non-false value, then it is used: #today = '' # Else, today_fmt is used as the format for a strftime call. #today_fmt = '%B %d, %Y' # List of patterns, relative to source directory, that match files and # directories to ignore when looking for source files. #exclude_patterns = [] #unused_docs = ["gpl"] # The reST default role (used for this markup: `text`) to use for all # documents. #default_role = None # If true, '()' will be appended to :func: etc. cross-reference text. #add_function_parentheses = True # If true, the current module name will be prepended to all description # unit titles (such as .. function::). #add_module_names = True # If true, sectionauthor and moduleauthor directives will be shown in the # output. They are ignored by default. #show_authors = False # The name of the Pygments (syntax highlighting) style to use. pygments_style = 'sphinx' # A list of ignored prefixes for module index sorting. #modindex_common_prefix = [] # If true, keep warnings as "system message" paragraphs in the built documents. #keep_warnings = False # -- Options for HTML output ---------------------------------------------- # The theme to use for HTML and HTML Help pages. See the documentation for # a list of builtin themes. html_theme = 'default' # Theme options are theme-specific and customize the look and feel of a theme # further. For a list of options available for each theme, see the # documentation. #html_theme_options = {} html_theme_options = { "stickysidebar": True, "collapsiblesidebar": False, } # Add any paths that contain custom themes here, relative to this directory. #html_theme_path = [] # The name for this set of Sphinx documents. If None, it defaults to # "<project> v<release> documentation". #html_title = None # A shorter title for the navigation bar. Default is the same as html_title. #html_short_title = None # The name of an image file (relative to this directory) to place at the top # of the sidebar. #html_logo = None # The name of an image file (within the static path) to use as favicon of the # docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32 # pixels large. #html_favicon = None # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files, # so a file named "default.css" will overwrite the builtin "default.css". html_static_path = ['_static'] # Add any extra paths that contain custom files (such as robots.txt or # .htaccess) here, relative to this directory. These files are copied # directly to the root of the documentation. #html_extra_path = [] # If not '', a 'Last updated on:' timestamp is inserted at every page bottom, # using the given strftime format. #html_last_updated_fmt = '%b %d, %Y' # If true, SmartyPants will be used to convert quotes and dashes to # typographically correct entities. #html_use_smartypants = True # Custom sidebar templates, maps document names to template names. #html_sidebars = {} # Additional templates that should be rendered to pages, maps page names to # template names. #html_additional_pages = {} # If false, no module index is generated. #html_domain_indices = True # If false, no index is generated. #html_use_index = True # If true, the index is split into individual pages for each letter. #html_split_index = False # If true, links to the reST sources are added to the pages. #html_show_sourcelink = True # If true, "Created using Sphinx" is shown in the HTML footer. Default is True. #html_show_sphinx = True # If true, "(C) Copyright ..." is shown in the HTML footer. Default is True. #html_show_copyright = True # If true, an OpenSearch description file will be output, and all pages will # contain a <link> tag referring to it. The value of this option must be the # base URL from which the finished HTML is served. #html_use_opensearch = '' # This is the file name suffix for HTML files (e.g. ".xhtml"). #html_file_suffix = None # Output file base name for HTML help builder. htmlhelp_basename = 'huhamhire-hostsdoc' # -- Options for LaTeX output --------------------------------------------- latex_elements = { 'inputenc': '', 'utf8extra': '', 'preamble': ''' \\hypersetup{unicode=true} \\usepackage{CJKutf8} \\AtBeginDocument{\\begin{CJK}{UTF8}{}} \\AtEndDocument{\\end{CJK}} ''', 'papersize': 'a4paper', # The paper size ('letterpaper' or 'a4paper'). #'papersize': 'letterpaper', # The font size ('10pt', '11pt' or '12pt'). #'pointsize': '10pt', # Additional stuff for the LaTeX preamble. #'preamble': '', } # Grouping the document tree into LaTeX files. List of tuples # (source start file, target name, title, # author, documentclass [howto, manual, or own class]). latex_documents = [ ('index', 'huhamhire-hosts.tex', u'Hosts Setup Utility Documentation', u'huhamhire-hosts team', 'manual'), ] # The name of an image file (relative to this directory) to place at the top of # the title page. #latex_logo = None # For "manual" documents, if this is true, then toplevel headings are parts, # not chapters. #latex_use_parts = False # If true, show page references after internal links. latex_show_pagerefs = True # If true, show URL addresses after external links. latex_show_urls = True # Documents to append as an appendix to all manuals. latex_appendices = ['gpl'] # If false, no module index is generated. #latex_domain_indices = True # -- Options for manual page output --------------------------------------- # One entry per manual page. List of tuples # (source start file, name, description, authors, manual section). man_pages = [ ('index', 'huhamhire-hosts', u'Hosts Setup Utility Documentation', [u'huhamhire-hosts team'], 1) ] # If true, show URL addresses after external links. #man_show_urls = False # -- Options for Texinfo output ------------------------------------------- # Grouping the document tree into Texinfo files. List of tuples # (source start file, target name, title, author, # dir menu entry, description, category) texinfo_documents = [ ('index', 'huhamhire-hosts', u'Hosts Setup Utility Documentation', u'huhamhire-hosts team', 'huhamhire-hosts', 'Easy managing hosts file.', 'Miscellaneous'), ] # Documents to append as an appendix to all manuals. #texinfo_appendices = [] # If false, no module index is generated. #texinfo_domain_indices = True # How to display URL addresses: 'footnote', 'no', or 'inline'. #texinfo_show_urls = 'footnote' # If true, do not generate a @detailmenu in the "Top" node's menu. #texinfo_no_detailmenu = False
8,175
Python
.py
201
39.029851
79
0.72948
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,282
_update.py
huhamhire_huhamhire-hosts/tui/_update.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # _update.py: Retrieve hosts data file. # # Copyleft (C) 2013 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import os import socket import urllib class FetchUpdate(object): """ FetchUpdate class contains methods to retrieve the latest hosts data file from the project server. :ivar str url: The URL of the latest hosts data file. :ivar str path: Destination path to save the data file downloaded. :ivar str tmp_path: Temporary path to save the data file while downloading. :ivar int file_size: Size of the data file in bytes. :ivar CursesDaemon parent: An instance of :class:`~tui.curses_d.CursesDaemon` class to get configuration with. """ def __init__(self, parent): """ Initialize a new instance of this class :param parent: An instance of :class:`~tui.curses_d.CursesDaemon` class to get configuration with. :type parent: :class:`~tui.curses_d.CursesDaemon` """ mirror_id = parent.settings[0][1] mirror = parent.settings[0][2][mirror_id] self.url = mirror["update"] + parent.filename self.path = "./" + parent.filename self.tmp_path = self.path + ".download" self.file_size = parent._update["size"] self.parent = parent def get_file(self): """ Fetch the latest hosts data file from project server. """ socket.setdefaulttimeout(10) try: urllib.urlretrieve(self.url, self.tmp_path, self.parent.process_bar) self.replace_old() except Exception, e: raise e def replace_old(self): """ Replace the old hosts data file with the new one. """ if os.path.isfile(self.path): os.remove(self.path) os.rename(self.tmp_path, self.path)
2,293
Python
.py
59
31.983051
77
0.596586
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,283
__doc__.py
huhamhire_huhamhire-hosts/tui/__doc__.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # __doc__.py Document in reST format of tui module. # # Copyleft (C) 2014 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== """ .. _tui-module: Text-based User Interface (TUI) =============================== The following sections describe the objects and methods from the Text-based User Interface (TUI) module of huhamhire-hosts HostsUtil. The methods to make TUI here are based on `curses <http://docs.python.org/2/library/curses.html>`_. HostsUtil(TUI) -------------- .. autoclass:: tui.hostsutil.HostsUtil :members: .. automethod:: tui.hostsutil.HostsUtil.__init__ .. automethod:: tui.hostsutil.HostsUtil.__del__ CursesDaemon ------------ .. autoclass:: tui.curses_d.CursesDaemon :members: CursesUI -------- .. autoclass:: tui.curses_ui.CursesUI :members: .. automethod:: tui.curses_ui.CursesUI.__init__ .. automethod:: tui.curses_ui.CursesUI.__del__ FetchUpdate ----------- .. autoclass:: tui._update.FetchUpdate :members: .. automethod:: tui._update.FetchUpdate.__init__ """
1,404
Python
.py
41
32.04878
77
0.60963
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,284
curses_d.py
huhamhire_huhamhire-hosts/tui/curses_d.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # curses_d.py: Operations for TUI window. # # Copyleft (C) 2014 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import curses import json import os import shutil import socket import urllib import sys from curses_ui import CursesUI from _update import FetchUpdate sys.path.append("..") from util import CommonUtil, RetrieveData from util import MakeHosts class CursesDaemon(CursesUI): """ CursesDaemon class contains methods to deal with the operations related to the TUI window of `Hosts Setup Utility`. Including methods to interactive with users. .. note:: This class is subclass of :class:`~tui.curses_ui.CursesUI` class. :ivar dict _update: Update information of the current data file on server. :ivar int _writable: Indicating whether the program is run with admin/root privileges. The value could be `1` or `0`. .. seealso:: `_update` and `_writable` in :class:`~gui.qdialog_d.QDialogDaemon` class. :ivar dict make_cfg: A set of module selection control bytes used to control whether a specified method is used or not while generate a hosts file. * `Keys` of :attr:`make_cfg` are typically 8-bit control byte indicating which part of the hosts data file would be effected by the corresponding `Value`. +----+----------------+ |Key |Part | +====+================+ |0x02|Localhost | +----+----------------+ |0x08|Shared hosts | +----+----------------+ |0x10|IPv4 hosts | +----+----------------+ |0x20|IPv6 hosts | +----+----------------+ |0x40|AD block hosts | +----+----------------+ * `Values` of :attr:`make_cfg` are typically 16-bit control bytes that decides which of the modules in a specified part would be inserted into the `hosts` file. * `Value` of `Localhost` part. The Value used in `Localhost` part are usually bytes indicating the current operating system. +---------------+-------------------+ |Hex |OS | +===============+===================+ |0x0001 |Windows | +---------------+-------------------+ |0x0002 |Linux, Unix | +---------------+-------------------+ |0x0004 |Mac OS X | +---------------+-------------------+ * `Values` of `Shared hosts`, `IPv4 hosts`, `IPv6 hosts`, and `AD block hosts` parts are usually sum of module IDs selected by user. .. note:: If modules in specified part whose IDs are `0x0002` and `0x0010`, the value here should be `0x0002 + 0x0010 = 0x0012`, which is `0b0000000000000010 + 0b0000000000010000 = 0b0000000000010010` in binary. .. warning:: Only one bit could be `1` in the binary form of a module ID, which means `0b0000000000010010` is an INVALID module ID while it could be a VALID `Value` in `make_cfg`. :ivar str platform: Platform of current operating system. The value could be `Windows`, `Linux`, `Unix`, `OS X`, and of course `Unknown`. :ivar str hostname: The hostname of current operating system. .. note:: This attribute would only be used on linux. :ivar str hosts_path: The absolute path to the hosts file on current operating system. :ivar str make_mode: Operation mode for making hosts file. The valid value could be one of `system`, `ansi`, and `utf-8`. .. seealso:: :attr:`make_mode` in :class:`~util.makehosts.MakeHosts` class. :ivar str make_path: Temporary path to store generated hosts file. The default value of :attr:`make_path` is "`./hosts`". :ivar list _ops_keys: Hot keys used to start a specified operation. Default operation keys are `F5`, `F6`, and `F10`. :ivar list _hot_keys: Hot keys used to select a item or confirm an operation. And the default :attr:`_hot_keys` is defined as:: _hot_keys = [curses.KEY_UP, curses.KEY_DOWN, 10, 32] .. seealso:: :attr:`~tui.curses_ui.CursesUI.funckeys` in :class:`~tui.curses_ui.CursesUI` class. """ _update = {} _writable = 0 make_cfg = {} platform = '' hostname = '' hosts_path = '' make_mode = '' make_path = "./hosts" _ops_keys = [curses.KEY_F5, curses.KEY_F6, curses.KEY_F10] _hot_keys = [curses.KEY_UP, curses.KEY_DOWN, 10, 32] def __init__(self): super(CursesDaemon, self).__init__() self.check_writable() def check_writable(self): """ Check if current session has write privileges to the hosts file. .. note:: IF current session does not has the write privileges to the hosts file of current system, a warning message box would popup. .. note:: ALL operation would change the `hosts` file on current system could only be done while current session has write privileges to the file. """ self._writable = CommonUtil.check_privileges()[1] if not self._writable: self.messagebox("Please check if you have writing\n" "privileges to the hosts file!", 1) exit() def session_daemon(self): """ Operations processed while running a TUI session of `Hosts Setup Utility`. :return: A flag indicating whether to reload the current session or all operations have been finished. The return value could only be `0` or `1`. To be specific: ==== ========= flag operation ==== ========= 0 Finish 1 Reload ==== ========= .. note:: Reload operation is called only when a new data file is retrieved from server. :rtype: int .. note:: IF hosts data file does not exists in current working directory, a warning message box would popup. And operations to change the hosts file on current system could be done only until a new data file has been downloaded. """ screen = self._stdscr.subwin(0, 0, 0, 0) screen.keypad(1) # Draw Menu self.banner() self.footer() # Key Press Operations key_in = None tab = 0 pos = 0 tab_entry = [self.configure_settings, self.select_func] while key_in != 27: self.setup_menu() self.status() self.process_bar(0, 0, 0, 0) for i, sec in enumerate(tab_entry): tab_entry[i](pos if i == tab else None) if key_in is None: test = self.settings[0][2][0]["test_url"] self.check_connection(test) key_in = screen.getch() if key_in == 9: if self.choice == [[], []]: tab = 0 else: tab = not tab pos = 0 elif key_in in self._hot_keys: pos = tab_entry[tab](pos, key_in) elif key_in in self._ops_keys: if key_in == curses.KEY_F10: if self._funcs == [[], []]: self.messagebox("No data file found! Press F6 to get " "data file first.", 1) else: msg = "Apply Changes to hosts file?" confirm = self.messagebox(msg, 2) if confirm: self.set_config_bytes() self.make_mode = "system" maker = MakeHosts(self) maker.make() self.move_hosts() elif key_in == curses.KEY_F5: self._update = self.check_update() elif key_in == curses.KEY_F6: if self._update == {}: self._update = self.check_update() # Check if data file up-to-date if self.new_version(): self.fetch_update() return 1 else: self.messagebox("Data file is up-to-date!", 1) else: pass return 0 def configure_settings(self, pos=None, key_in=None): """ Perform operations to config settings if `Configure Setting` frame is active, or just draw the `Configure Setting` frame with no items selected while it is inactive. .. note:: Whether the `Configure Setting` frame is inactive is decided by if :attr:`pos` is `None` or not. =========== ======== :attr:`pos` Status =========== ======== None Inactive int Active =========== ======== :param pos: Index of selected item in `Configure Setting` frame. The default value of `pos` is `None`. :type pos: int or None :param key_in: A flag indicating the key pressed by user. The default value of `key_in` is `None`. :type key_in: int or None :return: Index of selected item in `Configure Setting` frame. :rtype: int or None """ id_num = range(len(self.settings)) if pos is not None: if key_in == curses.KEY_DOWN: pos = list(id_num[1:] + id_num[:1])[pos] elif key_in == curses.KEY_UP: pos = list(id_num[-1:] + id_num[:-1])[pos] elif key_in in [10, 32]: self.sub_selection(pos) self.info(pos, 0) self.configure_settings_frame(pos) return pos def select_func(self, pos=None, key_in=None): """ Perform operations if `function selection list` is active, or just draw the `function selection list` with no items selected while it is inactive. .. note:: Whether the `function selection list` is inactive is decided by if :attr:`pos` is `None` or not. .. seealso:: :meth:`~tui.curses_d.CursesDaemon.configure_settings`. :param pos: Index of selected item in `function selection list`. The default value of `pos` is `None`. :type pos: int or None :param key_in: A flag indicating the key pressed by user. The default value of `key_in` is `None`. :type key_in: int or None :return: Index of selected item in `function selection list`. :rtype: int or None """ list_height = 15 ip = self.settings[1][1] # Key Press Operations item_len = len(self.choice[ip]) item_sup, item_inf = self._item_sup, self._item_inf if pos is not None: if item_len > list_height: if pos <= 1: item_sup = 0 item_inf = list_height - 1 elif pos >= item_len - 2: item_sup = item_len - list_height + 1 item_inf = item_len else: item_sup = 0 item_inf = item_len if key_in == curses.KEY_DOWN: pos += 1 if pos >= item_len: pos = 0 if pos not in range(item_sup, item_inf): item_sup += 2 if item_sup == 0 else 1 item_inf += 1 elif key_in == curses.KEY_UP: pos -= 1 if pos < 0: pos = item_len - 1 if pos not in range(item_sup, item_inf): item_inf -= 2 if item_inf == item_len else 1 item_sup -= 1 elif key_in in [10, 32]: self._funcs[ip][pos] = not self._funcs[ip][pos] mutex = RetrieveData.get_ids(self.choice[ip][pos][2]) for c_id, c in enumerate(self.choice[ip]): if c[0] == self.choice[ip][pos][0]: if c[1] in mutex and self._funcs[ip][c_id] == 1: self._funcs[ip][c_id] = 0 self.info(pos, 1) else: item_sup = 0 if item_len > list_height: item_inf = list_height - 1 else: item_inf = item_len self.show_funclist(pos, item_sup, item_inf) return pos def sub_selection(self, pos): """ Let user to choose settings from `Selection Dialog` specified by :attr:`pos`. :param pos: Index of selected item in `Configure Setting` frame. :type pos: int .. warning:: The value of `pos` MUST NOT be `None`. .. seealso:: :meth:`~tui.curses_ui.CursesUI.sub_selection_dialog` in :class:`~tui.curses_ui.CursesUI`. """ screen = self.sub_selection_dialog(pos) i_pos = self.settings[pos][1] # Key Press Operations id_num = range(len(self.settings[pos][2])) key_in = None while key_in != 27: self.sub_selection_dialog_items(pos, i_pos, screen) key_in = screen.getch() if key_in == curses.KEY_DOWN: i_pos = list(id_num[1:] + id_num[:1])[i_pos] elif key_in == curses.KEY_UP: i_pos = list(id_num[-1:] + id_num[:-1])[i_pos] elif key_in in [10, 32]: if pos == 0 and i_pos != self.settings[pos][1]: test = self.settings[pos][2][i_pos]["test_url"] self.check_connection(test) self.settings[pos][1] = i_pos return def check_connection(self, url): """ Check connection status to the server currently selected by user and show a status box indicating current operation. :param url: The link of the server chose by user.This string could be a domain name or the IP address of a server. .. seealso:: :attr:`link` in :meth:`~util.common.CommonUtil.check_connection`. :type url: str :return: A flag indicating connection status is good or not. .. seealso:: :meth:`~util.common.CommonUtil.check_connection`. in :class:`~util.common.CommonUtil` class. :rtype: int """ self.messagebox("Checking Server Status...") conn = CommonUtil.check_connection(url) if conn: self.statusinfo[0][1] = "OK" self.statusinfo[0][2] = "GREEN" else: self.statusinfo[0][1] = "Error" self.statusinfo[0][2] = "RED" self.status() return conn def check_update(self): """ Check the metadata of the latest hosts data file from server and show a status box indicating current operation. :return: A dictionary containing the `Version`, `Release Date` of current hosts data file and the `Latest Version` of the data file on server. IF error occurs while checking update, the dictionary would be defined as:: {"version": "[Error]"} :rtype: dict """ self.messagebox("Checking Update...") srv_id = self.settings[0][1] url = self.settings[0][2][srv_id]["update"] + self.infofile try: socket.setdefaulttimeout(5) url_obj = urllib.urlopen(url) j_str = url_obj.read() url_obj.close() info = json.loads(j_str) except: info = {"version": "[Error]"} self.hostsinfo["Latest"] = info["version"] self.status() return info def new_version(self): """ Compare version of local data file to the version from the server. :return: A flag indicating whether the local data file is up-to-date or not. ====== ============================================ Return Data file status ====== ============================================ 1 The version of data file on server is newer. 0 The local data file is up-to-date. ====== ============================================ :rtype: int """ local_ver = self.hostsinfo["Version"] if local_ver == "N/A": return 1 server_ver = self._update["version"] local_ver = local_ver.split('.') server_ver = server_ver.split('.') for i, ver_num in enumerate(local_ver): if server_ver[i] > ver_num: return 1 return 0 def fetch_update(self): """ Retrieve the latest hosts data file from server and show a status box indicating current operation. """ self.messagebox("Downloading...") fetch_d = FetchUpdate(self) fetch_d.get_file() def set_config_bytes(self): """ Calculate the module configuration byte words by the selection from function list on the main dialog. """ ip_flag = self.settings[1][1] selection = {} localhost_word = { "Windows": 0x0001, "Linux": 0x0002, "Unix": 0x0002, "OS X": 0x0004}[self.platform] selection[0x02] = localhost_word ch_parts = [0x08, 0x20 if ip_flag else 0x10, 0x40] # Set customized module if exists if os.path.isfile(self.custom): ch_parts.insert(0, 0x04) slices = self.slices[ip_flag] for i, part in enumerate(ch_parts): part_cfg = self._funcs[ip_flag][slices[i]:slices[i + 1]] part_word = 0 for i, cfg in enumerate(part_cfg): part_word += cfg << i selection[part] = part_word self.make_cfg = selection def move_hosts(self): """ Move hosts file to the system path after making operations are finished. """ filepath = "hosts" try: shutil.copy2(filepath, self.hosts_path) except IOError: os.remove(filepath) return os.remove(filepath) self.messagebox("Operation completed!", 1)
19,197
Python
.py
446
31.255605
78
0.517446
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,285
curses_ui.py
huhamhire_huhamhire-hosts/tui/curses_ui.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # curses_ui.py: Draw TUI using curses. # # Copyleft (C) 2014 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import curses import locale import sys sys.path.append("..") from util import CommonUtil from __version__ import __version__, __release__ class CursesUI(object): """ CursesUI class contains methods to draw the Text-based User Interface (TUI) of Hosts Setup Utility. The methods to make TUI here are based on `curses <http://docs.python.org/2/library/curses.html>`_. :ivar str __title: Title of the TUI utility. :ivar str __copyleft: Copyleft information of the TUI utility. :ivar WindowObject _stdscr: A **WindowObject** which represents the whole screen. :ivar int _item_sup: Upper bound of item index from `function selection list`. :ivar int _item_inf: Lower bound of item index from `function selection list`. :ivar str _make_path: Temporary path to store the hosts file in while building. The default _make_path is `./hosts`. :ivar list _funcs: Two lists with the information of function list both for IPv4 and IPv6 environment. :ivar list choice: Two lists with the selection of functions both for IPv4 and IPv6 environment. :ivar list slices: Two lists with integers indicating the number of function items from different parts listed in the function list. .. seealso:: `_funcs`, `choice`, and `slices` in :class:`~gui.qdialog_d.QDialogDaemon` class. :ivar str sys_eol: The End-Of-Line marker. This maker could typically be one of `CR`, `LF`, or `CRLF`. .. seealso:: :attr:`sys_eol` in :class:`~gui.qdialog_d.QDialogDaemon` class. :ivar list colorpairs: Tuples of `(foreground-color, background-color)` used while drawing TUI. The default colorpairs is defined as:: colorpairs = [(curses.COLOR_WHITE, curses.COLOR_BLUE), (curses.COLOR_WHITE, curses.COLOR_RED), (curses.COLOR_YELLOW, curses.COLOR_BLUE), (curses.COLOR_BLUE, curses.COLOR_WHITE), (curses.COLOR_WHITE, curses.COLOR_WHITE), (curses.COLOR_BLACK, curses.COLOR_WHITE), (curses.COLOR_GREEN, curses.COLOR_WHITE), (curses.COLOR_WHITE, curses.COLOR_BLACK), (curses.COLOR_RED, curses.COLOR_WHITE), ] :ivar list settings: Two list containing the server selection and IP protocol version of current session. The settings should be like:: settings = [["Server", 0, []], ["IP Version", 0, ["IPv4", "IPv6"]]] :ivar list funckeys: Lists of hot keys with their function to be shown on TUI. The default :attr:`funckeys` is defined as:: funckeys = [["", "Select Item"], ["Tab", "Select Field"], ["Enter", "Set Item"], ["F5", "Check Update"], ["F6", "Fetch Update"], ["F10", "Apply Changes"], ["Esc", "Exit"]] :ivar list statusinfo: Two lists containing the connection and OS checking status of current session. The default :attr:`statusinfo` is defined as:: statusinfo = [["Connection", "N/A", "GREEN"], ["OS", "N/A", "GREEN"]] :ivar dict hostsinfo: Containing the `Version`, `Release Date` of current hosts data file and the `Latest Version` of the data file on server. The default hostsinfo is defined as:: hostsinfo = {"Version": "N/A", "Release": "N/A", "Latest": "N/A"} .. note:: IF the hosts data file does NOT exist in current working directory, OR the file metadata has NOT been checked, the values here would just be `N/A`. :ivar str filename: Filename of the hosts data file containing data to make hosts files from. Default by "`hostslist.data`". :ivar str infofile: Filename of the info file containing metadata of the hosts data file formatted in JSON. Default by "`hostslist.json`". .. seealso:: :attr:`filename` and :attr:`infofile` in :class:`~gui.hostsutil.HostsUtil` class. :ivar str custom: File name of User Customized Hosts File. Customized hosts would be able to select if this file exists. The default file name is ``custom.hosts``. .. seealso:: :ref:`User Customized Hosts<intro-customize>`. """ __title = "HOSTS SETUP UTILITY" version = "".join(['v', __version__, ' ', __release__]) __copyleft = "%s Copyleft 2011-2014, huhamhire-hosts Team" % version _stdscr = None _item_sup = 0 _item_inf = 0 _make_path = "./hosts" _funcs = [[], []] choice = [[], []] slices = [[], []] sys_eol = "" colorpairs = [(curses.COLOR_WHITE, curses.COLOR_BLUE), (curses.COLOR_WHITE, curses.COLOR_RED), (curses.COLOR_YELLOW, curses.COLOR_BLUE), (curses.COLOR_BLUE, curses.COLOR_WHITE), (curses.COLOR_WHITE, curses.COLOR_WHITE), (curses.COLOR_BLACK, curses.COLOR_WHITE), (curses.COLOR_GREEN, curses.COLOR_WHITE), (curses.COLOR_WHITE, curses.COLOR_BLACK), (curses.COLOR_RED, curses.COLOR_WHITE), ] settings = [["Server", 0, []], ["IP Version", 0, ["IPv4", "IPv6"]]] funckeys = [["", "Select Item"], ["Tab", "Select Field"], ["Enter", "Set Item"], ["F5", "Check Update"], ["F6", "Fetch Update"], ["F10", "Apply Changes"], ["Esc", "Exit"]] statusinfo = [["Connection", "N/A", "GREEN"], ["OS", "N/A", "GREEN"]] hostsinfo = {"Version": "N/A", "Release": "N/A", "Latest": "N/A"} filename = "hostslist.data" infofile = "hostsinfo.json" custom = "custom.hosts" def __init__(self): """ Initialize a new TUI window in terminal. """ locale.setlocale(locale.LC_ALL, '') self._stdscr = curses.initscr() curses.start_color() curses.noecho() curses.cbreak() curses.curs_set(0) # Set colors curses.use_default_colors() for i, color in enumerate(self.colorpairs): curses.init_pair(i + 1, *color) def __del__(self): """ Reset terminal before quit. """ curses.nocbreak() curses.echo() curses.endwin() def banner(self): """ Draw the banner in the TUI window. """ screen = self._stdscr.subwin(2, 80, 0, 0) screen.bkgd(' ', curses.color_pair(1)) # Set local variable title = curses.A_NORMAL title += curses.A_BOLD normal = curses.color_pair(4) # Print title screen.addstr(0, 0, self.__title.center(79), title) screen.addstr(1, 0, "Setup".center(10), normal) screen.refresh() def footer(self): """ Draw the footer in the TUI window. """ screen = self._stdscr.subwin(1, 80, 23, 0) screen.bkgd(' ', curses.color_pair(1)) # Set local variable normal = curses.A_NORMAL # Copyright info copyleft = self.__copyleft screen.addstr(0, 0, copyleft.center(79), normal) screen.refresh() def configure_settings_frame(self, pos=None): """ Draw `Configure Setting` frame with a index number (`pos`) of the item selected. :param pos: Index of selected item in `Configure Setting` frame. The default value of `pos` is `None`. :type pos: int or None .. note:: None of the items in `Configure Setting` frame would be selected if pos is `None`. """ self._stdscr.keypad(1) screen = self._stdscr.subwin(8, 25, 2, 0) screen.bkgd(' ', curses.color_pair(4)) # Set local variable normal = curses.A_NORMAL select = curses.color_pair(5) select += curses.A_BOLD for p, item in enumerate(self.settings): item_str = item[0].ljust(12) screen.addstr(3 + p, 2, item_str, select if p == pos else normal) if p: choice = "[%s]" % item[2][item[1]] else: choice = "[%s]" % item[2][item[1]]["label"] screen.addstr(3 + p, 15, ''.ljust(10), normal) screen.addstr(3 + p, 15, choice, select if p == pos else normal) screen.refresh() def status(self): """ Draw `Status` frame and `Hosts File` frame in the TUI window. """ screen = self._stdscr.subwin(11, 25, 10, 0) screen.bkgd(' ', curses.color_pair(4)) # Set local variable normal = curses.A_NORMAL green = curses.color_pair(7) red = curses.color_pair(9) # Status info for i, stat in enumerate(self.statusinfo): screen.addstr(2 + i, 2, stat[0], normal) stat_str = ''.join(['[', stat[1], ']']).ljust(9) screen.addstr(2 + i, 15, stat_str, green if stat[2] == "GREEN" else red) # Hosts file info i = 0 for key, info in self.hostsinfo.items(): screen.addstr(7 + i, 2, key, normal) screen.addstr(7 + i, 15, info, normal) i += 1 screen.refresh() def show_funclist(self, pos, item_sup, item_inf): """ Draw `function selection list` frame with a index number of the item selected and the range of items to be displayed. :param pos: Index of selected item in `function selection list`. :type pos: int or None :param item_sup: Upper bound of item index from `function selection list`. :type item_sup: int :param item_inf: Lower bound of item index from `function selection list`. :type item_inf: int """ # Set UI variable screen = self._stdscr.subwin(18, 26, 2, 26) screen.bkgd(' ', curses.color_pair(4)) normal = curses.A_NORMAL select = curses.color_pair(5) select += curses.A_BOLD list_height = 15 # Set local variable ip = self.settings[1][1] item_len = len(self.choice[ip]) # Function list items_show = self.choice[ip][item_sup:item_inf] items_selec = self._funcs[ip][item_sup:item_inf] for p, item in enumerate(items_show): sel_ch = '+' if items_selec[p] else ' ' item_str = ("[%s] %s" % (sel_ch, item[3])).ljust(23) item_pos = pos - item_sup if pos is not None else None highlight = select if p == item_pos else normal if item_len > list_height: if item_inf - item_sup == list_height - 2: screen.addstr(4 + p, 2, item_str, highlight) elif item_inf == item_len: screen.addstr(4 + p, 2, item_str, highlight) elif item_sup == 0: screen.addstr(3 + p, 2, item_str, highlight) else: screen.addstr(3 + p, 2, item_str, highlight) if item_len > list_height: if item_inf - item_sup == list_height - 2: screen.addstr(3, 2, " More ".center(23, '.'), normal) screen.addch(3, 15, curses.ACS_UARROW) screen.addstr(17, 2, " More ".center(23, '.'), normal) screen.addch(17, 15, curses.ACS_DARROW) elif item_inf == item_len: screen.addstr(3, 2, " More ".center(23, '.'), normal) screen.addch(3, 15, curses.ACS_UARROW) elif item_sup == 0: screen.addstr(17, 2, " More ".center(23, '.'), normal) screen.addch(17, 15, curses.ACS_DARROW) else: for line_i in range(list_height - item_len): screen.addstr(17 - line_i, 2, ' ' * 23, normal) if not items_show: screen.addstr(4, 2, "No data file!".center(23), normal) screen.refresh() self._item_sup, self._item_inf = item_sup, item_inf def info(self, pos, tab): """ Draw `Information` frame with a index number (`pos`) of the item selected from the frame specified by `tab`. :param pos: Index of selected item in a specified frame. :type pos: int :param tab: Index of the frame to select items from. :type tab: int .. warning:: Both of `pos` and `tab` in this method could not be set to `None`. """ screen = self._stdscr.subwin(18, 24, 2, 52) screen.bkgd(' ', curses.color_pair(4)) normal = curses.A_NORMAL if tab: ip = self.settings[1][1] info_str = self.choice[ip][pos][3] else: info_str = self.settings[pos][0] # Clear Expired Infomotion for i in range(6): screen.addstr(1 + i, 2, ''.ljust(22), normal) screen.addstr(1, 2, info_str, normal) # Key Info Offset k_info_y = 10 k_info_x_key = 2 k_info_x_text = 10 # Arrow Keys screen.addch(k_info_y, k_info_x_key, curses.ACS_UARROW, normal) screen.addch(k_info_y, k_info_x_key + 1, curses.ACS_DARROW, normal) # Show Key Info for i, keyinfo in enumerate(self.funckeys): screen.addstr(k_info_y + i, k_info_x_key, keyinfo[0], normal) screen.addstr(k_info_y + i, k_info_x_text, keyinfo[1], normal) screen.refresh() def process_bar(self, done, block, total, mode=1): """ Draw `Process Bar` at the bottom which is used to indicate progress of downloading operation. .. note:: This method is a callback function responses to :meth:`urllib.urlretrieve` method while fetching hosts data file. :param done: Block count of packaged retrieved. :type done: int :param block: Block size of the data pack retrieved. :type block: int :param total: Total size of the hosts data file. :type total: int :param mode: A flag indicating the status of `Process Bar`. The default value of `mode` is `1`. ==== ==================================== mode `Process Bar` status ==== ==================================== 1 Downloading operation is processing. 0 Not downloading. ==== ==================================== :type mode: int """ screen = self._stdscr.subwin(2, 80, 20, 0) screen.bkgd(' ', curses.color_pair(4)) normal = curses.A_NORMAL line_width = 76 prog_len = line_width - 20 # Progress Bar if mode: done *= block prog = 1.0 * prog_len * done / total progress = ''.join(['=' * int(prog), '-' * int(2 * prog % 2)]) progress = progress.ljust(prog_len) total = CommonUtil.convert_size(total).ljust(7) done = CommonUtil.convert_size(done).rjust(7) else: progress = ' ' * prog_len done = total = 'N/A'.center(7) # Show Progress prog_bar = "[%s] %s | %s" % (progress, done, total) screen.addstr(1, 2, prog_bar, normal) screen.refresh() def sub_selection_dialog(self, pos): """ Draw a `Selection Dialog` on screen used to make configurations. :param pos: Index of selected item in `Configure Setting` frame. :type pos: int .. warning:: The value of `pos` MUST NOT be `None`. :return: A **WindowObject** which represents the selection dialog. :rtype: WindowObject """ i_len = len(self.settings[pos][2]) # Draw Shadow shadow = curses.newwin(i_len + 2, 18, 13 - i_len / 2, 31) shadow.bkgd(' ', curses.color_pair(8)) shadow.refresh() # Draw Subwindow screen = curses.newwin(i_len + 2, 18, 12 - i_len / 2, 30) screen.box() screen.bkgd(' ', curses.color_pair(1)) screen.keypad(1) # Set local variable normal = curses.A_NORMAL # Title of Subwindow screen.addstr(0, 3, self.settings[pos][0].center(12), normal) return screen def sub_selection_dialog_items(self, pos, i_pos, screen): """ Draw items in `Selection Dialog`. :param pos: Index of selected item in `Configure Setting` frame. :type pos: int :param i_pos: Index of selected item in `Selection Dialog`. :type i_pos: int :param screen: A **WindowObject** which represents the selection dialog. :type screen: WindowObject """ # Set local variable normal = curses.A_NORMAL select = normal + curses.A_BOLD for p, item in enumerate(self.settings[pos][2]): item_str = item if pos else item["tag"] screen.addstr(1 + p, 2, item_str, select if p == i_pos else normal) screen.refresh() def setup_menu(self): """ Draw the main frame of `Setup` tab in the TUI window. """ screen = self._stdscr.subwin(21, 80, 2, 0) screen.box() screen.bkgd(' ', curses.color_pair(4)) # Configuration Section screen.addch(0, 26, curses.ACS_BSSS) screen.vline(1, 26, curses.ACS_VLINE, 17) # Status Section screen.addch(7, 0, curses.ACS_SSSB) screen.addch(7, 26, curses.ACS_SBSS) screen.hline(7, 1, curses.ACS_HLINE, 25) # Select Functions Section screen.addch(0, 52, curses.ACS_BSSS) screen.vline(1, 52, curses.ACS_VLINE, 17) # Process Bar Section screen.addch(18, 0, curses.ACS_SSSB) screen.addch(18, 79, curses.ACS_SBSS) screen.hline(18, 1, curses.ACS_HLINE, 78) screen.addch(18, 26, curses.ACS_SSBS) screen.addch(18, 52, curses.ACS_SSBS) # Section Titles title = curses.color_pair(6) subtitles = [["Configure Settings", (1, 2)], ["Status", (8, 2)], ["Hosts File", (13, 2)], ["Select Functions", (1, 28)]] for s_title in subtitles: cord = s_title[1] screen.addstr(cord[0], cord[1], s_title[0], title) screen.hline(cord[0] + 1, cord[1], curses.ACS_HLINE, 23) screen.refresh() @staticmethod def messagebox(msg, mode=0): """ Draw a `Message Box` with :attr:`msg` in a specified type defined by :attr:`mode`. .. note:: This is a `static` method. :param msg: The information to be displayed in message box. :type msg: str :param mode: A flag indicating the type of message box to be displayed. The default value of `mode` is `0`. ==== =========================================================== mode Message Box Type ==== =========================================================== 0 A simple message box showing a message without any buttons. 1 A message box with an `OK` button for user to confirm. 2 A message box with `OK` and `Cancel` buttons for user to choose. ==== =========================================================== :type mode: int :return: A flag indicating the choice made by user. ====== ===================================================== Return Condition ====== ===================================================== 0 #. No button is pressed while :attr:`mode` is `0`. #. `OK` button pressed while :attr:`mode` is `1`. #. `Cancel` button pressed while :attr:`mode` is `2`. 1 `OK` button pressed while :attr:`mode` is `2`. ====== ===================================================== :rtype: int """ pos_x = 24 if mode == 0 else 20 pos_y = 10 width = 30 if mode == 0 else 40 height = 2 messages = CommonUtil.cut_message(msg, width - 4) height += len(messages) if mode: height += 2 # Draw Shadow shadow = curses.newwin(height, width, pos_y + 1, pos_x + 1) shadow.bkgd(' ', curses.color_pair(8)) shadow.refresh() # Draw Subwindow screen = curses.newwin(height, width, pos_y, pos_x) screen.box() screen.bkgd(' ', curses.color_pair(2)) screen.keypad(1) # Set local variable normal = curses.A_NORMAL select = curses.A_REVERSE # Insert messages for i in range(len(messages)): screen.addstr(1 + i, 2, messages[i].center(width - 4), normal) if mode == 0: screen.refresh() else: # Draw subwindow frame line_height = 1 + len(messages) screen.hline(line_height, 1, curses.ACS_HLINE, width - 2) screen.addch(line_height, 0, curses.ACS_SSSB) screen.addch(line_height, width - 1, curses.ACS_SBSS) tab = 0 key_in = None while key_in != 27: if mode == 1: choices = ["OK"] elif mode == 2: choices = ["OK", "Cancel"] else: return 0 for i, item in enumerate(choices): item_str = ''.join(['[', item, ']']) tab_pos_x = 6 + 20 * i if mode == 2 else 18 screen.addstr(line_height + 1, tab_pos_x, item_str, select if i == tab else normal) screen.refresh() key_in = screen.getch() if mode == 2: # OK or Cancel if key_in in [9, curses.KEY_LEFT, curses.KEY_RIGHT]: tab = [1, 0][tab] if key_in in [ord('a'), ord('c')]: key_in -= (ord('a') - ord('A')) if key_in in [ord('C'), ord('O')]: return [ord('C'), ord('O')].index(key_in) if key_in in [10, 32]: return not tab return 0
23,013
Python
.py
520
33.503846
78
0.53569
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,286
__init__.py
huhamhire_huhamhire-hosts/tui/__init__.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # __init__.py: Declare modules to be called in tui module. # # Copyleft (C) 2014 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== from hostsutil import HostsUtil __all__ = ["HostsUtil"]
562
Python
.py
13
42.076923
71
0.533821
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,287
hostsutil.py
huhamhire_huhamhire-hosts/tui/hostsutil.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # hostsutil.py: Start a TUI session of `Hosts Setup Utility`. # # Copyleft (C) 2014 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import os from zipfile import BadZipfile from curses_d import CursesDaemon import sys sys.path.append("..") from util import CommonUtil, RetrieveData class HostsUtil(CursesDaemon): """ HostsUtil class in :mod:`tui` module is the main entrance to the Text-based User Interface (TUI) mode of `Hosts Setup Utility`. This class contains methods to start a TUI session of `Hosts Setup Utility`. .. note:: This class is subclass of :class:`~tui.curses_d.CursesDaemon` class. .. inheritance-diagram:: tui.hostsutil.HostsUtil :parts: 2 Typical usage to start a TUI session:: import tui util = tui.HostsUtil() util.start() :ivar str platform: Platform of current operating system. The value could be `Windows`, `Linux`, `Unix`, `OS X`, and of course `Unknown`. :ivar str hostname: The hostname of current operating system. .. note:: This attribute would only be used on linux. :ivar str hosts_path: The absolute path to the hosts file on current operating system. .. seealso:: :attr:`platform`, :attr:`hostname`, :attr:`hosts_path` in :class:`~tui.curses_d.CursesDaemon` class. :ivar str sys_eol: The End-Of-Line marker. This maker could typically be one of `CR`, `LF`, or `CRLF`. .. seealso:: :attr:`sys_eol` in :class:`~tui.curses_ui.CursesUI` class. """ platform = "" hostname = "" hosts_path = "" sys_eol = "" def __init__(self): """ Initialize a new TUI session. * Load server list from a configuration file under working directory. * Try to load the hosts data file under working directory if it exists. .. note:: IF hosts data file does not exists correctly in current working directory, a warning message box would popup. And operations to change the hosts file on current system could be done only until a new data file has been downloaded. .. seealso:: :meth:`~tui.curses_d.CursesDaemon.session_daemon` method in :class:`~tui.curses_d.CursesDaemon`. .. seealso:: :meth:`~gui.hostsutil.HostsUtil.init_main` in :class:`~gui.hostsutil.HostsUtil` class. """ super(HostsUtil, self).__init__() # Set mirrors self.settings[0][2] = CommonUtil.set_network("network.conf") # Read data file and set function list try: self.set_platform() RetrieveData.unpack() RetrieveData.connect_db() self.set_info() self.set_func_list() except IOError: self.messagebox("No data file found! Press F6 to get data file " "first.", 1) except BadZipfile: self.messagebox("Incorrect Data file! Press F6 to get a new data " "file first.", 1) def __del__(self): """ Reset the terminal and clear up the temporary data file while TUI session is finished. """ super(HostsUtil, self).__del__() try: RetrieveData.clear() except: pass def start(self): """ Start the TUI session. .. note:: This method is the trigger to start a TUI session of `Hosts Setup Utility`. """ while True: # Reload if self.session_daemon(): self.__del__() self.__init__() else: break def set_platform(self): """ Set the information about current operating system. """ system, hostname, path, encode, flag = CommonUtil.check_platform() color = "GREEN" if flag else "RED" self.platform = system self.statusinfo[1][1] = system self.hostname = hostname self.hosts_path = path self.statusinfo[1][2] = color if encode == "win_ansi": self.sys_eol = "\r\n" else: self.sys_eol = "\n" def set_func_list(self): """ Set the function selection list in TUI session. """ for ip in range(2): choice, defaults, slices = RetrieveData.get_choice(ip) if os.path.isfile(self.custom): choice.insert(0, [4, 1, 0, "customize"]) defaults[0x04] = [1] for i in range(len(slices)): slices[i] += 1 slices.insert(0, 0) self.choice[ip] = choice self.slices[ip] = slices funcs = [] for func in choice: if func[1] in defaults[func[0]]: funcs.append(1) else: funcs.append(0) self._funcs[ip] = funcs def set_info(self): """ Set the information of the current local data file. """ info = RetrieveData.get_info() build = info["Buildtime"] self.hostsinfo["Version"] = info["Version"] self.hostsinfo["Release"] = CommonUtil.timestamp_to_date(build) if __name__ == "__main__": main = HostsUtil() main.start()
5,787
Python
.py
149
29.583893
78
0.566845
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,288
__doc__.py
huhamhire_huhamhire-hosts/util/__doc__.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # __doc__.py : Document in reST format of util module. # # Copyleft (C) 2014 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== """ Shared Utilities ================ The module described in this chapter provides shared utilities CommonUtil ---------- .. autoclass:: util.common.CommonUtil :members: MakeHosts --------- .. autoclass:: util.makehosts.MakeHosts :members: .. automethod:: util.makehosts.MakeHosts.__init__ RetrieveData ------------ .. autoclass:: util.retrievedata.RetrieveData :members: """
901
Python
.py
29
29.241379
71
0.581019
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,289
makehosts.py
huhamhire_huhamhire-hosts/util/makehosts.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # makehosts.py: Make a hosts file. # # Copyleft (C) 2014 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import os import time from retrievedata import RetrieveData class MakeHosts(object): """ MakeHosts class contains methods to make a hosts file with host entries from a single data file. :ivar str make_mode: Operation mode for making hosts file. The valid value could be one of `system`, `ansi`, and `utf-8`. .. seealso:: :attr:`make_mode` in :class:`~gui.qdialog_d.QDialogDaemon` class. :ivar str custom: File name of User Customized Hosts file. .. seealso:: :ref:`User Customized Hosts<intro-customize>`. :ivar str hostname: File Name of hosts file. :ivar file hosts_file: The hosts file to write hosts to. :ivar int mod_num: Total number of modules written to hosts file. :ivar int count: Number of the module being processed currently in the operation sequence. :ivar dict make_cfg: Configuration to make a new hosts file. :ivar str eol: End-of-Line used by the hosts file created. :ivar time make_time: Timestamp of making hosts file. .. seealso:: :class:`gui._make.QSubMakeHosts` class and :class:`tui.curses_d.CursesDaemon` class. """ make_mode = "" custom = "" hostname = "" hosts_file = None make_cfg = {} mod_num = 0 count = 0 eol = "" make_time = None def __init__(self, parent): """ Retrieve configuration from the main dialog to make a new hosts file. :param parent: An instance of :class:`~tui.curses_d.CursesDaemon` class to retrieve configuration with. :type parent: :class:`~tui.curses_d.CursesDaemon` .. warning:: :attr:`parent` MUST NOT be set as `None`. """ self.count = 0 self.make_cfg = parent.make_cfg self.hostname = parent.hostname self.custom = parent.custom make_path = parent.make_path self.make_mode = parent.make_mode if self.make_mode == "system": self.eol = parent.sys_eol self.hosts_file = open("hosts", "wb") elif self.make_mode == "ansi": self.eol = "\r\n" self.hosts_file = open(unicode(make_path), "wb") elif self.make_mode == "utf-8": self.eol = "\n" self.hosts_file = open(unicode(make_path), "wb") def make(self): """ Start operations to retrieve data from the data file and make the new hosts file for the current operating system. """ RetrieveData.connect_db() self.make_time = time.time() self.write_head() self.write_info() self.get_hosts(self.make_cfg) self.hosts_file.close() RetrieveData.disconnect_db() def get_hosts(self, make_cfg): """ Make the new hosts file by the configuration defined by `make_cfg` from function list on the main dialog. :param make_cfg: Module settings in byte word format. :type make_cfg: dict .. seealso:: :attr:`make_cfg` in :class:`~tui.curses_d.CursesDaemon` class. """ for part_id in sorted(make_cfg.keys()): mod_cfg = make_cfg[part_id] if not RetrieveData.chk_mutex(part_id, mod_cfg): return mods = RetrieveData.get_ids(mod_cfg) for mod_id in mods: self.mod_num += 1 hosts, mod_name = RetrieveData.get_host(part_id, mod_id) if part_id == 0x02: self.write_localhost_mod(hosts) elif part_id == 0x04: self.write_customized() else: self.write_common_mod(hosts, mod_name) def write_head(self): """ Write the head part into the new hosts file. """ for head_str in RetrieveData.get_head(): self.hosts_file.write("%s%s" % (head_str[0], self.eol)) def write_info(self): """ Write the information part into the new hosts file. """ info = RetrieveData.get_info() info_lines = [ "#", "# %s: %s" % ("Version", info["Version"]), "# %s: %s" % ("BuildTime", info["Buildtime"]), "# %s: %s" % ("ApplyTime", int(self.make_time)), "#" ] for line in info_lines: self.hosts_file.write("%s%s" % (line, self.eol)) def write_common_mod(self, hosts, mod_name): """ Write hosts entries :attr:`hosts` from a module named `hosts` in the hosts data file.. :param hosts: Hosts entries from a part in the data file. :type hosts: list :param mod_name: Name of a module from the data file. :type mod_name: str """ self.hosts_file.write( "%s# Section Start: %s%s" % (self.eol, mod_name, self.eol)) for host in hosts: ip = host[0] if len(ip) < 16: ip = ip.ljust(16) self.hosts_file.write("%s %s%s" % (ip, host[1], self.eol)) self.count += 1 self.hosts_file.write("# Section End: %s%s" % (mod_name, self.eol)) def write_customized(self): """ Write user customized hosts list into the hosts file if the customized hosts file exists. """ if os.path.isfile(self.custom): custom_file = open(unicode(self.custom), "r") lines = custom_file.readlines() self.hosts_file.write( "%s# Section Start: Customized%s" % (self.eol, self.eol)) for line in lines: line = line.strip("\n") entry = line.split(" ", 1) if line.startswith("#"): self.hosts_file.write(line + self.eol) elif len(entry) > 1: ip = entry[0] if len(ip) < 16: ip = entry[0].ljust(16) self.hosts_file.write( "%s %s%s" % (ip, entry[1], self.eol) ) else: pass self.hosts_file.write("# Section End: Customized%s" % self.eol) def write_localhost_mod(self, hosts): """ Write localhost entries :attr:`hosts` into the hosts file. :param hosts: Hosts entries from a part in the data file. :type hosts: list """ self.hosts_file.write( "%s# Section Start: Localhost%s" % (self.eol, self.eol)) for host in hosts: if "#Replace" in host[1]: host = (host[0], self.hostname) ip = host[0] if len(ip) < 16: ip = ip.ljust(16) self.hosts_file.write("%s %s%s" % (ip, host[1], self.eol)) self.count += 1 self.hosts_file.write("# Section End: Localhost%s" % self.eol)
7,404
Python
.py
183
30.497268
78
0.547728
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,290
__init__.py
huhamhire_huhamhire-hosts/util/__init__.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # __init__.py: Declare modules to be called in util module. # # Copyleft (C) 2014 - huhamhire <me@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # ===================================================================== from common import CommonUtil from makehosts import MakeHosts from retrievedata import RetrieveData __all__ = ["CommonUtil", "MakeHosts", "RetrieveData"]
660
Python
.py
15
42.933333
71
0.582298
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,291
retrievedata.py
huhamhire_huhamhire-hosts/util/retrievedata.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # retrievedata.py : Retrieve data from the hosts data file. # # Copyleft (C) 2014 - huhamhire hosts team <hosts@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # # This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import os import sqlite3 import zipfile DATAFILE = "./hostslist.data" DATABASE = "./hostslist.s3db" class RetrieveData(object): """ RetrieveData class contains a set of tools to retrieve information from the hosts data file. .. note:: All methods from this class are declared as `classmethod`. :ivar sqlite3.connect conn: An instance of :class:`sqlite3.connect` object to set up connection to a SQLite database. :ivar sqlite3.connect.cursor _cur: An instance of :class:`sqlite3.connect.cursor` object to process SQL queries in the database. :ivar str _db: Filename of a SQLite database file. """ conn = None _cur = None _database = None @classmethod def db_exists(cls, database=DATABASE): """ Check whether the :attr:`database` file exists or not. .. note:: This is a `classmethod`. :param database: Path to a SQLite database file. `./hostslist.s3db` by default. :type database: str :return: A flag indicating whether the database file exists or not. :rtype: bool """ return os.path.isfile(database) @classmethod def connect_db(cls, database=DATABASE): """ Set up connection with a SQLite :attr:`database`. .. note:: This is a `classmethod`. :param database: Path to a SQLite database file. `./hostslist.s3db` by default. :type database: str """ cls.conn = sqlite3.connect(database) cls._cur = cls.conn.cursor() cls._database = database @classmethod def disconnect_db(cls): """ Close the connection with a SQLite database. .. note:: This is a `classmethod`. """ cls.conn.close() @classmethod def get_info(cls): """ Retrieve the metadata of current data file. .. note:: This is a `classmethod`. :return: Metadata of current data file. The metadata here is a dictionary while the `Keys` are made of `Section Name` and `Values` are made of `Information` defined in the hosts data file. :rtype: dict """ cls._cur.execute("SELECT sect, info FROM info;") info = dict(cls._cur.fetchall()) return info @classmethod def get_head(cls): """ Retrieve the head information from hosts data file. .. note:: This is a `classmethod`. :return: Lines of hosts head information. :rtype: list """ cls._cur.execute("SELECT str FROM hosts_head ORDER BY ln;") head = cls._cur.fetchall() return head @classmethod def get_ids(cls, id_cfg): """ Calculate the id numbers covered by config word :attr:`id_cfg`. .. note:: This is a `classmethod`. :param id_cfg: A hexadecimal config word of id selections. :type id_cfg: int :return: ID numbers covered by config word. :rtype: list """ cfg = bin(id_cfg)[:1:-1] ids = [] for i, id_en in enumerate(cfg): if int(id_en): ids.append(0b1 << i) return ids @classmethod def get_host(cls, part_id, mod_id): """ Retrieve the hosts module specified by :attr:`mod_id` from a part specified by :attr:`part_id` in the data file. .. note:: This is a `classmethod`. :param part_id: ID number of a specified part from the hosts data file. .. note:: ID number is usually an 8-bit control byte. :type part_id: int :param mod_id: ID number of a specified module from a specified part. .. note:: ID number is usually an 8-bit control byte. :type mod_id: int .. seealso:: :attr:`make_cfg` in :class:`~tui.curses_d.CursesDaemon` class. :return: hosts, mod_name * hosts(`list`): Hosts entries from a specified module. * mod_name(`str`): Name of a specified module. :rtype: list, str """ if part_id == 0x04: return None, "customize" cls._cur.execute(""" SELECT part_name FROM parts WHERE part_id=:part_id; """, (part_id, )) part_name = cls._cur.fetchone()[0] cls._cur.execute(""" SELECT ip, host FROM %s WHERE cate=%s; """ % (part_name, mod_id)) hosts = cls._cur.fetchall() cls._cur.execute(""" SELECT mod_name FROM modules WHERE part_id=:part_id AND mod_id=:mod_id; """, (part_id, mod_id)) mod_name = cls._cur.fetchone()[0] return hosts, mod_name @classmethod def get_choice(cls, flag_v6=False): """ Retrieve module selection items from the hosts data file with default selection for users. .. note:: This is a `classmethod`. :param flag_v6: A flag indicating whether to receive IPv6 hosts entries or the IPv4 ones. Default by `False`. =============== ======= :attr:`flag_v6` hosts =============== ======= True IPv6 False IPv4 =============== ======= :type flag_v6: bool :return: modules, defaults, slices * modules(`list`): Information of modules for users to select. * defaults(`dict`): Default selection config for selected parts. * slices(`list`): Numbers of modules in each part. :rtype: list, dict, list """ ch_parts = (0x08, 0x20 if flag_v6 else 0x10, 0x40) cls._cur.execute(""" SELECT * FROM modules WHERE part_id IN (:id_shared, :id_ipv, :id_adblock); """, ch_parts) modules = cls._cur.fetchall() cls._cur.execute(""" SELECT part_id, part_default FROM parts WHERE part_id IN (:id_shared, :id_ipv, :id_adblock); """, ch_parts) default_cfg = cls._cur.fetchall() defaults = {} for default in default_cfg: defaults[default[0]] = cls.get_ids(default[1]) slices = [0] for ch_part in ch_parts: cls._cur.execute(""" SELECT COUNT(mod_id) FROM modules WHERE part_id=:ch_part; """, (ch_part, )) slices.append(cls._cur.fetchone()[0]) for s in range(1, len(slices)): slices[s] += slices[s - 1] return modules, defaults, slices @classmethod def chk_mutex(cls, part_id, mod_cfg): """ Check if there is conflict in user selections :attr:`mod_cfg` from a part specified by :attr:`part_id` in the data file. .. note:: A conflict may happen while one module selected is declared in `mutex` word of ano module selected at the same time. .. note:: This is a `classmethod`. :param part_id: ID number of a specified part from the hosts data file. .. note:: ID number is usually an 8-bit control byte. .. seealso:: :meth:`~util.retrievedata.get_host`. :type part_id: int :param mod_cfg: A 16-bit config word indicating module selections of a specified part. .. note:: If modules in specified part whose IDs are `0x0002` and `0x0010`, the value here should be `0x0002 + 0x0010 = 0x0012`, which is `0b0000000000000010 + 0b0000000000010000 = 0b0000000000010010` in binary. :type: int .. seealso:: :attr:`make_cfg` in :class:`~tui.curses_d.CursesDaemon` class. :return: A flag indicating whether there is a conflict or not. ====== ============ Return Status ====== ============ True Conflict False No conflicts ====== ============ :rtype: bool """ if part_id == 0x04: return True cls._cur.execute(""" SELECT mod_id, mutex FROM modules WHERE part_id=:part_id; """, (part_id, )) mutex_tuple = dict(cls._cur.fetchall()) mutex_info = [] mod_info = cls.get_ids(mod_cfg) for mod_id in mod_info: mutex_info.extend(cls.get_ids(mutex_tuple[mod_id])) mutex_info = set(mutex_info) for mod_id in mod_info: if mod_id in mutex_info: return False return True @classmethod def unpack(cls, datafile=DATAFILE, database=DATABASE): """ Unzip the archived :attr:`datafile` to a SQLite database file :attr:`database`. .. note:: This is a `classmethod`. :param datafile: Path to the zipped data file. `./hostslist.data` by default. :type datafile: str :param database: Path to a SQLite database file. `./hostslist.s3db` by default. :type database: str """ datafile = zipfile.ZipFile(datafile, "r") path, filename = os.path.split(database) datafile.extract(filename, path) @classmethod def clear(cls): """ Close connection to the database and delete the database file. .. note:: This is a `classmethod`. """ cls.conn.close() os.remove(cls._database)
10,221
Python
.py
262
29.740458
78
0.563207
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,292
common.py
huhamhire_huhamhire-hosts/util/common.py
#!/usr/bin/env python # -*- coding: utf-8 -*- # # common.py : Basic utilities used by Hosts Setup Utility. # # Copyleft (C) 2013 - huhamhire hosts team <hosts@huhamhire.com> # ===================================================================== # Licensed under the GNU General Public License, version 3. You should # have received a copy of the GNU General Public License along with # this program. If not, see <http://www.gnu.org/licenses/>. # # This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE. # ===================================================================== __author__ = "huhamhire <me@huhamhire.com>" import ConfigParser import math import os import sys import socket import time class CommonUtil(object): """ CommonUtil class contains a set of basic tools for Hosts Setup Utility to use. .. note:: All methods from this class are declared as `classmethod`. """ @classmethod def check_connection(cls, link): """ Check connect to a specified server by :attr:`link`. .. note:: This is a `classmethod`. :param link: The link to a specified server. This string could be a domain name or the IP address of a server. :type link: str :return: A flag indicating whether the connection status is good or not. ==== ====== flag Status ==== ====== 1 OK 0 Error ==== ====== :rtype: int """ try: timeout = 3 sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) sock.settimeout(timeout) sock.connect((link, 80)) sock.close() return 1 except: return 0 @classmethod def check_platform(cls): """ Check information about current operating system. .. note:: This is a `classmethod`. :return: system, hostname, path, encode, flag * system(`str`): Operating system of current session. * hostname(`str`): Hostname of current machine. * path(`str`): Path to hosts on current operating system. * encode(`str`): Default encoding of current OS. * flag(`int`): A flag indicating whether the current OS is supported or not. ==== =========== flag Status ==== =========== 1 supported 2 unsupported ==== =========== :rtype: str, str, str, str, int """ hostname = socket.gethostname() if os.name == "nt": system = "Windows" path = os.getenv("WINDIR") + "\\System32\\drivers\\etc\\hosts" encode = "win_ansi" elif os.name == "posix": path = "/etc/hosts" encode = "unix_utf8" if sys.platform == "darwin": system = "OS X" # Remove the ".local" suffix hostname = hostname[0:-6] else: system = ["Unix", "Linux"][sys.platform.startswith('linux')] else: return "Unknown", '', '', 0 return system, hostname, path, encode, 1 @classmethod def check_privileges(cls): """ Check whether the current session has privileges to change the hosts file of current operating system. .. note:: This is a `classmethod`. :return: username, flag * username(`str`): Username of the user running current session. * flag(`bool`): A flag indicating whether the current session has write privileges to the hosts file or not. :rtype: str, bool """ if os.name == 'nt': try: # Only windows users with admin privileges can read the # C:\windows\temp os.listdir(os.sep.join([ os.environ.get('SystemRoot', 'C:\windows'), 'temp'])) except: return os.environ['USERNAME'], False else: return os.environ['USERNAME'], True else: # Check wirte privileges to the hosts file for current user w_flag = os.access("/etc/hosts", os.W_OK) try: return os.environ['USERNAME'], w_flag except KeyError: return os.environ['USER'], w_flag @classmethod def set_network(cls, conf_file="network.conf"): """ Get configurations for mirrors to connect to. .. note:: This is a `classmethod`. :param conf_file: Path to a configuration file containing which contains the server list. :type conf_file: str :return: `tag`, `test url`, and `update url` of the servers listed in the configuration file. Definition of the dictionary returned: ======== =================================================== Key Value ======== =================================================== tag `Tag` string of a specified server. label Name of a specified server. test_url `URL` to test the connection to a server. update `URL` containing the directory to get latest hosts\ data file. ======== =================================================== :rtype: dict """ conf = ConfigParser.ConfigParser() conf.read(conf_file) mirrors = [] for sec in conf.sections(): mirror = {"tag": sec, "label": conf.get(sec, "label"), "test_url": conf.get(sec, "server"), "update": conf.get(sec, "update"), } mirrors.append(mirror) return mirrors @classmethod def timestamp_to_date(cls, timestamp): """ Transform unix :attr:`timestamp` to a data string in ISO format. .. note:: This is a `classmethod`. :param timestamp: A unix timestamp indicating a specified time. :type timestamp: number .. note:: The :attr:`timestamp` could be `int` or `float`. :return: Date in ISO format, which is `YY-mm-dd` in specific. :rtype: str """ l_time = time.localtime(float(timestamp)) iso_format = "%Y-%m-%d" date = time.strftime(iso_format, l_time) return date @classmethod def convert_size(cls, bufferbytes): """ Convert byte size :attr:`bufferbytes` of a file into a size string. .. note:: This is a `classmethod`. :param bufferbytes: The size of a file counted in bytes. :type bufferbytes: int :return: A readable size string. :rtype: str """ if bufferbytes == 0: return "0 B" l_unit = int(math.log(bufferbytes, 0x400)) units = ['B', 'KB', 'MB', 'GB', 'TB', 'PB'] formats = ['%.2f', '%.1f', '%d'] size = bufferbytes / math.pow(0x400, l_unit) l_num = int(math.log(size, 10)) if l_unit >= len(units): l_unit = len(units) - 1 if l_num >= len(formats): l_num = len(formats) - 1 return ''.join([formats[l_num], ' ', units[l_unit]]) % size @classmethod def cut_message(cls, msg, cut): """ Cut english message (:attr:`msg`) into lines with specified length (:attr:`cut`). .. note:: This is a `classmethod`. :param msg: The message to be cut. :type msg: str :param cut: The length for each line of the message. :type cut: int :return: Lines cut from the message. :rtype: list """ delimiter = [" ", "\n"] msgs = [] while len(msg) >= cut: if "\n" in msg[:cut-1]: [line, msg] = msg.split("\n", 1) else: if (msg[cut-1] not in delimiter) and \ (msg[cut] not in delimiter): cut_len = cut - 1 hyphen = " " if msg[cut-2] in delimiter else "-" else: cut_len = cut hyphen = " " line = msg[:cut_len] + hyphen msg = msg[cut_len:] msgs.append(line) msgs.append(msg) return msgs
8,627
Python
.py
221
28.294118
77
0.508302
huhamhire/huhamhire-hosts
1,500
289
54
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,293
Makefile.pythonscripts.am
freeipa_freeipa/Makefile.pythonscripts.am
# special handling of Python scripts with auto-generated shebang line $(PYTHON_SHEBANG):%: %.in Makefile $(AM_V_GEN)sed -e 's|^#!/usr/bin/python3.*|#!$(PYTHON) -I|g' $< > $@ $(AM_V_GEN)chmod +x $@ .PHONY: python_scripts_sub python_scripts_sub: $(PYTHON_SHEBANG)
265
Python
.py
6
42.666667
69
0.678295
freeipa/freeipa
975
339
31
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,294
Makefile.python.am
freeipa_freeipa/Makefile.python.am
pkgname = $(shell basename "$(abs_srcdir)") pkgpythondir = $(pythondir)/$(pkgname) if VERBOSE_MAKE VERBOSITY="--verbose" else VERBOSITY="--quiet" endif !VERBOSE_MAKE # hack to handle back-in-the-hierarchy depedency on ipasetup.py .PHONY: $(top_builddir)/ipasetup.py $(top_builddir)/ipasetup.py: (cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) ipasetup.py) all-local: $(top_builddir)/ipasetup.py cd $(srcdir); $(PYTHON) setup.py \ $(VERBOSITY) \ build \ --build-base "$(abs_builddir)/build" install-exec-local: $(top_builddir)/ipasetup.py if [ "x$(pkginstall)" != "xfalse" ]; then \ $(PYTHON) $(srcdir)/setup.py \ $(VERBOSITY) \ build \ --build-base "$(abs_builddir)/build" \ install \ --prefix "$(DESTDIR)$(prefix)" \ --single-version-externally-managed \ --record "$(DESTDIR)$(pkgpythondir)/install_files.txt" \ --optimize 1 \ $(PYTHON_INSTALL_EXTRA_OPTIONS); \ fi uninstall-local: if [ -f "$(DESTDIR)$(pkgpythondir)/install_files.txt" ]; then \ cat "$(DESTDIR)$(pkgpythondir)/install_files.txt" | xargs rm -rf ; \ fi rm -rf "$(DESTDIR)$(pkgpythondir)" clean-local: $(top_builddir)/ipasetup.py $(PYTHON) "$(srcdir)/setup.py" \ clean \ --all --build-base "$(abs_builddir)/build" rm -rf "$(srcdir)/build" "$(srcdir)/dist" "$(srcdir)/MANIFEST" find "$(srcdir)" \ -name "*.py[co]" -delete -o \ -name "__pycache__" -delete -o \ -name "*.egg-info" -exec rm -rf {} + # take list of all Python source files and copy them into distdir # SOURCES.txt does not contain directories so we need to create those dist-hook: $(top_builddir)/ipasetup.py $(PYTHON) "$(srcdir)/setup.py" egg_info PYTHON_SOURCES=$$(cat "$(srcdir)/$(pkgname).egg-info/SOURCES.txt") || exit $$?; \ for FILEN in $${PYTHON_SOURCES}; \ do \ if test -x "$(srcdir)/$${FILEN}"; then MODE=755; else MODE=644; fi; \ $(INSTALL) -D -m $${MODE} "$(srcdir)/$${FILEN}" "$(distdir)/$${FILEN}" || exit $$?; \ done WHEELDISTDIR = $(top_builddir)/dist/wheels .PHONY: bdist_wheel bdist_wheel: $(top_builddir)/ipasetup.py rm -rf $(WHEELDISTDIR)/$(pkgname)-*.whl $(PYTHON) "$(srcdir)/setup.py" \ build \ --build-base "$(abs_builddir)/build" \ bdist_wheel \ --dist-dir=$(WHEELDISTDIR)
2,322
Python
.py
63
32.936508
87
0.627277
freeipa/freeipa
975
339
31
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,295
pylint_plugins.py
freeipa_freeipa/pylint_plugins.py
# # Copyright (C) 2015 FreeIPA Contributors see COPYING for license # from __future__ import print_function import copy import os.path import sys import textwrap from astroid import MANAGER, register_module_extender from astroid.nodes import scoped_nodes from pylint.checkers import BaseChecker from pylint.checkers.utils import only_required_for_messages from astroid.builder import AstroidBuilder def register(linter): linter.register_checker(IPAChecker(linter)) def _warning_already_exists(cls, member): print( "WARNING: member '{member}' in '{cls}' already exists".format( cls="{}.{}".format(cls.root().name, cls.name), member=member), file=sys.stderr ) def fake_class(name_or_class_obj, members=()): if isinstance(name_or_class_obj, scoped_nodes.ClassDef): cl = name_or_class_obj else: cl = scoped_nodes.ClassDef( name=name_or_class_obj, lineno=None, col_offset=None, parent=None, end_lineno=None, end_col_offset=None) for m in members: if isinstance(m, str): if m in cl.locals: _warning_already_exists(cl, m) else: cl.locals[m] = [scoped_nodes.ClassDef( name=m, lineno=None, col_offset=None, parent=None, end_lineno=None, end_col_offset=None)] elif isinstance(m, dict): for key, val in m.items(): assert isinstance(key, str), "key must be string" if key in cl.locals: _warning_already_exists(cl, key) fake_class(cl.locals[key], val) else: cl.locals[key] = [fake_class(key, val)] else: # here can be used any astroid type if m.name in cl.locals: _warning_already_exists(cl, m.name) else: cl.locals[m.name] = [copy.copy(m)] return cl # 'class': ['generated', 'properties'] ipa_class_members = { # Python standard library & 3rd party classes 'socket._socketobject': ['sendall'], # IPA classes 'ipalib.base.NameSpace': [ 'add', 'mod', 'del', 'show', 'find' ], 'ipalib.cli.Collector': ['__options'], 'ipalib.config.Env': [ # somehow needed for pylint on Python 2 'debug', 'startup_traceback', 'server', 'validate_api', 'verbose', ], 'ipalib.errors.ACIError': [ 'info', ], 'ipalib.errors.ConversionError': [ 'error', ], 'ipalib.errors.DatabaseError': [ 'desc', ], 'ipalib.errors.NetworkError': [ 'error', ], 'ipalib.errors.NotFound': [ 'reason', ], 'ipalib.errors.PublicError': [ 'msg', 'strerror', 'kw', ], 'ipalib.errors.SingleMatchExpected': [ 'found', ], 'ipalib.errors.SkipPluginModule': [ 'reason', ], 'ipalib.errors.ValidationError': [ 'error', ], 'ipalib.errors.SchemaUpToDate': [ 'fingerprint', 'ttl', ], 'ipalib.messages.PublicMessage': [ 'msg', 'strerror', 'type', 'kw', ], 'ipalib.parameters.Param': [ 'cli_name', 'cli_short_name', 'label', 'default', 'doc', 'required', 'multivalue', 'primary_key', 'normalizer', 'default_from', 'autofill', 'query', 'attribute', 'include', 'exclude', 'flags', 'hint', 'alwaysask', 'sortorder', 'option_group', 'no_convert', 'deprecated', ], 'ipalib.parameters.Bool': [ 'truths', 'falsehoods'], 'ipalib.parameters.Data': [ 'minlength', 'maxlength', 'length', 'pattern', 'pattern_errmsg', ], 'ipalib.parameters.Str': ['noextrawhitespace'], 'ipalib.parameters.Password': ['confirm'], 'ipalib.parameters.File': ['stdin_if_missing'], 'ipalib.parameters.Enum': ['values'], 'ipalib.parameters.Number': [ 'minvalue', 'maxvalue', ], 'ipalib.parameters.Decimal': [ 'precision', 'exponential', 'numberclass', ], 'ipalib.parameters.DNSNameParam': [ 'only_absolute', 'only_relative', ], 'ipalib.parameters.Principal': [ 'require_service', ], 'ipalib.plugable.API': [ 'Advice', ], 'ipalib.util.ForwarderValidationError': [ 'msg', ], 'ipaserver.plugins.dns.DNSRecord': [ 'validatedns', 'normalizedns', ], } def fix_ipa_classes(cls): class_name_with_module = "{}.{}".format(cls.root().name, cls.name) if class_name_with_module in ipa_class_members: fake_class(cls, ipa_class_members[class_name_with_module]) MANAGER.register_transform(scoped_nodes.ClassDef, fix_ipa_classes) def ipaplatform_constants_transform(): return AstroidBuilder(MANAGER).string_build(textwrap.dedent(''' from ipaplatform.base.constants import constants, User, Group __all__ = ('constants', 'User', 'Group') ''')) def ipaplatform_paths_transform(): return AstroidBuilder(MANAGER).string_build(textwrap.dedent(''' from ipaplatform.base.paths import paths __all__ = ('paths',) ''')) def ipaplatform_services_transform(): return AstroidBuilder(MANAGER).string_build(textwrap.dedent(''' from ipaplatform.base.services import knownservices from ipaplatform.base.services import timedate_services from ipaplatform.base.services import service from ipaplatform.base.services import wellknownservices from ipaplatform.base.services import wellknownports __all__ = ('knownservices', 'timedate_services', 'service', 'wellknownservices', 'wellknownports') ''')) def ipaplatform_tasks_transform(): return AstroidBuilder(MANAGER).string_build(textwrap.dedent(''' from ipaplatform.base.tasks import tasks __all__ = ('tasks',) ''')) register_module_extender(MANAGER, 'ipaplatform.constants', ipaplatform_constants_transform) register_module_extender(MANAGER, 'ipaplatform.paths', ipaplatform_paths_transform) register_module_extender(MANAGER, 'ipaplatform.services', ipaplatform_services_transform) register_module_extender(MANAGER, 'ipaplatform.tasks', ipaplatform_tasks_transform) def ipalib_request_transform(): """ipalib.request.context attribute """ return AstroidBuilder(MANAGER).string_build(textwrap.dedent(''' from ipalib.request import context context._pylint_attr = Connection("_pylint", lambda: None) ''')) register_module_extender(MANAGER, 'ipalib.request', ipalib_request_transform) class IPAChecker(BaseChecker): name = 'ipa' msgs = { 'W9901': ( 'Forbidden import %s (can\'t import from %s in %s)', 'ipa-forbidden-import', 'Used when an forbidden import is detected.', ), } options = ( ( 'forbidden-imports', { 'default': '', 'type': 'csv', 'metavar': '<path>[:<module>[:<module>...]][,<path>...]', 'help': 'Modules which are forbidden to be imported in the ' 'given paths', }, ), ) priority = -1 def open(self): self._dir = os.path.abspath(os.path.dirname(__file__)) self._forbidden_imports = {self._dir: []} for forbidden_import in self.linter.config.forbidden_imports: forbidden_import = forbidden_import.split(':') path = os.path.join(self._dir, forbidden_import[0]) path = os.path.abspath(path) modules = forbidden_import[1:] self._forbidden_imports[path] = modules self._forbidden_imports_stack = [] def _get_forbidden_import_rule(self, node): path = node.path if path and isinstance(path, list): # In pylint 2.0, path is a list with one element. Namespace # packages may contain more than one element, but we can safely # ignore them, as they don't contain code. path = path[0] if path: path = os.path.abspath(path) while path.startswith(self._dir): if path in self._forbidden_imports: return path path = os.path.dirname(path) return self._dir def visit_module(self, node): self._forbidden_imports_stack.append( self._get_forbidden_import_rule(node)) def leave_module(self, node): self._forbidden_imports_stack.pop() def _check_forbidden_imports(self, node, names): path = self._forbidden_imports_stack[-1] relpath = os.path.relpath(path, self._dir) modules = self._forbidden_imports[path] for module in modules: module_prefix = module + '.' for name in names: if name == module or name.startswith(module_prefix): self.add_message('ipa-forbidden-import', args=(name, module, relpath), node=node) @only_required_for_messages('ipa-forbidden-import') def visit_import(self, node): names = [n[0] for n in node.names] self._check_forbidden_imports(node, names) @only_required_for_messages('ipa-forbidden-import') def visit_importfrom(self, node): names = ['{}.{}'.format(node.modname, n[0]) for n in node.names] self._check_forbidden_imports(node, names) # # Teach pylint how api object works # # ipalib uses some tricks to create api.env members and api objects. pylint # is not able to infer member names and types from code. The explict # assignments inside the string builder templates are good enough to show # pylint, how the api is created. Additional transformations are not # required. # AstroidBuilder(MANAGER).string_build(textwrap.dedent( """ from ipalib import api from ipalib import cli, plugable, rpc from ipalib.base import NameSpace from ipaclient.plugins import rpcclient try: from ipaserver.plugins import dogtag, ldap2, serverroles except ImportError: HAS_SERVER = False else: HAS_SERVER = True def wildcard(*args, **kwargs): return None # ipalib.api members api.Backend = plugable.APINameSpace(api, None) api.Command = plugable.APINameSpace(api, None) api.Method = plugable.APINameSpace(api, None) api.Object = plugable.APINameSpace(api, None) api.Updater = plugable.APINameSpace(api, None) # ipalib.api.Backend members api.Backend.cli = cli.cli(api) api.Backend.textui = cli.textui(api) api.Backend.jsonclient = rpc.jsonclient(api) api.Backend.rpcclient = rpcclient.rpcclient(api) api.Backend.xmlclient = rpc.xmlclient(api) if HAS_SERVER: api.Backend.kra = dogtag.kra(api) api.Backend.ldap2 = ldap2.ldap2(api) api.Backend.ra = dogtag.ra(api) api.Backend.ra_certprofile = dogtag.ra_certprofile(api) api.Backend.ra_lightweight_ca = dogtag.ra_lightweight_ca(api) api.Backend.serverroles = serverroles.serverroles(api) # ipalib.base.NameSpace NameSpace.find = wildcard """ )) AstroidBuilder(MANAGER).string_build(textwrap.dedent( """ from ipalib import api from ipapython.dn import DN api.env.api_version = '' api.env.bin = '' # object api.env.ca_agent_port = 0 api.env.ca_host = '' api.env.ca_install_port = None api.env.ca_port = 0 api.env.cache_dir = '' # object api.env.certmonger_wait_timeout = 0 api.env.conf = '' # object api.env.conf_default = '' # object api.env.confdir = '' # object api.env.container_accounts = DN() api.env.container_adtrusts = DN() api.env.container_applications = DN() api.env.container_automember = DN() api.env.container_automount = DN() api.env.container_ca = DN() api.env.container_ca_renewal = DN() api.env.container_subids = DN() api.env.container_caacl = DN() api.env.container_certmap = DN() api.env.container_certmaprules = DN() api.env.container_certprofile = DN() api.env.container_cifsdomains = DN() api.env.container_configs = DN() api.env.container_custodia = DN() api.env.container_deleteuser = DN() api.env.container_dna = DN() api.env.container_dna_posix_ids = DN() api.env.container_dns = DN() api.env.container_dnsservers = DN() api.env.container_passkey = DN() api.env.container_group = DN() api.env.container_hbac = DN() api.env.container_hbacservice = DN() api.env.container_hbacservicegroup = DN() api.env.container_host = DN() api.env.container_hostgroup = DN() api.env.container_idp = DN() api.env.container_locations = DN() api.env.container_masters = DN() api.env.container_netgroup = DN() api.env.container_otp = DN() api.env.container_permission = DN() api.env.container_policies = DN() api.env.container_policygroups = DN() api.env.container_policylinks = DN() api.env.container_privilege = DN() api.env.container_radiusproxy = DN() api.env.container_ranges = DN() api.env.container_realm_domains = DN() api.env.container_rolegroup = DN() api.env.container_roles = DN() api.env.container_s4u2proxy = DN() api.env.container_selinux = DN() api.env.container_service = DN() api.env.container_stageuser = DN() api.env.container_sudocmd = DN() api.env.container_sudocmdgroup = DN() api.env.container_sudorule = DN() api.env.container_sysaccounts = DN() api.env.container_topology = DN() api.env.container_trusts = DN() api.env.container_user = DN() api.env.container_vault = DN() api.env.container_views = DN() api.env.container_virtual = DN() api.env.context = '' # object api.env.debug = False api.env.delegate = False api.env.dogtag_version = 0 api.env.dot_ipa = '' # object api.env.enable_ra = False api.env.env_confdir = None api.env.fallback = True api.env.force_schema_check = False api.env.home = '' # object api.env.host = '' api.env.host_princ = '' api.env.http_timeout = 0 api.env.in_server = False # object api.env.in_tree = False # object api.env.interactive = True api.env.ipalib = '' # object api.env.kinit_lifetime = None api.env.log = '' # object api.env.logdir = '' # object api.env.mode = '' api.env.mount_ipa = '' api.env.nss_dir = '' # object api.env.plugins_on_demand = False # object api.env.prompt_all = False api.env.ra_plugin = '' api.env.recommended_max_agmts = 0 api.env.replication_wait_timeout = 0 api.env.rpc_protocol = '' api.env.server = '' api.env.script = '' # object api.env.site_packages = '' # object api.env.skip_version_check = False api.env.smb_princ = '' api.env.startup_timeout = 0 api.env.startup_traceback = False api.env.tls_ca_cert = '' # object api.env.tls_version_max = '' api.env.tls_version_min = '' api.env.validate_api = False api.env.verbose = 0 api.env.version = '' api.env.wait_for_dns = 0 api.env.webui_prod = True # defined in ipaclient/install/ipa_epn.py api.env.smtp_server = "" api.env.smtp_port = 0 api.env.smtp_user = None api.env.smtp_password = None api.env.smtp_client_cert = None api.env.smtp_client_key = None api.env.smtp_client_key_pass = None api.env.smtp_timeout = 0 api.env.smtp_security = "" api.env.smtp_admin = "" api.env.smtp_delay = None api.env.mail_from = None api.env.mail_from_name = None api.env.notify_ttls = "" api.env.msg_charset = "" api.env.msg_subtype = "" api.env.msg_subject = "" # defined in contrib/lite-server.py api.env.lite_pem = '' api.env.lite_profiler = '' api.env.lite_host = '' api.env.lite_port = 0 api.env.lite_tracemalloc = False """ )) # dnspython 2.x introduces enums and creates module level globals from them # pylint does not understand the trick AstroidBuilder(MANAGER).string_build(textwrap.dedent( """ import dns.flags import dns.rdataclass import dns.rdatatype dns.flags.AD = 0 dns.flags.CD = 0 dns.flags.DO = 0 dns.flags.RD = 0 dns.rdataclass.IN = 0 dns.rdatatype.A = 0 dns.rdatatype.AAAA = 0 dns.rdatatype.CNAME = 0 dns.rdatatype.DNSKEY = 0 dns.rdatatype.MX = 0 dns.rdatatype.NS = 0 dns.rdatatype.PTR = 0 dns.rdatatype.RRSIG = 0 dns.rdatatype.SOA = 0 dns.rdatatype.SRV = 0 dns.rdatatype.TXT = 0 dns.rdatatype.URI = 0 """ )) AstroidBuilder(MANAGER).string_build( textwrap.dedent( """\ from ipatests.test_integration.base import IntegrationTest from ipatests.pytest_ipa.integration.host import Host, WinHost from ipatests.pytest_ipa.integration.config import Config, Domain class PylintIPAHosts: def __getitem__(self, key): return Host() class PylintWinHosts: def __getitem__(self, key): return WinHost() class PylintADDomains: def __getitem__(self, key): return Domain() Host.config = Config() Host.domain = Domain() IntegrationTest.domain = Domain() IntegrationTest.master = Host() IntegrationTest.replicas = PylintIPAHosts() IntegrationTest.clients = PylintIPAHosts() IntegrationTest.ads = PylintWinHosts() IntegrationTest.ad_treedomains = PylintWinHosts() IntegrationTest.ad_subdomains = PylintWinHosts() IntegrationTest.ad_domains = PylintADDomains() """ ) )
18,000
Python
.py
531
27.016949
78
0.626128
freeipa/freeipa
975
339
31
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,296
ipasetup.py.in
freeipa_freeipa/ipasetup.py.in
# Copyright (C) 2016 Red Hat # see file 'COPYING' for use and warranty information # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. # import logging import os import sys from setuptools.command.build_py import build_py as setuptools_build_py class build_py(setuptools_build_py): """Exclude NAME.install subpackage from wheels """ def initialize_options(self): setuptools_build_py.initialize_options(self) self.skip_modules = () def finalize_options(self): setuptools_build_py.finalize_options(self) omit = os.environ.get('IPA_OMIT_INSTALL', '0') if omit == '1': distname = self.distribution.metadata.name self.skip_modules = ( # *.install.* subpackages '{}.install'.format(distname), # platform override module 'ipaplatform.override', ) logging.warning("bdist_wheel: Ignore package: %s", ', '.join(self.skip_modules)) def build_module(self, module, module_file, package): if isinstance(package, str): package = package.split('.') name = '.'.join(list(package) + [module]) if self.skip_modules and name.startswith(self.skip_modules): # remove file in case it has been copied to build/lib before outfile = self.get_module_outfile(self.build_lib, package, module) try: os.unlink(outfile) except OSError: pass return None else: return setuptools_build_py.build_module(self, module, module_file, package) import setuptools VERSION = '@VERSION@' SETUPTOOLS_VERSION = tuple(int(v) for v in setuptools.__version__.split(".")) PACKAGE_VERSION = { 'cryptography': 'cryptography >= 1.6', 'custodia': 'custodia >= 0.3.1', 'dnspython': 'dnspython >= 1.15', 'gssapi': 'gssapi >= 1.2.0', 'ipaclient': 'ipaclient == {}'.format(VERSION), 'ipalib': 'ipalib == {}'.format(VERSION), 'ipaplatform': 'ipaplatform == {}'.format(VERSION), 'ipapython': 'ipapython == {}'.format(VERSION), 'ipaserver': 'ipaserver == {}'.format(VERSION), 'jwcrypto': 'jwcrypto >= 0.4.2', 'kdcproxy': 'kdcproxy >= 0.3', 'ifaddr': 'ifaddr >= 0.1.7', 'python-ldap': 'python-ldap >= 3.0.0', 'python-yubico': 'python-yubico >= 1.2.3', 'qrcode': 'qrcode >= 5.0', } common_args = dict( version=VERSION, license="GPLv3", author="FreeIPA Developers", author_email="freeipa-devel@lists.fedorahosted.org", maintainer="FreeIPA Developers", maintainer_email="freeipa-devel@redhat.com", url="https://www.freeipa.org/", download_url="https://www.freeipa.org/page/Downloads", platforms=["Linux"], python_requires=">=3.6.0", classifiers=[ "Development Status :: 5 - Production/Stable", "Intended Audience :: System Administrators", ("License :: OSI Approved :: " "GNU General Public License v3 (GPLv3)"), "Programming Language :: C", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Programming Language :: Python :: Implementation :: CPython", "Operating System :: POSIX", "Operating System :: POSIX :: Linux", "Operating System :: Unix", "Topic :: Internet :: Name Service (DNS)", "Topic :: Security", ("Topic :: System :: Systems Administration :: " "Authentication/Directory :: LDAP"), ], ) local_path = os.path.dirname(os.path.abspath(sys.argv[0])) old_path = os.path.abspath(os.getcwd()) def ipasetup(name, doc, **kwargs): doclines = doc.split("\n") install_requires = list(kwargs.pop('install_requires', [])) for i, entry in enumerate(install_requires): install_requires[i] = PACKAGE_VERSION.get(entry, entry) setup_kwargs = common_args.copy() setup_kwargs.update( name=name, description=doclines[0], long_description="\n".join(doclines[:2]), install_requires=install_requires, **kwargs ) # exclude setup helpers from getting installed epd = setup_kwargs.setdefault('exclude_package_data', {}) epd.setdefault('', []).extend(['*/setup.py', '*/ipasetup.py']) # exclude NAME.install from wheels cmdclass = setup_kwargs.setdefault('cmdclass', {}) cmdclass['build_py'] = build_py # Env markers like ":python_version<'3'" are not supported by # setuptools < 18.0. if 'extras_require' in setup_kwargs and SETUPTOOLS_VERSION < (18, 0, 0): for k in list(setup_kwargs['extras_require']): if not k.startswith(':'): continue values = setup_kwargs['extras_require'].pop(k) req = setup_kwargs.setdefault('install_requires', []) if k == ":python_version<'3'": if sys.version_info.major == 2: req.extend(values) elif k == ":python_version>='3'": if sys.version_info.major >= 3: req.extend(values) else: raise ValueError(k, values) os.chdir(local_path) try: # BEFORE importing distutils, remove MANIFEST. distutils doesn't # properly update it when the contents of directories change. if os.path.isfile('MANIFEST'): os.unlink('MANIFEST') from setuptools import setup return setup(**setup_kwargs) finally: os.chdir(old_path)
6,233
Python
.py
151
33.529801
78
0.619456
freeipa/freeipa
975
339
31
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,297
conftest.py
freeipa_freeipa/ipatests/conftest.py
# # Copyright (C) 2016 FreeIPA Contributors see COPYING for license # from __future__ import print_function import os import pprint import shutil import sys import tempfile import pytest from ipalib import api from ipalib.cli import cli_plugins import ipatests.util try: import ipaplatform # pylint: disable=unused-import except ImportError: ipaplatform = None osinfo = None else: from ipaplatform.osinfo import osinfo HERE = os.path.dirname(os.path.abspath(__file__)) class PytestIPADeprecationWarning(pytest.PytestWarning, DeprecationWarning): """Warning class for features that will be removed in a future version.""" pytest_plugins = [ 'ipatests.pytest_ipa.additional_config', 'ipatests.pytest_ipa.deprecated_frameworks', 'ipatests.pytest_ipa.slicing', 'ipatests.pytest_ipa.beakerlib', 'ipatests.pytest_ipa.declarative', 'ipatests.pytest_ipa.nose_compat', 'ipatests.pytest_ipa.integration', 'pytester', ] MARKERS = [ 'tier0: basic unit tests and critical functionality', 'tier1: functional API tests', 'cs_acceptance: Acceptance test suite for Dogtag Certificate Server', 'ds_acceptance: Acceptance test suite for 389 Directory Server', 'skip_ipaclient_unittest: Skip in ipaclient unittest mode', 'needs_ipaapi: Test needs IPA API', ('skip_if_platform(platform, reason): Skip test on platform ' '(ID and ID_LIKE)'), ('skip_if_container(type, reason): Skip test on container ' '("any" or specific type)'), ] NO_RECURSE_DIRS = [ # build directories 'ipaclient/build', 'ipalib/build', 'ipaplatform/build', 'ipapython/build', 'ipaserver/build', 'ipatests/build', # install/share/wsgi.py 'install/share', # integration plugin imports from ipaplatform 'ipatests/pytest_ipa', 'ipatests/azure', ] INIVALUES = { 'python_classes': ['test_', 'Test'], 'python_files': ['test_*.py'], 'python_functions': ['test_*'], } def pytest_configure(config): # add pytest markers for marker in MARKERS: config.addinivalue_line('markers', marker) # do not recurse into build directories or install/share directory. for norecursedir in NO_RECURSE_DIRS: config.addinivalue_line('norecursedirs', norecursedir) # addinivalue_line() adds duplicated entries and does not remove existing. for name, values in INIVALUES.items(): current = config.getini(name) current[:] = values # set default JUnit prefix if config.option.junitprefix is None: config.option.junitprefix = 'ipa' # always run doc tests config.option.doctestmodules = True # apply global options ipatests.util.SKIP_IPAAPI = config.option.skip_ipaapi ipatests.util.IPACLIENT_UNITTESTS = config.option.ipaclient_unittests ipatests.util.PRETTY_PRINT = config.option.pretty_print def pytest_addoption(parser): group = parser.getgroup("IPA integration tests") group.addoption( '--ipaclient-unittests', help='Run ipaclient unit tests only (no RPC and ipaserver)', action='store_true' ) group.addoption( '--skip-ipaapi', help='Do not run tests that depends on IPA API', action='store_true', ) def pytest_cmdline_main(config): kwargs = dict( context=u'cli', in_server=False, fallback=False ) # FIXME: workaround for https://pagure.io/freeipa/issue/8317 kwargs.update(in_tree=True) if not os.path.isfile(os.path.expanduser('~/.ipa/default.conf')): # dummy domain/host for machines without ~/.ipa/default.conf kwargs.update(domain=u'ipa.test', server=u'master.ipa.test') api.bootstrap(**kwargs) for klass in cli_plugins: api.add_plugin(klass) # XXX workaround until https://fedorahosted.org/freeipa/ticket/6408 has # been resolved. if os.path.isfile(api.env.conf_default): api.finalize() if config.option.verbose: print('api.env: ') pprint.pprint({k: api.env[k] for k in api.env}) print("uname: {}".format(os.uname())) print("euid: {}, egid: {}".format(os.geteuid(), os.getegid())) print("working dir: {}".format(os.path.abspath(os.getcwd()))) print('sys.version: {}'.format(sys.version)) def pytest_runtest_setup(item): if isinstance(item, pytest.Function): if item.get_closest_marker('skip_ipaclient_unittest'): if item.config.option.ipaclient_unittests: pytest.skip("Skip in ipaclient unittest mode") if item.get_closest_marker('needs_ipaapi'): if item.config.option.skip_ipaapi: pytest.skip("Skip tests that needs an IPA API") if osinfo is not None: for mark in item.iter_markers(name="skip_if_platform"): platform = mark.kwargs.get("platform") if platform is None: platform = mark.args[0] reason = mark.kwargs["reason"] if platform in osinfo.platform_ids: pytest.skip(f"Skip test on platform {platform}: {reason}") for mark in item.iter_markers(name="skip_if_container"): container = mark.kwargs.get("container") if container is None: container = mark.args[0] reason = mark.kwargs["reason"] if osinfo.container is not None: if container in ('any', osinfo.container): pytest.skip( f"Skip test on '{container}' container type: {reason}") @pytest.fixture def tempdir(request): tempdir = tempfile.mkdtemp() def fin(): shutil.rmtree(tempdir) request.addfinalizer(fin) return tempdir
5,719
Python
.py
151
31.516556
79
0.67251
freeipa/freeipa
975
339
31
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,298
util.py
freeipa_freeipa/ipatests/util.py
# Authors: # Jason Gerard DeRose <jderose@redhat.com> # # Copyright (C) 2008 Red Hat # see file 'COPYING' for use and warranty information # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. """ Common utility functions and classes for unit tests. """ from __future__ import absolute_import import inspect import os from os import path import tempfile import shutil import re import uuid import pytest from contextlib import contextmanager from pprint import pformat import six import ipalib from ipalib import api from ipalib.kinit import kinit_keytab, kinit_password from ipalib.plugable import Plugin from ipalib.request import context from ipapython.dn import DN from ipapython.ipautil import run try: # not available with client-only wheel packages from ipaplatform.paths import paths except ImportError: paths = None try: # not available with optional python-ldap import ldap except ImportError: pass else: import ldap.sasl import ldap.modlist from ipapython.ipaldap import ldap_initialize if six.PY3: unicode = str # settings are configured by conftest IPACLIENT_UNITTESTS = None SKIP_IPAAPI = None PRETTY_PRINT = None def check_ipaclient_unittests(reason="Skip in ipaclient unittest mode"): """Call this in a package to skip the package in ipaclient-unittest mode """ if IPACLIENT_UNITTESTS: pytest.skip(reason, allow_module_level=True) def check_no_ipaapi(reason="Skip tests that needs an IPA API"): """Call this in a package to skip the package in no-ipaapi mode """ if SKIP_IPAAPI: pytest.skip(reason, allow_module_level=True) class TempDir: def __init__(self): self.__path = tempfile.mkdtemp(prefix='ipa.tests.') assert self.path == self.__path def __get_path(self): assert path.abspath(self.__path) == self.__path assert self.__path.startswith(path.join(tempfile.gettempdir(), 'ipa.tests.')) assert path.isdir(self.__path) and not path.islink(self.__path) return self.__path path = property(__get_path) def rmtree(self): if self.__path is not None: shutil.rmtree(self.path) self.__path = None def makedirs(self, *parts): d = self.join(*parts) if not path.exists(d): os.makedirs(d) assert path.isdir(d) and not path.islink(d) return d def touch(self, *parts): d = self.makedirs(*parts[:-1]) f = path.join(d, parts[-1]) assert not path.exists(f) open(f, 'w').close() assert path.isfile(f) and not path.islink(f) return f def write(self, content, *parts): d = self.makedirs(*parts[:-1]) f = path.join(d, parts[-1]) assert not path.exists(f) open(f, 'w').write(content) assert path.isfile(f) and not path.islink(f) return f def join(self, *parts): return path.join(self.path, *parts) def __del__(self): self.rmtree() def __enter__(self): return self def __exit__(self, exc_type, exc_val, exc_tb): self.rmtree() class TempHome(TempDir): def __init__(self): super(TempHome, self).__init__() os.environ['HOME'] = self.path class ExceptionNotRaised(Exception): """ Exception raised when an *expected* exception is *not* raised during a unit test. """ msg = 'expected %s' def __init__(self, expected): self.expected = expected def __str__(self): return self.msg % self.expected.__name__ def assert_equal(val1, val2, msg=''): """ Assert ``val1`` and ``val2`` are the same type and of equal value. """ assert type(val1) is type(val2), '%r != %r' % (val1, val2) assert val1 == val2, '%r != %r %r' % (val1, val2, msg) def assert_not_equal(val1, val2): """ Assert ``val1`` and ``val2`` are the same type and of non-equal value. """ assert type(val1) is type(val2), '%r != %r' % (val1, val2) assert val1 != val2, '%r == %r' % (val1, val2) class Fuzzy: r""" Perform a fuzzy (non-strict) equality tests. `Fuzzy` instances will likely be used when comparing nesting data-structures using `assert_deepequal()`. By default a `Fuzzy` instance is equal to everything. For example, all of these evaluate to ``True``: >>> Fuzzy() == False True >>> 7 == Fuzzy() # Order doesn't matter True >>> Fuzzy() == u'Hello False, Lucky 7!' True The first optional argument *regex* is a regular expression pattern to match. For example, you could match a phone number like this: >>> phone = Fuzzy(r'^\d{3}-\d{3}-\d{4}$') >>> u'123-456-7890' == phone True Use of a regular expression by default implies the ``unicode`` type, so comparing with an ``str`` instance will evaluate to ``False``: >>> phone.type is str True >>> b'123-456-7890' == phone False The *type* kwarg allows you to specify a type constraint, so you can force the above to work on ``str`` instances instead: >>> '123-456-7890' == Fuzzy(r'^\d{3}-\d{3}-\d{4}$', type=str) True You can also use the *type* constraint on its own without the *regex*, for example: >>> 42 == Fuzzy(type=int) True >>> 42.0 == Fuzzy(type=int) False >>> 42.0 == Fuzzy(type=(int, float)) True Finally the *test* kwarg is an optional callable that will be called to perform the loose equality test. For example: >>> 42 == Fuzzy(test=lambda other: other > 42) False >>> 43 == Fuzzy(test=lambda other: other > 42) True You can use *type* and *test* together. For example: >>> 43 == Fuzzy(type=float, test=lambda other: other > 42) False >>> 42.5 == Fuzzy(type=float, test=lambda other: other > 42) True The *regex*, *type*, and *test* kwargs are all availabel via attributes on the `Fuzzy` instance: >>> fuzzy = Fuzzy('.+', type=str, test=lambda other: True) >>> fuzzy.regex '.+' >>> fuzzy.type is str True >>> fuzzy.test # doctest:+ELLIPSIS <function <lambda> at 0x...> To aid debugging, `Fuzzy.__repr__()` reveals these kwargs as well: >>> fuzzy # doctest:+ELLIPSIS Fuzzy('.+', <... 'str'>, <function <lambda> at 0x...>) """ __hash__ = None def __init__(self, regex=None, type=None, test=None): r""" Initialize. :param regex: A regular expression pattern to match, e.g. ``u'^\d+foo'`` :param type: A type or tuple of types to test using ``isinstance()``, e.g. ``(int, float)`` :param test: A callable used to perform equality test, e.g. ``lambda other: other >= 18`` """ assert regex is None or isinstance(regex, str) assert test is None or callable(test) if regex is None: self.re = None else: self.re = re.compile(regex) if type is None: type = unicode assert type in (unicode, bytes, str) self.regex = regex self.type = type self.test = test def __repr__(self): return '%s(%r, %r, %r)' % ( self.__class__.__name__, self.regex, self.type, self.test ) def __eq__(self, other): if not (self.type is None or isinstance(other, self.type)): return False if not (self.re is None or self.re.search(other)): return False if not (self.test is None or self.test(other)): return False return True def __ne__(self, other): return not self.__eq__(other) VALUE = """assert_deepequal: expected != got. %s expected = %r got = %r path = %r""" TYPE = """assert_deepequal: type(expected) is not type(got). %s type(expected) = %r type(got) = %r expected = %r got = %r path = %r""" LEN = """assert_deepequal: list length mismatch. %s len(expected) = %r len(got) = %r expected = %s got = %s path = %r""" KEYS = """assert_deepequal: dict keys mismatch. %s missing keys = %r extra keys = %r expected = %s got = %s path = %r""" EXPECTED_LEN = len(' expected = ') GOT_LEN = len(' got = ') def struct_to_string(struct, indent=1): """ Function to pretty-format a structure and optionally indent its lines so they match the visual indention of the first line """ return pformat(struct).replace('\n', '\n' + ' ' * indent) def assert_deepequal(expected, got, doc='', stack=tuple()): """ Recursively check for type and equality. If a value in expected is callable then it will used as a callback to test for equality on the got value. The callback is passed the got value and returns True if equal, False otherwise. If the tests fails, it will raise an ``AssertionError`` with detailed information, including the path to the offending value. For example: >>> expected = [u'Hello', dict(world=1)] >>> got = [u'Hello', dict(world=1.0)] >>> expected == got True >>> assert_deepequal( ... expected, got, doc='Testing my nested data') # doctest: +ELLIPSIS Traceback (most recent call last): ... AssertionError: assert_deepequal: type(expected) is not type(got). Testing my nested data type(expected) = <... 'int'> type(got) = <... 'float'> expected = 1 got = 1.0 path = (..., 'world') Note that lists and tuples are considered equivalent, and the order of their elements does not matter. """ if PRETTY_PRINT: expected_str = struct_to_string(expected, EXPECTED_LEN) got_str = struct_to_string(got, GOT_LEN) else: expected_str = repr(expected) got_str = repr(got) if isinstance(expected, tuple): expected = list(expected) if isinstance(got, tuple): got = list(got) if isinstance(expected, DN): if isinstance(got, str): got = DN(got) if ( not (isinstance(expected, Fuzzy) or callable(expected) or type(expected) is type(got)) ): raise AssertionError( TYPE % (doc, type(expected), type(got), expected, got, stack) ) if isinstance(expected, (list, tuple)): if len(expected) != len(got): raise AssertionError( LEN % (doc, len(expected), len(got), expected_str, got_str, stack) ) # Sort list elements, unless they are dictionaries if expected and isinstance(expected[0], dict): s_got = got s_expected = expected else: try: s_got = sorted(got) except TypeError: s_got = got try: s_expected = sorted(expected) except TypeError: s_expected = expected for (i, e_sub) in enumerate(s_expected): g_sub = s_got[i] assert_deepequal(e_sub, g_sub, doc, stack + (i,)) elif isinstance(expected, dict): missing = set(expected).difference(got) extra = set(got).difference(expected) if missing or extra: raise AssertionError(KEYS % ( doc, sorted(missing), sorted(extra), expected_str, got_str, stack) ) for key in sorted(expected): e_sub = expected[key] g_sub = got[key] assert_deepequal(e_sub, g_sub, doc, stack + (key,)) elif callable(expected): if not expected(got): raise AssertionError( VALUE % (doc, expected, got, stack) ) elif expected != got: raise AssertionError( VALUE % (doc, expected, got, stack) ) def raises(exception, callback, *args, **kw): """ Tests that the expected exception is raised; raises ExceptionNotRaised if test fails. """ try: callback(*args, **kw) except exception as e: return e raise ExceptionNotRaised(exception) def getitem(obj, key): """ Works like getattr but for dictionary interface. Use this in combination with raises() to test that, for example, KeyError is raised. """ return obj[key] def setitem(obj, key, value): """ Works like setattr but for dictionary interface. Use this in combination with raises() to test that, for example, TypeError is raised. """ obj[key] = value def delitem(obj, key): """ Works like delattr but for dictionary interface. Use this in combination with raises() to test that, for example, TypeError is raised. """ del obj[key] def no_set(obj, name, value='some_new_obj'): """ Tests that attribute cannot be set. """ raises(AttributeError, setattr, obj, name, value) def no_del(obj, name): """ Tests that attribute cannot be deleted. """ raises(AttributeError, delattr, obj, name) def read_only(obj, name, value='some_new_obj'): """ Tests that attribute is read-only. Returns attribute. """ # Test that it cannot be set: no_set(obj, name, value) # Test that it cannot be deleted: no_del(obj, name) # Return the attribute return getattr(obj, name) def is_prop(prop): return type(prop) is property class ClassChecker: __cls = None __subcls = None def __get_cls(self): if self.__cls is None: self.__cls = self._cls # pylint: disable=E1101 assert inspect.isclass(self.__cls) return self.__cls cls = property(__get_cls) def __get_subcls(self): if self.__subcls is None: self.__subcls = self.get_subcls() assert inspect.isclass(self.__subcls) return self.__subcls subcls = property(__get_subcls) def get_subcls(self): raise AttributeError( self.__class__.__name__, 'get_subcls()' ) @pytest.fixture(autouse=True) def classchecker_setup(self, request): def fin(): context.__dict__.clear() request.addfinalizer(fin) def get_api(**kw): """ Returns (api, home) tuple. This function returns a tuple containing an `ipalib.plugable.API` instance and a `TempHome` instance. """ home = TempHome() api = ipalib.create_api(mode='unit_test') api.env.in_tree = True for (key, value) in kw.items(): api.env[key] = value return (api, home) def create_test_api(**kw): """ Returns (api, home) tuple. This function returns a tuple containing an `ipalib.plugable.API` instance and a `TempHome` instance. """ home = TempHome() api = ipalib.create_api(mode='unit_test') api.env.in_tree = True for (key, value) in kw.items(): api.env[key] = value return (api, home) class PluginTester: __plugin = None def __get_plugin(self): if self.__plugin is None: self.__plugin = self._plugin # pylint: disable=E1101 assert issubclass(self.__plugin, Plugin) return self.__plugin plugin = property(__get_plugin) def register(self, *plugins, **kw): r""" Create a testing api and register ``self.plugin``. This method returns an (api, home) tuple. :param plugins: Additional \*plugins to register. :param kw: Additional \**kw args to pass to `create_test_api`. """ (api, home) = create_test_api(**kw) api.add_plugin(self.plugin) for p in plugins: api.add_plugin(p) return (api, home) def finalize(self, *plugins, **kw): (api, home) = self.register(*plugins, **kw) api.finalize() return (api, home) def instance(self, namespace, *plugins, **kw): (api, home) = self.finalize(*plugins, **kw) o = api[namespace][self.plugin.__name__] return (o, api, home) @pytest.fixture(autouse=True) def plugintester_setup(self, request): def fin(): context.__dict__.clear() request.addfinalizer(fin) class dummy_ugettext: __called = False def __init__(self, translation=None): if translation is None: translation = u'The translation' self.translation = translation assert type(self.translation) is unicode def __call__(self, message): assert self.__called is False self.__called = True assert type(message) is str assert not hasattr(self, 'message') self.message = message assert type(self.translation) is unicode return self.translation def called(self): return self.__called def reset(self): assert type(self.translation) is unicode assert type(self.message) is str del self.message assert self.__called is True self.__called = False class dummy_ungettext: __called = False def __init__(self): self.translation_singular = u'The singular translation' self.translation_plural = u'The plural translation' def __call__(self, singular, plural, n): assert type(singular) is str assert type(plural) is str assert type(n) is int assert self.__called is False self.__called = True self.singular = singular self.plural = plural self.n = n if n == 1: return self.translation_singular return self.translation_plural class DummyMethod: def __init__(self, callback, name): self.__callback = callback self.__name = name def __call__(self, *args, **kw): return self.__callback(self.__name, args, kw) class DummyClass: def __init__(self, *calls): self.__calls = calls self.__i = 0 for (name, _args, _kw, _result) in calls: method = DummyMethod(self.__process, name) setattr(self, name, method) def __process(self, name_, args_, kw_): if self.__i >= len(self.__calls): raise AssertionError( "extra call: {name!s}, {args!r}, {kwargs!r}".format( name=name_, args=args_, kwargs=kw_ ) ) (name, args, kw, result) = self.__calls[self.__i] self.__i += 1 i = self.__i if name_ != name: raise AssertionError( "call {0:d} should be to method {1!r}; got {2!r}".format( i, name, name_ ) ) if args_ != args: raise AssertionError( "call {0:d} to {1!r} should have args {2!r}; got {3!r}".format( i, name, args, args_ ) ) if kw_ != kw: raise AssertionError( "call {0:d} to {1!r} should have kw {2!r}, got {3!r}".format( i, name, kw, kw_ ) ) if isinstance(result, Exception): raise result return result def _calledall(self): return self.__i == len(self.__calls) class MockLDAP: def __init__(self): self.connection = ldap_initialize( 'ldap://{host}'.format(host=ipalib.api.env.host) ) auth = ldap.sasl.gssapi('') self.connection.sasl_interactive_bind_s('', auth) def add_entry(self, dn, mods): try: ldif = ldap.modlist.addModlist(mods) self.connection.add_s(dn, ldif) except ldap.ALREADY_EXISTS: pass def mod_entry(self, dn, mods): self.connection.modify_s(dn, mods) def del_entry(self, dn): try: self.connection.delete_s(dn) except ldap.NO_SUCH_OBJECT: pass def unbind(self): if self.connection is not None: self.connection.unbind_s() # contextmanager protocol def __enter__(self): return self def __exit__(self, exc_type, exc_value, traceback): self.unbind() def prepare_config(template, values): with open(template) as f: template = f.read() with tempfile.NamedTemporaryFile(mode='w', delete=False) as config: config.write(template.format(**values)) return config.name def unlock_principal_password(user, oldpw, newpw): userdn = "uid={},{},{}".format( user, api.env.container_user, api.env.basedn) args = [paths.LDAPPASSWD, '-D', userdn, '-w', oldpw, '-a', oldpw, '-s', newpw, '-x', '-H', api.env.ldap_uri] return run(args) @contextmanager def change_principal(principal, password=None, client=None, path=None, canonicalize=False, enterprise=False, keytab=None): """Temporarily change the kerberos principal Most of the test cases run with the admin ipa user which is granted all access and exceptions from rules on some occasions. When the test needs to test for an application of some kind of a restriction it needs to authenticate as a different principal with required set of rights to the operation. The context manager changes the principal identity in two ways: * using password * using keytab If the context manager is to be used with a keytab, the keytab option must be its absolute path. The context manager can be used to authenticate with enterprise principals and aliases when given respective options. """ if path: ccache_name = path else: ccache_name = os.path.join('/tmp', str(uuid.uuid4())) if client is None: client = api client.Backend.rpcclient.disconnect() try: if keytab: kinit_keytab(principal, keytab, ccache_name) else: kinit_password(principal, password, ccache_name, canonicalize=canonicalize, enterprise=enterprise) client.Backend.rpcclient.connect(ccache=ccache_name) try: yield finally: client.Backend.rpcclient.disconnect() finally: # If we generated a ccache name, try to remove it, but don't fail if not path: try: os.remove(ccache_name) except OSError: pass client.Backend.rpcclient.connect() @contextmanager def get_entity_keytab(principal, options=None): """Requests a keytab for an entity The keytab will generate new keys if not specified otherwise in the options. To retrieve existing keytab, use the -r option """ keytab_filename = os.path.join('/tmp', str(uuid.uuid4())) try: cmd = [paths.IPA_GETKEYTAB, '-p', principal, '-k', keytab_filename] if options: cmd.extend(options) run(cmd) yield keytab_filename finally: if os.path.isfile(keytab_filename): os.remove(keytab_filename) @contextmanager def host_keytab(hostname, options=None): """Retrieves keytab for a particular host After leaving the context manager, the keytab file is deleted. """ principal = u'host/{}'.format(hostname) with get_entity_keytab(principal, options) as keytab: yield keytab def get_group_dn(cn): return DN(('cn', cn), api.env.container_group, api.env.basedn) def get_user_dn(uid): return DN(('uid', uid), api.env.container_user, api.env.basedn) @contextmanager def xfail_context(condition, reason): """Expect a block of code to fail. This function provides functionality similar to pytest.mark.xfail but for a block of code instead of the whole test function. This has two benefits: 1) you can mark single line as expectedly failing without suppressing all other errors in the test function 2) you can use conditions which can not be evaluated before the test start. The check is always done in "strict" mode, i.e. if test is expected to fail but succeeds then it will be marked as failing. """ try: yield except Exception: if condition: pytest.xfail(reason) raise else: if condition: pytest.fail('XPASS(strict) reason: {}'.format(reason), False)
24,923
Python
.py
713
27.757363
79
0.61291
freeipa/freeipa
975
339
31
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)
16,299
setup.py
freeipa_freeipa/ipatests/setup.py
# Copyright (C) 2007 Red Hat # see file 'COPYING' for use and warranty information # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. # """FreeIPA tests FreeIPA is a server for identity, policy, and audit. """ from os.path import abspath, dirname import sys if __name__ == '__main__': # include ../ for ipasetup.py sys.path.append(dirname(dirname(abspath(__file__)))) from ipasetup import ipasetup # noqa: E402 ipasetup( name="ipatests", doc=__doc__, package_dir={'ipatests': ''}, packages=[ "ipatests", "ipatests.pytest_ipa", "ipatests.pytest_ipa.integration", "ipatests.test_cmdline", "ipatests.test_custodia", "ipatests.test_install", "ipatests.test_integration", "ipatests.test_ipaclient", "ipatests.test_ipalib", "ipatests.test_ipalib_install", "ipatests.test_ipaplatform", "ipatests.test_ipapython", "ipatests.test_ipaserver", "ipatests.test_ipaserver.test_install", "ipatests.test_ipatests_plugins", "ipatests.test_webui", "ipatests.test_xmlrpc", "ipatests.test_xmlrpc.tracker" ], scripts=['ipa-run-tests', 'ipa-test-config', 'ipa-test-task'], package_data={ 'ipatests': ['prci_definitions/*'], 'ipatests.test_custodia': ['*.conf', 'empty.conf.d/*.conf'], 'ipatests.test_install': ['*.update'], 'ipatests.test_integration': ['scripts/*'], 'ipatests.test_ipaclient': ['data/*/*/*'], 'ipatests.test_ipalib': ['data/*'], 'ipatests.test_ipaplatform': ['data/*'], "ipatests.test_ipaserver": ['data/*'], 'ipatests.test_xmlrpc': ['data/*'], }, install_requires=[ "cryptography", "dnspython", "gssapi", "ipaclient", "ipalib", "ipaplatform", "ipapython", "polib", "pytest", "pytest_multihost", "python-ldap", "six", "pexpect", ], extras_require={ "integration": ["dbus-python", "pyyaml", "ipaserver"], "ipaserver": ["ipaserver"], "webui": ["selenium", "pyyaml", "ipaserver"], "xmlrpc": ["ipaserver"], ":python_version<'3'": ["mock"], } )
3,083
Python
.py
84
27.845238
72
0.573289
freeipa/freeipa
975
339
31
GPL-3.0
9/5/2024, 5:12:14 PM (Europe/Amsterdam)