From acc2c59920f0f19fd037cba90e764b8339964862 Mon Sep 17 00:00:00 2001 From: Henrik Levkowetz Date: Fri, 24 Apr 2015 21:47:12 +0000 Subject: [PATCH] Updated a bunch of links from http: to https: based on a patch from lars@netapp.com. - Legacy-Id: 9556 --- ietf/community/views.py | 2 +- ietf/doc/redirect_drafts_urls.py | 2 +- ietf/doc/redirect_idtracker_urls.py | 2 +- ietf/doc/utils.py | 4 +-- ietf/doc/views_doc.py | 8 +++--- ietf/iesg/urls.py | 2 +- ietf/liaisons/mails.py | 2 +- ietf/liaisons/urls.py | 2 +- ietf/mailinglists/urls.py | 6 ++-- ietf/meeting/feeds.py | 2 +- ietf/release/views.py | 4 +-- ietf/secr/proceedings/proc_utils.py | 2 +- ietf/secr/templates/base_site.html | 2 +- .../templates/includes/proceeding_footer.html | 6 ++-- .../proceedings/interim_directory.html | 2 +- ietf/settings.py | 28 +++++++++---------- ietf/submit/admin.py | 2 +- ietf/submit/parsers/plain_parser.py | 4 +-- ietf/sync/iana.py | 8 +++--- ietf/sync/rfceditor.py | 4 +-- 20 files changed, 47 insertions(+), 47 deletions(-) diff --git a/ietf/community/views.py b/ietf/community/views.py index 0e5672236..87c2a9702 100644 --- a/ietf/community/views.py +++ b/ietf/community/views.py @@ -164,7 +164,7 @@ def _atom_view(request, clist, significant=False): notifications = notifications.filter(listnotification__significant=True) host = request.get_host() - feed_url = 'http://%s%s' % (host, request.get_full_path()) + feed_url = 'https://%s%s' % (host, request.get_full_path()) feed_id = uuid.uuid5(uuid.NAMESPACE_URL, feed_url.encode('utf-8')) title = '%s RSS Feed' % clist.long_name() if significant: diff --git a/ietf/doc/redirect_drafts_urls.py b/ietf/doc/redirect_drafts_urls.py index fba0479f2..b4a85f51a 100644 --- a/ietf/doc/redirect_drafts_urls.py +++ b/ietf/doc/redirect_drafts_urls.py @@ -17,5 +17,5 @@ urlpatterns = patterns('', (r'^(?P[^/]+)/(related/)?$', RedirectView.as_view(url='/doc/%(name)s/')), (r'^wgid/(?P\d+)/$', lambda request, id: HttpResponsePermanentRedirect("/wg/%s/" % get_object_or_404(Group, id=id).acronym)), (r'^wg/(?P[^/]+)/$', RedirectView.as_view(url='/wg/%(acronym)s/')), - (r'^all_id(?:_txt)?.html$', RedirectView.as_view(url='http://www.ietf.org/id/all_id.txt')), + (r'^all_id(?:_txt)?.html$', RedirectView.as_view(url='https://www.ietf.org/id/all_id.txt')), ) diff --git a/ietf/doc/redirect_idtracker_urls.py b/ietf/doc/redirect_idtracker_urls.py index df7d21d17..3a8e7bc85 100644 --- a/ietf/doc/redirect_idtracker_urls.py +++ b/ietf/doc/redirect_idtracker_urls.py @@ -3,7 +3,7 @@ from django.views.generic import RedirectView urlpatterns = patterns('', (r'^help/(?:sub)?state/(?:\d+/)?$', RedirectView.as_view(url='/doc/help/state/draft-iesg/')), - (r'^help/evaluation/$', RedirectView.as_view(url='http://www.ietf.org/iesg/voting-procedures.html')), + (r'^help/evaluation/$', RedirectView.as_view(url='https://www.ietf.org/iesg/voting-procedures.html')), (r'^status/$', RedirectView.as_view(url='/doc/iesg/')), (r'^status/last-call/$', RedirectView.as_view(url='/doc/iesg/last-call/')), (r'^rfc0*(?P\d+)/$', RedirectView.as_view(url='/doc/rfc%(rfc_number)s/')), diff --git a/ietf/doc/utils.py b/ietf/doc/utils.py index 4be8a5efb..d7d49fa83 100644 --- a/ietf/doc/utils.py +++ b/ietf/doc/utils.py @@ -239,7 +239,7 @@ def add_links_in_new_revision_events(doc, events, diff_revisions): full_url = diff_url = diff_urls[(e.doc.name, e.rev)] if doc.type_id in "draft": # work around special diff url for drafts - full_url = "http://tools.ietf.org/id/" + diff_url + ".txt" + full_url = "https://tools.ietf.org/id/" + diff_url + ".txt" # build links links = r'\1' % full_url @@ -247,7 +247,7 @@ def add_links_in_new_revision_events(doc, events, diff_revisions): links += "" if prev != None: - links += ' (diff from previous)' % (settings.RFCDIFF_PREFIX, urllib.quote(prev, safe="~"), urllib.quote(diff_url, safe="~")) + links += ' (diff from previous)' % (settings.RFCDIFF_PREFIX, urllib.quote(prev, safe="~"), urllib.quote(diff_url, safe="~")) # replace the bold filename part e.desc = re.sub(r"(.+-[0-9][0-9].txt)", links, e.desc) diff --git a/ietf/doc/views_doc.py b/ietf/doc/views_doc.py index 965f6ad50..06d6e4188 100644 --- a/ietf/doc/views_doc.py +++ b/ietf/doc/views_doc.py @@ -179,7 +179,7 @@ def document_main(request, name, rev=None): possible_types = ["txt", "pdf", "ps"] found_types = [t for t in possible_types if os.path.exists(base_path + t)] - base = "http://www.rfc-editor.org/rfc/" + base = "https://www.rfc-editor.org/rfc/" file_urls = [] for t in found_types: @@ -190,7 +190,7 @@ def document_main(request, name, rev=None): file_urls.append(("pdf", base + "pdfrfc/" + name + ".txt.pdf")) if "txt" in found_types: - file_urls.append(("html", "http://tools.ietf.org/html/" + name)) + file_urls.append(("html", "https://tools.ietf.org/html/" + name)) if not found_types: content = "This RFC is not currently available online." @@ -209,10 +209,10 @@ def document_main(request, name, rev=None): possible_types = ["pdf", "xml", "ps"] found_types = ["txt"] + [t for t in possible_types if os.path.exists(base_path + t)] - tools_base = "http://tools.ietf.org/" + tools_base = "https://tools.ietf.org/" if doc.get_state_slug() == "active": - base = "http://www.ietf.org/id/" + base = "https://www.ietf.org/id/" else: base = tools_base + "id/" diff --git a/ietf/iesg/urls.py b/ietf/iesg/urls.py index bacb79b63..b534d4ed0 100644 --- a/ietf/iesg/urls.py +++ b/ietf/iesg/urls.py @@ -36,7 +36,7 @@ from django.conf.urls import patterns from django.views.generic import RedirectView urlpatterns = patterns('', - (r'^telechat/.*$', RedirectView.as_view(url='http://www.ietf.org/iesg/minutes.html')), + (r'^telechat/.*$', RedirectView.as_view(url='https://www.ietf.org/iesg/minutes.html')), (r'^ann/(?:ind|new|prev)/$', RedirectView.as_view(url="/iesg/decisions/", permanent=True )), (r'^telechatdates/$', RedirectView.as_view(url='/admin/iesg/telechatdate/')), diff --git a/ietf/liaisons/mails.py b/ietf/liaisons/mails.py index 3af748db5..f2d9b9a89 100644 --- a/ietf/liaisons/mails.py +++ b/ietf/liaisons/mails.py @@ -30,7 +30,7 @@ def notify_pending_by_email(request, liaison): # Broken: this does not find the list of approvers for the sending body # For now, we are sending to statements@ietf.org so the Secretariat can nudge - # Bug 880: http://trac.tools.ietf.org/tools/ietfdb/ticket/880 + # Bug 880: https://trac.tools.ietf.org/tools/ietfdb/ticket/880 # # from ietf.liaisons.utils import IETFHM # diff --git a/ietf/liaisons/urls.py b/ietf/liaisons/urls.py index a519e9ad9..732ee951c 100644 --- a/ietf/liaisons/urls.py +++ b/ietf/liaisons/urls.py @@ -8,7 +8,7 @@ urlpatterns = patterns('', url(r'^help/fields/$', TemplateView.as_view(template_name='liaisons/field_help.html'), name="liaisons_field_help"), (r'^help/from_ietf/$', TemplateView.as_view(template_name='liaisons/guide_from_ietf.html')), (r'^help/to_ietf/$', TemplateView.as_view(template_name='liaisons/guide_to_ietf.html')), - (r'^managers/$', RedirectView.as_view(url='http://www.ietf.org/liaison/managers.html')), + (r'^managers/$', RedirectView.as_view(url='https://www.ietf.org/liaison/managers.html')), ) urlpatterns += patterns('ietf.liaisons.views', diff --git a/ietf/mailinglists/urls.py b/ietf/mailinglists/urls.py index a5c021b9f..3f6af28ca 100644 --- a/ietf/mailinglists/urls.py +++ b/ietf/mailinglists/urls.py @@ -5,7 +5,7 @@ from django.views.generic import RedirectView urlpatterns = patterns('', (r'^wg/$', 'ietf.mailinglists.views.groups'), - (r'^nonwg/$', RedirectView.as_view(url='http://www.ietf.org/list/nonwg.html')), - (r'^nonwg/update/$', RedirectView.as_view(url='http://www.ietf.org/list/nonwg.html')), - (r'^request/$', RedirectView.as_view(url='http://www.ietf.org/list/request.html')), + (r'^nonwg/$', RedirectView.as_view(url='https://www.ietf.org/list/nonwg.html')), + (r'^nonwg/update/$', RedirectView.as_view(url='https://www.ietf.org/list/nonwg.html')), + (r'^request/$', RedirectView.as_view(url='https://www.ietf.org/list/request.html')), ) diff --git a/ietf/meeting/feeds.py b/ietf/meeting/feeds.py index 32a9f1140..1366da74f 100644 --- a/ietf/meeting/feeds.py +++ b/ietf/meeting/feeds.py @@ -11,7 +11,7 @@ class LatestMeetingMaterialFeed(Feed): feed_type = Atom1Feed link = "/meeting/" language = "en" - base_url = "http://www3.ietf.org/proceedings/" + base_url = "https://www.ietf.org/proceedings/" def items(self): objs = [] diff --git a/ietf/release/views.py b/ietf/release/views.py index 825d6e1d2..1a4b256a9 100644 --- a/ietf/release/views.py +++ b/ietf/release/views.py @@ -12,9 +12,9 @@ import changelog def trac_links(text): # changeset links - text = re.sub(r'\[(\d+)\]', r'[\1]', text) + text = re.sub(r'\[(\d+)\]', r'[\1]', text) # issue links - text = re.sub(r'#(\d+)', r'#\1', text) + text = re.sub(r'#(\d+)', r'#\1', text) return text diff --git a/ietf/secr/proceedings/proc_utils.py b/ietf/secr/proceedings/proc_utils.py index bc7fe2ac5..ad5ef03c1 100644 --- a/ietf/secr/proceedings/proc_utils.py +++ b/ietf/secr/proceedings/proc_utils.py @@ -50,7 +50,7 @@ def check_audio_files(group,meeting): filename = 'ietf{}-{}-{}-*'.format(meeting.number,room,time) path = os.path.join(settings.MEETING_RECORDINGS_DIR,'ietf{}'.format(meeting.number),filename) for file in glob.glob(path): - url = 'http://www.ietf.org/audio/ietf{}/{}'.format(meeting.number,os.path.basename(file)) + url = 'https://www.ietf.org/audio/ietf{}/{}'.format(meeting.number,os.path.basename(file)) doc = Document.objects.filter(external_url=url).first() if not doc: create_recording(session,meeting,group,url) diff --git a/ietf/secr/templates/base_site.html b/ietf/secr/templates/base_site.html index 92ea7c4d2..2d473be59 100644 --- a/ietf/secr/templates/base_site.html +++ b/ietf/secr/templates/base_site.html @@ -32,7 +32,7 @@ {% endblock %} diff --git a/ietf/secr/templates/includes/proceeding_footer.html b/ietf/secr/templates/includes/proceeding_footer.html index 7c93ac210..20634945b 100644 --- a/ietf/secr/templates/includes/proceeding_footer.html +++ b/ietf/secr/templates/includes/proceeding_footer.html @@ -1,8 +1,8 @@ diff --git a/ietf/secr/templates/proceedings/interim_directory.html b/ietf/secr/templates/proceedings/interim_directory.html index d0aeaea76..0dacf0404 100644 --- a/ietf/secr/templates/proceedings/interim_directory.html +++ b/ietf/secr/templates/proceedings/interim_directory.html @@ -13,7 +13,7 @@ {% for meeting in meetings %} {{ meeting.date }} - {{ meeting.group.acronym }} + {{ meeting.group.acronym }} {% if meeting.agenda %} Agenda {% else %} diff --git a/ietf/settings.py b/ietf/settings.py index 5b7c43a59..f20d4a670 100644 --- a/ietf/settings.py +++ b/ietf/settings.py @@ -276,8 +276,8 @@ INTERNAL_IPS = ( ) # no slash at end -IDTRACKER_BASE_URL = "http://datatracker.ietf.org" -RFCDIFF_PREFIX = "//www.ietf.org/rfcdiff" +IDTRACKER_BASE_URL = "https://datatracker.ietf.org" +RFCDIFF_PREFIX = "https://www.ietf.org/rfcdiff" # Valid values: # 'production', 'test', 'development' @@ -352,22 +352,22 @@ INTERNET_DRAFT_ARCHIVE_DIR = '/a/www/www6s/draft-archive' MEETING_RECORDINGS_DIR = '/a/www/audio' # Mailing list info URL for lists hosted on the IETF servers -MAILING_LIST_INFO_URL = "//www.ietf.org/mailman/listinfo/%(list_addr)s" +MAILING_LIST_INFO_URL = "https://www.ietf.org/mailman/listinfo/%(list_addr)s" # Ideally, more of these would be local -- but since we don't support # versions right now, we'll point to external websites DOC_HREFS = { - "charter": "//www.ietf.org/charter/{doc.name}-{doc.rev}.txt", - "draft": "//www.ietf.org/archive/id/{doc.name}-{doc.rev}.txt", - "slides": "//www.ietf.org/slides/{doc.name}-{doc.rev}", - "conflrev": "//www.ietf.org/cr/{doc.name}-{doc.rev}.txt", - "statchg": "//www.ietf.org/sc/{doc.name}-{doc.rev}.txt", + "charter": "https://www.ietf.org/charter/{doc.name}-{doc.rev}.txt", + "draft": "https://www.ietf.org/archive/id/{doc.name}-{doc.rev}.txt", + "slides": "https://www.ietf.org/slides/{doc.name}-{doc.rev}", + "conflrev": "https://www.ietf.org/cr/{doc.name}-{doc.rev}.txt", + "statchg": "https://www.ietf.org/sc/{doc.name}-{doc.rev}.txt", } MEETING_DOC_HREFS = { "agenda": "/meeting/{meeting}/agenda/{doc.group.acronym}/", - "minutes": "//www.ietf.org/proceedings/{meeting}/minutes/{doc.external_url}", - "slides": "//www.ietf.org/proceedings/{meeting}/slides/{doc.external_url}", + "minutes": "https://www.ietf.org/proceedings/{meeting}/minutes/{doc.external_url}", + "slides": "https://www.ietf.org/proceedings/{meeting}/slides/{doc.external_url}", "recording": "{doc.external_url}", } @@ -393,14 +393,14 @@ IANA_APPROVE_EMAIL = "drafts-approval@icann.org" # Put real password in settings_local.py IANA_SYNC_PASSWORD = "secret" IANA_SYNC_CHANGES_URL = "https://datatracker.iana.org:4443/data-tracker/changes" -IANA_SYNC_PROTOCOLS_URL = "http://www.iana.org/protocols/" +IANA_SYNC_PROTOCOLS_URL = "https://www.iana.org/protocols/" RFC_TEXT_RSYNC_SOURCE="ftp.rfc-editor.org::rfcs-text-only" RFC_EDITOR_SYNC_PASSWORD="secret" -RFC_EDITOR_SYNC_NOTIFICATION_URL = "http://www.rfc-editor.org/parser/parser.php" -RFC_EDITOR_QUEUE_URL = "http://www.rfc-editor.org/queue2.xml" -RFC_EDITOR_INDEX_URL = "http://www.rfc-editor.org/rfc/rfc-index.xml" +RFC_EDITOR_SYNC_NOTIFICATION_URL = "https://www.rfc-editor.org/parser/parser.php" +RFC_EDITOR_QUEUE_URL = "https://www.rfc-editor.org/queue2.xml" +RFC_EDITOR_INDEX_URL = "https://www.rfc-editor.org/rfc/rfc-index.xml" # Liaison Statement Tool settings LIAISON_UNIVERSAL_FROM = 'Liaison Statement Management Tool ' diff --git a/ietf/submit/admin.py b/ietf/submit/admin.py index 63661cc6b..740fb80cf 100644 --- a/ietf/submit/admin.py +++ b/ietf/submit/admin.py @@ -19,7 +19,7 @@ class SubmissionAdmin(admin.ModelAdmin): def draft_link(self, instance): if instance.state_id == "posted": - return '%s' % (instance.name, instance.rev, instance.name) + return '%s' % (instance.name, instance.rev, instance.name) else: return instance.name draft_link.allow_tags = True diff --git a/ietf/submit/parsers/plain_parser.py b/ietf/submit/parsers/plain_parser.py index fb1e4c723..2c1656e9f 100644 --- a/ietf/submit/parsers/plain_parser.py +++ b/ietf/submit/parsers/plain_parser.py @@ -61,10 +61,10 @@ class PlainParser(FileParser): if extra_chars: if len(extra_chars) == 1: self.parsed_info.add_error((u'The name contains a disallowed character: %s ' % (', '.join(set(extra_chars))).decode('ascii','replace')) + - u'(see http://www.ietf.org/id-info/guidelines.html#naming for details).') + u'(see https://www.ietf.org/id-info/guidelines.html#naming for details).') else: self.parsed_info.add_error((u'The name contains disallowed characters: %s ' % (', '.join(set(extra_chars))).decode('ascii','replace')) + - u'(see http://www.ietf.org/id-info/guidelines.html#naming for details).') + u'(see https://www.ietf.org/id-info/guidelines.html#naming for details).') match_revision = revisionre.match(name) if match_revision: self.parsed_info.metadata.rev = match_revision.group(1) diff --git a/ietf/sync/iana.py b/ietf/sync/iana.py index c75c4b17f..0e70e0d92 100644 --- a/ietf/sync/iana.py +++ b/ietf/sync/iana.py @@ -15,8 +15,8 @@ from ietf.person.models import Person from ietf.utils.timezone import local_timezone_to_utc, email_time_to_local_timezone, utc_to_local_timezone -#PROTOCOLS_URL = "http://www.iana.org/protocols/" -#CHANGES_URL = "http://datatracker.dev.icann.org:8080/data-tracker/changes" +#PROTOCOLS_URL = "https://www.iana.org/protocols/" +#CHANGES_URL = "https://datatracker.dev.icann.org:8080/data-tracker/changes" def fetch_protocol_page(url): f = urllib2.urlopen(settings.IANA_SYNC_PROTOCOLS_URL) @@ -89,8 +89,8 @@ def parse_changes_json(text): # a little bit of cleaning i["doc"] = i["doc"].strip() - if i["doc"].startswith("http://www.ietf.org/internet-drafts/"): - i["doc"] = i["doc"][len("http://www.ietf.org/internet-drafts/"):] + if i["doc"].startswith("https://www.ietf.org/internet-drafts/"): + i["doc"] = i["doc"][len("https://www.ietf.org/internet-drafts/"):] # make sure we process oldest entries first changes.sort(key=lambda c: c["time"]) diff --git a/ietf/sync/rfceditor.py b/ietf/sync/rfceditor.py index 0c4535f8c..d99718d2b 100644 --- a/ietf/sync/rfceditor.py +++ b/ietf/sync/rfceditor.py @@ -18,8 +18,8 @@ from ietf.person.models import Person from ietf.utils.log import log from ietf.utils.mail import send_mail_text -#QUEUE_URL = "http://www.rfc-editor.org/queue2.xml" -#INDEX_URL = "http://www.rfc-editor.org/rfc/rfc-index.xml" +#QUEUE_URL = "https://www.rfc-editor.org/queue2.xml" +#INDEX_URL = "https://www.rfc-editor.org/rfc/rfc-index.xml" #POST_APPROVED_DRAFT_URL = "https://www.rfc-editor.org/sdev/jsonexp/jsonparser.php" MIN_QUEUE_RESULTS = 10