mirror of https://gitlab.com/bashrc2/epicyon
Receiving POST from lynx
parent
00203624f5
commit
f32d31464a
|
@ -4918,6 +4918,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
users_path = users_path.split('/tags/')[0]
|
users_path = users_path.split('/tags/')[0]
|
||||||
actor_str = self._get_instance_url(calling_domain) + users_path
|
actor_str = self._get_instance_url(calling_domain) + users_path
|
||||||
tag_screen_str = actor_str + '/tags/' + hashtag
|
tag_screen_str = actor_str + '/tags/' + hashtag
|
||||||
|
boundary = None
|
||||||
if ' boundary=' in self.headers['Content-type']:
|
if ' boundary=' in self.headers['Content-type']:
|
||||||
boundary = self.headers['Content-type'].split('boundary=')[1]
|
boundary = self.headers['Content-type'].split('boundary=')[1]
|
||||||
if ';' in boundary:
|
if ';' in boundary:
|
||||||
|
@ -4937,6 +4938,7 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.postreq_busy = False
|
self.server.postreq_busy = False
|
||||||
return
|
return
|
||||||
|
|
||||||
|
if self.headers.get('Content-length'):
|
||||||
length = int(self.headers['Content-length'])
|
length = int(self.headers['Content-length'])
|
||||||
|
|
||||||
# check that the POST isn't too large
|
# check that the POST isn't too large
|
||||||
|
@ -4967,6 +4969,11 @@ class PubServer(BaseHTTPRequestHandler):
|
||||||
self.server.postreq_busy = False
|
self.server.postreq_busy = False
|
||||||
return
|
return
|
||||||
|
|
||||||
|
if not boundary:
|
||||||
|
if b'--LYNX' in post_bytes:
|
||||||
|
boundary = '--LYNX'
|
||||||
|
|
||||||
|
if boundary:
|
||||||
# extract all of the text fields into a dict
|
# extract all of the text fields into a dict
|
||||||
fields = \
|
fields = \
|
||||||
extract_text_fields_in_post(post_bytes, boundary, debug)
|
extract_text_fields_in_post(post_bytes, boundary, debug)
|
||||||
|
|
Loading…
Reference in New Issue