chiark / gitweb /
Merge branch 'random-small-fixes' into 'master'
[fdroidserver.git] / fdroidserver / lint.py
1 #!/usr/bin/env python3
2 #
3 # lint.py - part of the FDroid server tool
4 # Copyright (C) 2013-2014 Daniel Martí <mvdan@mvdan.cc>
5 #
6 # This program is free software: you can redistribute it and/or modify
7 # it under the terms of the GNU Affero General Public License as published by
8 # the Free Software Foundation, either version 3 of the License, or
9 # (at your option) any later version.
10 #
11 # This program is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See th
14 # GNU Affero General Public License for more details.
15 #
16 # You should have received a copy of the GNU Affero General Public Licen
17 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
18
19 from argparse import ArgumentParser
20 import glob
21 import os
22 import re
23 import sys
24
25 from . import common
26 from . import metadata
27 from . import rewritemeta
28
29 config = None
30 options = None
31
32
33 def enforce_https(domain):
34     return (re.compile(r'.*[^sS]://[^/]*' + re.escape(domain) + r'(/.*)?'),
35             domain + " URLs should always use https://")
36
37
38 https_enforcings = [
39     enforce_https('github.com'),
40     enforce_https('gitlab.com'),
41     enforce_https('bitbucket.org'),
42     enforce_https('apache.org'),
43     enforce_https('google.com'),
44     enforce_https('svn.code.sf.net'),
45 ]
46
47
48 def forbid_shortener(domain):
49     return (re.compile(r'https?://[^/]*' + re.escape(domain) + r'/.*'),
50             "URL shorteners should not be used")
51
52
53 http_url_shorteners = [
54     forbid_shortener('goo.gl'),
55     forbid_shortener('t.co'),
56     forbid_shortener('ur1.ca'),
57     forbid_shortener('is.gd'),
58     forbid_shortener('bit.ly'),
59     forbid_shortener('tiny.cc'),
60     forbid_shortener('tinyurl.com'),
61 ]
62
63 http_checks = https_enforcings + http_url_shorteners + [
64     (re.compile(r'.*github\.com/[^/]+/[^/]+\.git'),
65      "Appending .git is not necessary"),
66     (re.compile(r'.*://[^/]*(github|gitlab|bitbucket|rawgit)[^/]*/([^/]+/){1,3}master'),
67      "Use /HEAD instead of /master to point at a file in the default branch"),
68 ]
69
70 regex_checks = {
71     'WebSite': http_checks,
72     'SourceCode': http_checks,
73     'Repo': https_enforcings,
74     'IssueTracker': http_checks + [
75         (re.compile(r'.*github\.com/[^/]+/[^/]+/*$'),
76          "/issues is missing"),
77         (re.compile(r'.*gitlab\.com/[^/]+/[^/]+/*$'),
78          "/issues is missing"),
79     ],
80     'Donate': http_checks + [
81         (re.compile(r'.*flattr\.com'),
82          "Flattr donation methods belong in the FlattrID flag"),
83     ],
84     'Changelog': http_checks,
85     'Author Name': [
86         (re.compile(r'^\s'),
87          "Unnecessary leading space"),
88         (re.compile(r'.*\s$'),
89          "Unnecessary trailing space"),
90     ],
91     'Summary': [
92         (re.compile(r'.*\b(free software|open source)\b.*', re.IGNORECASE),
93          "No need to specify that the app is Free Software"),
94         (re.compile(r'.*((your|for).*android|android.*(app|device|client|port|version))', re.IGNORECASE),
95          "No need to specify that the app is for Android"),
96         (re.compile(r'.*[a-z0-9][.!?]( |$)'),
97          "Punctuation should be avoided"),
98         (re.compile(r'^\s'),
99          "Unnecessary leading space"),
100         (re.compile(r'.*\s$'),
101          "Unnecessary trailing space"),
102     ],
103     'Description': [
104         (re.compile(r'\s*[*#][^ .]'),
105          "Invalid bulleted list"),
106         (re.compile(r'^\s'),
107          "Unnecessary leading space"),
108         (re.compile(r'.*\s$'),
109          "Unnecessary trailing space"),
110         (re.compile(r'.*([^[]|^)\[[^:[\]]+( |\]|$)'),
111          "Invalid link - use [http://foo.bar Link title] or [http://foo.bar]"),
112         (re.compile(r'(^|.* )https?://[^ ]+'),
113          "Unlinkified link - use [http://foo.bar Link title] or [http://foo.bar]"),
114     ],
115 }
116
117 locale_pattern = re.compile(r'^[a-z]{2,3}(-[A-Z][A-Z])?$')
118
119
120 def check_regexes(app):
121     for f, checks in regex_checks.items():
122         for m, r in checks:
123             v = app.get(f)
124             t = metadata.fieldtype(f)
125             if t == metadata.TYPE_MULTILINE:
126                 for l in v.splitlines():
127                     if m.match(l):
128                         yield "%s at line '%s': %s" % (f, l, r)
129             else:
130                 if v is None:
131                     continue
132                 if m.match(v):
133                     yield "%s '%s': %s" % (f, v, r)
134
135
136 def get_lastbuild(builds):
137     lowest_vercode = -1
138     lastbuild = None
139     for build in builds:
140         if not build.disable:
141             vercode = int(build.versionCode)
142             if lowest_vercode == -1 or vercode < lowest_vercode:
143                 lowest_vercode = vercode
144         if not lastbuild or int(build.versionCode) > int(lastbuild.versionCode):
145             lastbuild = build
146     return lastbuild
147
148
149 def check_ucm_tags(app):
150     lastbuild = get_lastbuild(app.builds)
151     if (lastbuild is not None
152             and lastbuild.commit
153             and app.UpdateCheckMode == 'RepoManifest'
154             and not lastbuild.commit.startswith('unknown')
155             and lastbuild.versionCode == app.CurrentVersionCode
156             and not lastbuild.forcevercode
157             and any(s in lastbuild.commit for s in '.,_-/')):
158         yield "Last used commit '%s' looks like a tag, but Update Check Mode is '%s'" % (
159             lastbuild.commit, app.UpdateCheckMode)
160
161
162 def check_char_limits(app):
163     limits = config['char_limits']
164
165     if len(app.Summary) > limits['summary']:
166         yield "Summary of length %s is over the %i char limit" % (
167             len(app.Summary), limits['summary'])
168
169     if len(app.Description) > limits['description']:
170         yield "Description of length %s is over the %i char limit" % (
171             len(app.Description), limits['description'])
172
173
174 def check_old_links(app):
175     usual_sites = [
176         'github.com',
177         'gitlab.com',
178         'bitbucket.org',
179     ]
180     old_sites = [
181         'gitorious.org',
182         'code.google.com',
183     ]
184     if any(s in app.Repo for s in usual_sites):
185         for f in ['WebSite', 'SourceCode', 'IssueTracker', 'Changelog']:
186             v = app.get(f)
187             if any(s in v for s in old_sites):
188                 yield "App is in '%s' but has a link to '%s'" % (app.Repo, v)
189
190
191 def check_useless_fields(app):
192     if app.UpdateCheckName == app.id:
193         yield "Update Check Name is set to the known app id - it can be removed"
194
195
196 filling_ucms = re.compile(r'^(Tags.*|RepoManifest.*)')
197
198
199 def check_checkupdates_ran(app):
200     if filling_ucms.match(app.UpdateCheckMode):
201         if not app.AutoName and not app.CurrentVersion and app.CurrentVersionCode == '0':
202             yield "UCM is set but it looks like checkupdates hasn't been run yet"
203
204
205 def check_empty_fields(app):
206     if not app.Categories:
207         yield "Categories are not set"
208
209
210 all_categories = set([
211     "Connectivity",
212     "Development",
213     "Games",
214     "Graphics",
215     "Internet",
216     "Money",
217     "Multimedia",
218     "Navigation",
219     "Phone & SMS",
220     "Reading",
221     "Science & Education",
222     "Security",
223     "Sports & Health",
224     "System",
225     "Theming",
226     "Time",
227     "Writing",
228 ])
229
230
231 def check_categories(app):
232     for categ in app.Categories:
233         if categ not in all_categories:
234             yield "Category '%s' is not valid" % categ
235
236
237 def check_duplicates(app):
238     if app.Name and app.Name == app.AutoName:
239         yield "Name '%s' is just the auto name - remove it" % app.Name
240
241     links_seen = set()
242     for f in ['Source Code', 'Web Site', 'Issue Tracker', 'Changelog']:
243         v = app.get(f)
244         if not v:
245             continue
246         v = v.lower()
247         if v in links_seen:
248             yield "Duplicate link in '%s': %s" % (f, v)
249         else:
250             links_seen.add(v)
251
252     name = app.Name or app.AutoName
253     if app.Summary and name:
254         if app.Summary.lower() == name.lower():
255             yield "Summary '%s' is just the app's name" % app.Summary
256
257     if app.Summary and app.Description and len(app.Description) == 1:
258         if app.Summary.lower() == app.Description[0].lower():
259             yield "Description '%s' is just the app's summary" % app.Summary
260
261     seenlines = set()
262     for l in app.Description.splitlines():
263         if len(l) < 1:
264             continue
265         if l in seenlines:
266             yield "Description has a duplicate line"
267         seenlines.add(l)
268
269
270 desc_url = re.compile(r'(^|[^[])\[([^ ]+)( |\]|$)')
271
272
273 def check_mediawiki_links(app):
274     wholedesc = ' '.join(app.Description)
275     for um in desc_url.finditer(wholedesc):
276         url = um.group(1)
277         for m, r in http_checks:
278             if m.match(url):
279                 yield "URL '%s' in Description: %s" % (url, r)
280
281
282 def check_bulleted_lists(app):
283     validchars = ['*', '#']
284     lchar = ''
285     lcount = 0
286     for l in app.Description.splitlines():
287         if len(l) < 1:
288             lcount = 0
289             continue
290
291         if l[0] == lchar and l[1] == ' ':
292             lcount += 1
293             if lcount > 2 and lchar not in validchars:
294                 yield "Description has a list (%s) but it isn't bulleted (*) nor numbered (#)" % lchar
295                 break
296         else:
297             lchar = l[0]
298             lcount = 1
299
300
301 def check_builds(app):
302     for build in app.builds:
303         if build.disable:
304             if build.disable.startswith('Generated by import.py'):
305                 yield "Build generated by `fdroid import` - remove disable line once ready"
306             continue
307         for s in ['master', 'origin', 'HEAD', 'default', 'trunk']:
308             if build.commit and build.commit.startswith(s):
309                 yield "Branch '%s' used as commit in build '%s'" % (s, build.versionName)
310             for srclib in build.srclibs:
311                 ref = srclib.split('@')[1].split('/')[0]
312                 if ref.startswith(s):
313                     yield "Branch '%s' used as commit in srclib '%s'" % (s, srclib)
314
315
316 def check_files_dir(app):
317     dir_path = os.path.join('metadata', app.id)
318     if not os.path.isdir(dir_path):
319         return
320     files = set()
321     for name in os.listdir(dir_path):
322         path = os.path.join(dir_path, name)
323         if not (os.path.isfile(path) or name == 'signatures' or locale_pattern.match(name)):
324             yield "Found non-file at %s" % path
325             continue
326         files.add(name)
327
328     used = {'signatures', }
329     for build in app.builds:
330         for fname in build.patch:
331             if fname not in files:
332                 yield "Unknown file %s in build '%s'" % (fname, build.versionName)
333             else:
334                 used.add(fname)
335
336     for name in files.difference(used):
337         if locale_pattern.match(name):
338             continue
339         yield "Unused file at %s" % os.path.join(dir_path, name)
340
341
342 def check_format(app):
343     if options.format and not rewritemeta.proper_format(app):
344         yield "Run rewritemeta to fix formatting"
345
346
347 def check_license_tag(app):
348     '''Ensure all license tags are in https://spdx.org/license-list'''
349     if app.License.rstrip('+') not in SPDX:
350         yield 'Invalid license tag "%s"! Use only tags from https://spdx.org/license-list' \
351             % (app.License)
352
353
354 def check_extlib_dir(apps):
355     dir_path = os.path.join('build', 'extlib')
356     files = set()
357     for root, dirs, names in os.walk(dir_path):
358         for name in names:
359             files.add(os.path.join(root, name)[len(dir_path) + 1:])
360
361     used = set()
362     for app in apps:
363         for build in app.builds:
364             for path in build.extlibs:
365                 if path not in files:
366                     yield "%s: Unknown extlib %s in build '%s'" % (app.id, path, build.versionName)
367                 else:
368                     used.add(path)
369
370     for path in files.difference(used):
371         if any(path.endswith(s) for s in [
372                 '.gitignore',
373                 'source.txt', 'origin.txt', 'md5.txt',
374                 'LICENSE', 'LICENSE.txt',
375                 'COPYING', 'COPYING.txt',
376                 'NOTICE', 'NOTICE.txt',
377                 ]):
378             continue
379         yield "Unused extlib at %s" % os.path.join(dir_path, path)
380
381
382 def check_for_unsupported_metadata_files(basedir=""):
383     """Checks whether any non-metadata files are in metadata/"""
384
385     global config
386
387     return_value = False
388     formats = config['accepted_formats']
389     for f in glob.glob(basedir + 'metadata/*') + glob.glob(basedir + 'metadata/.*'):
390         if os.path.isdir(f):
391             exists = False
392             for t in formats:
393                 exists = exists or os.path.exists(f + '.' + t)
394             if not exists:
395                 print('"' + f + '/" has no matching metadata file!')
396                 return_value = True
397         elif not os.path.splitext(f)[1][1:] in formats:
398             print('"' + f.replace(basedir, '')
399                   + '" is not a supported file format: (' + ','.join(formats) + ')')
400             return_value = True
401
402     return return_value
403
404
405 def main():
406
407     global config, options
408
409     # Parse command line...
410     parser = ArgumentParser(usage="%(prog)s [options] [APPID [APPID ...]]")
411     common.setup_global_opts(parser)
412     parser.add_argument("-f", "--format", action="store_true", default=False,
413                         help="Also warn about formatting issues, like rewritemeta -l")
414     parser.add_argument("appid", nargs='*', help="app-id in the form APPID")
415     metadata.add_metadata_arguments(parser)
416     options = parser.parse_args()
417     metadata.warnings_action = options.W
418
419     config = common.read_config(options)
420
421     # Get all apps...
422     allapps = metadata.read_metadata(xref=True)
423     apps = common.read_app_args(options.appid, allapps, False)
424
425     anywarns = check_for_unsupported_metadata_files()
426
427     apps_check_funcs = []
428     if len(options.appid) == 0:
429         # otherwise it finds tons of unused extlibs
430         apps_check_funcs.append(check_extlib_dir)
431     for check_func in apps_check_funcs:
432         for warn in check_func(apps.values()):
433             anywarns = True
434             print(warn)
435
436     for appid, app in apps.items():
437         if app.Disabled:
438             continue
439
440         app_check_funcs = [
441             check_regexes,
442             check_ucm_tags,
443             check_char_limits,
444             check_old_links,
445             check_checkupdates_ran,
446             check_useless_fields,
447             check_empty_fields,
448             check_categories,
449             check_duplicates,
450             check_mediawiki_links,
451             check_bulleted_lists,
452             check_builds,
453             check_files_dir,
454             check_format,
455             check_license_tag,
456         ]
457
458         for check_func in app_check_funcs:
459             for warn in check_func(app):
460                 anywarns = True
461                 print("%s: %s" % (appid, warn))
462
463     if anywarns:
464         sys.exit(1)
465
466
467 # A compiled, public domain list of official SPDX license tags from:
468 # https://github.com/sindresorhus/spdx-license-list/blob/v3.0.1/spdx-simple.json
469 # The deprecated license tags have been removed from the list, they are at the
470 # bottom, starting after the last license tags that start with Z.
471 # This is at the bottom, since its a long list of data
472 SPDX = [
473     "PublicDomain",  # an F-Droid addition, until we can enforce a better option
474     "Glide",
475     "Abstyles",
476     "AFL-1.1",
477     "AFL-1.2",
478     "AFL-2.0",
479     "AFL-2.1",
480     "AFL-3.0",
481     "AMPAS",
482     "APL-1.0",
483     "Adobe-Glyph",
484     "APAFML",
485     "Adobe-2006",
486     "AGPL-1.0",
487     "Afmparse",
488     "Aladdin",
489     "ADSL",
490     "AMDPLPA",
491     "ANTLR-PD",
492     "Apache-1.0",
493     "Apache-1.1",
494     "Apache-2.0",
495     "AML",
496     "APSL-1.0",
497     "APSL-1.1",
498     "APSL-1.2",
499     "APSL-2.0",
500     "Artistic-1.0",
501     "Artistic-1.0-Perl",
502     "Artistic-1.0-cl8",
503     "Artistic-2.0",
504     "AAL",
505     "Bahyph",
506     "Barr",
507     "Beerware",
508     "BitTorrent-1.0",
509     "BitTorrent-1.1",
510     "BSL-1.0",
511     "Borceux",
512     "BSD-2-Clause",
513     "BSD-2-Clause-FreeBSD",
514     "BSD-2-Clause-NetBSD",
515     "BSD-3-Clause",
516     "BSD-3-Clause-Clear",
517     "BSD-3-Clause-No-Nuclear-License",
518     "BSD-3-Clause-No-Nuclear-License-2014",
519     "BSD-3-Clause-No-Nuclear-Warranty",
520     "BSD-4-Clause",
521     "BSD-Protection",
522     "BSD-Source-Code",
523     "BSD-3-Clause-Attribution",
524     "0BSD",
525     "BSD-4-Clause-UC",
526     "bzip2-1.0.5",
527     "bzip2-1.0.6",
528     "Caldera",
529     "CECILL-1.0",
530     "CECILL-1.1",
531     "CECILL-2.0",
532     "CECILL-2.1",
533     "CECILL-B",
534     "CECILL-C",
535     "ClArtistic",
536     "MIT-CMU",
537     "CNRI-Jython",
538     "CNRI-Python",
539     "CNRI-Python-GPL-Compatible",
540     "CPOL-1.02",
541     "CDDL-1.0",
542     "CDDL-1.1",
543     "CPAL-1.0",
544     "CPL-1.0",
545     "CATOSL-1.1",
546     "Condor-1.1",
547     "CC-BY-1.0",
548     "CC-BY-2.0",
549     "CC-BY-2.5",
550     "CC-BY-3.0",
551     "CC-BY-4.0",
552     "CC-BY-ND-1.0",
553     "CC-BY-ND-2.0",
554     "CC-BY-ND-2.5",
555     "CC-BY-ND-3.0",
556     "CC-BY-ND-4.0",
557     "CC-BY-NC-1.0",
558     "CC-BY-NC-2.0",
559     "CC-BY-NC-2.5",
560     "CC-BY-NC-3.0",
561     "CC-BY-NC-4.0",
562     "CC-BY-NC-ND-1.0",
563     "CC-BY-NC-ND-2.0",
564     "CC-BY-NC-ND-2.5",
565     "CC-BY-NC-ND-3.0",
566     "CC-BY-NC-ND-4.0",
567     "CC-BY-NC-SA-1.0",
568     "CC-BY-NC-SA-2.0",
569     "CC-BY-NC-SA-2.5",
570     "CC-BY-NC-SA-3.0",
571     "CC-BY-NC-SA-4.0",
572     "CC-BY-SA-1.0",
573     "CC-BY-SA-2.0",
574     "CC-BY-SA-2.5",
575     "CC-BY-SA-3.0",
576     "CC-BY-SA-4.0",
577     "CC0-1.0",
578     "Crossword",
579     "CrystalStacker",
580     "CUA-OPL-1.0",
581     "Cube",
582     "curl",
583     "D-FSL-1.0",
584     "diffmark",
585     "WTFPL",
586     "DOC",
587     "Dotseqn",
588     "DSDP",
589     "dvipdfm",
590     "EPL-1.0",
591     "ECL-1.0",
592     "ECL-2.0",
593     "eGenix",
594     "EFL-1.0",
595     "EFL-2.0",
596     "MIT-advertising",
597     "MIT-enna",
598     "Entessa",
599     "ErlPL-1.1",
600     "EUDatagrid",
601     "EUPL-1.0",
602     "EUPL-1.1",
603     "Eurosym",
604     "Fair",
605     "MIT-feh",
606     "Frameworx-1.0",
607     "FreeImage",
608     "FTL",
609     "FSFAP",
610     "FSFUL",
611     "FSFULLR",
612     "Giftware",
613     "GL2PS",
614     "Glulxe",
615     "AGPL-3.0",
616     "GFDL-1.1",
617     "GFDL-1.2",
618     "GFDL-1.3",
619     "GPL-1.0",
620     "GPL-2.0",
621     "GPL-3.0",
622     "LGPL-2.1",
623     "LGPL-3.0",
624     "LGPL-2.0",
625     "gnuplot",
626     "gSOAP-1.3b",
627     "HaskellReport",
628     "HPND",
629     "IBM-pibs",
630     "IPL-1.0",
631     "ICU",
632     "ImageMagick",
633     "iMatix",
634     "Imlib2",
635     "IJG",
636     "Info-ZIP",
637     "Intel-ACPI",
638     "Intel",
639     "Interbase-1.0",
640     "IPA",
641     "ISC",
642     "JasPer-2.0",
643     "JSON",
644     "LPPL-1.0",
645     "LPPL-1.1",
646     "LPPL-1.2",
647     "LPPL-1.3a",
648     "LPPL-1.3c",
649     "Latex2e",
650     "BSD-3-Clause-LBNL",
651     "Leptonica",
652     "LGPLLR",
653     "Libpng",
654     "libtiff",
655     "LAL-1.2",
656     "LAL-1.3",
657     "LiLiQ-P-1.1",
658     "LiLiQ-Rplus-1.1",
659     "LiLiQ-R-1.1",
660     "LPL-1.02",
661     "LPL-1.0",
662     "MakeIndex",
663     "MTLL",
664     "MS-PL",
665     "MS-RL",
666     "MirOS",
667     "MITNFA",
668     "MIT",
669     "Motosoto",
670     "MPL-1.0",
671     "MPL-1.1",
672     "MPL-2.0",
673     "MPL-2.0-no-copyleft-exception",
674     "mpich2",
675     "Multics",
676     "Mup",
677     "NASA-1.3",
678     "Naumen",
679     "NBPL-1.0",
680     "Net-SNMP",
681     "NetCDF",
682     "NGPL",
683     "NOSL",
684     "NPL-1.0",
685     "NPL-1.1",
686     "Newsletr",
687     "NLPL",
688     "Nokia",
689     "NPOSL-3.0",
690     "NLOD-1.0",
691     "Noweb",
692     "NRL",
693     "NTP",
694     "Nunit",
695     "OCLC-2.0",
696     "ODbL-1.0",
697     "PDDL-1.0",
698     "OCCT-PL",
699     "OGTSL",
700     "OLDAP-2.2.2",
701     "OLDAP-1.1",
702     "OLDAP-1.2",
703     "OLDAP-1.3",
704     "OLDAP-1.4",
705     "OLDAP-2.0",
706     "OLDAP-2.0.1",
707     "OLDAP-2.1",
708     "OLDAP-2.2",
709     "OLDAP-2.2.1",
710     "OLDAP-2.3",
711     "OLDAP-2.4",
712     "OLDAP-2.5",
713     "OLDAP-2.6",
714     "OLDAP-2.7",
715     "OLDAP-2.8",
716     "OML",
717     "OPL-1.0",
718     "OSL-1.0",
719     "OSL-1.1",
720     "OSL-2.0",
721     "OSL-2.1",
722     "OSL-3.0",
723     "OpenSSL",
724     "OSET-PL-2.1",
725     "PHP-3.0",
726     "PHP-3.01",
727     "Plexus",
728     "PostgreSQL",
729     "psfrag",
730     "psutils",
731     "Python-2.0",
732     "QPL-1.0",
733     "Qhull",
734     "Rdisc",
735     "RPSL-1.0",
736     "RPL-1.1",
737     "RPL-1.5",
738     "RHeCos-1.1",
739     "RSCPL",
740     "RSA-MD",
741     "Ruby",
742     "SAX-PD",
743     "Saxpath",
744     "SCEA",
745     "SWL",
746     "SMPPL",
747     "Sendmail",
748     "SGI-B-1.0",
749     "SGI-B-1.1",
750     "SGI-B-2.0",
751     "OFL-1.0",
752     "OFL-1.1",
753     "SimPL-2.0",
754     "Sleepycat",
755     "SNIA",
756     "Spencer-86",
757     "Spencer-94",
758     "Spencer-99",
759     "SMLNJ",
760     "SugarCRM-1.1.3",
761     "SISSL",
762     "SISSL-1.2",
763     "SPL-1.0",
764     "Watcom-1.0",
765     "TCL",
766     "TCP-wrappers",
767     "Unlicense",
768     "TMate",
769     "TORQUE-1.1",
770     "TOSL",
771     "Unicode-DFS-2015",
772     "Unicode-DFS-2016",
773     "Unicode-TOU",
774     "UPL-1.0",
775     "NCSA",
776     "Vim",
777     "VOSTROM",
778     "VSL-1.0",
779     "W3C-20150513",
780     "W3C-19980720",
781     "W3C",
782     "Wsuipa",
783     "Xnet",
784     "X11",
785     "Xerox",
786     "XFree86-1.1",
787     "xinetd",
788     "xpp",
789     "XSkat",
790     "YPL-1.0",
791     "YPL-1.1",
792     "Zed",
793     "Zend-2.0",
794     "Zimbra-1.3",
795     "Zimbra-1.4",
796     "Zlib",
797     "zlib-acknowledgement",
798     "ZPL-1.1",
799     "ZPL-2.0",
800     "ZPL-2.1",
801 ]
802
803 if __name__ == "__main__":
804     main()