Skip to content

Commit

Permalink
Merge pull request #1706 from codeforpdx/kent-insecure-mode
Browse files Browse the repository at this point in the history
Disable SSL verification temporarily
  • Loading branch information
KentShikama authored Jul 27, 2023
2 parents a2c0672 + 7e6cc50 commit ef46079
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 6 deletions.
8 changes: 4 additions & 4 deletions src/backend/expungeservice/crawler/crawler.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ class Crawler:
def attempt_login(session: Session, username, password) -> str:
url = URL.login_url()
payload = Payload.login_payload(username, password)
response = session.post(url, data=payload)
response = session.post(url, data=payload, verify=False)
if Crawler._succeed_login(response):
return response.text
elif "Oregon eCourt is temporarily unavailable due to maintenance" in response.text:
Expand All @@ -47,7 +47,7 @@ def attempt_login(session: Session, username, password) -> str:
@staticmethod
def fetch_link(link: str, session: Session = None):
if session:
response = session.get(link)
response = session.get(link, verify=False)
Crawler.cached_links[link] = response
return response
else:
Expand Down Expand Up @@ -78,7 +78,7 @@ def search(
@staticmethod
def _search_record(session: Session, node_response, search_url, first_name, last_name, middle_name, birth_date):
payload = Crawler.__extract_payload(node_response, last_name, first_name, middle_name, birth_date)
response = session.post(search_url, data=payload, timeout=30)
response = session.post(search_url, data=payload, timeout=30, verify=False)
record_parser = RecordParser()
record_parser.feed(response.text)
return record_parser
Expand Down Expand Up @@ -110,7 +110,7 @@ def _fetch_search_page(session, url, login_response):
node_parser = NodeParser()
node_parser.feed(login_response)
payload = {"NodeID": node_parser.node_id, "NodeDesc": "All+Locations"}
return session.post(url, data=payload)
return session.post(url, data=payload, verify=False)

@staticmethod
def _parse_case(session: Session, case: CaseSummary):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ exports[`renders correctly 1`] = `
className="db mb1 fw6"
htmlFor="password"
>
Password
Password (WARNING: we have temporarily disabled security - we are working hard to get it restored - proceed at your own risk of getting your password stolen)
</label>
<input
aria-invalid={false}
Expand Down
4 changes: 3 additions & 1 deletion src/frontend/src/components/OeciLogin/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,9 @@ class OeciLogin extends React.Component<State> {
/>
</div>
<label htmlFor="password" className="db mb1 fw6">
Password
Password (WARNING: we have temporarily disabled security
- we are working hard to get it restored - proceed at
your own risk of getting your password stolen)
</label>
<input
id="password"
Expand Down

0 comments on commit ef46079

Please sign in to comment.