mirror of
https://github.com/ail-project/ail-framework.git
synced 2024-11-27 00:07:16 +00:00
Merge branch 'master' into base64
This commit is contained in:
commit
98d0235fc3
3 changed files with 9 additions and 5 deletions
|
@ -93,7 +93,7 @@ if __name__ == '__main__':
|
||||||
|
|
||||||
try:
|
try:
|
||||||
#feeder_name = ( complete_paste.replace("archive/","") ).split("/")[0]
|
#feeder_name = ( complete_paste.replace("archive/","") ).split("/")[0]
|
||||||
feeder_name, paste_name = complete_paste.split('>')
|
feeder_name, paste_name = complete_paste.split('>>')
|
||||||
feeder_name.replace(" ","")
|
feeder_name.replace(" ","")
|
||||||
paste_name = complete_paste
|
paste_name = complete_paste
|
||||||
|
|
||||||
|
|
|
@ -29,8 +29,12 @@ def create_paste(uuid, paste_content, ltags, ltagsgalaxies, name):
|
||||||
addError(uuid, 'File: ' + save_path + ' already exist in submitted pastes')
|
addError(uuid, 'File: ' + save_path + ' already exist in submitted pastes')
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
|
try:
|
||||||
gzipencoded = gzip.compress(paste_content)
|
gzipencoded = gzip.compress(paste_content)
|
||||||
gzip64encoded = base64.standard_b64encode(gzipencoded).decode()
|
gzip64encoded = base64.standard_b64encode(gzipencoded).decode()
|
||||||
|
except:
|
||||||
|
abord_file_submission(uuid, "file error")
|
||||||
|
continue
|
||||||
|
|
||||||
# send paste to Global module
|
# send paste to Global module
|
||||||
relay_message = "{0} {1}".format(save_path, gzip64encoded)
|
relay_message = "{0} {1}".format(save_path, gzip64encoded)
|
||||||
|
@ -219,7 +223,7 @@ if __name__ == "__main__":
|
||||||
abord_file_submission(uuid, "file error")
|
abord_file_submission(uuid, "file error")
|
||||||
continue
|
continue
|
||||||
r_serv_log_submit.set(uuid + ':nb_total', 1)
|
r_serv_log_submit.set(uuid + ':nb_total', 1)
|
||||||
create_paste(uuid, content, ltags, ltagsgalaxies, uuid)
|
create_paste(uuid, content.encode(), ltags, ltagsgalaxies, uuid)
|
||||||
remove_submit_uuid(uuid)
|
remove_submit_uuid(uuid)
|
||||||
|
|
||||||
else:
|
else:
|
||||||
|
|
|
@ -187,7 +187,7 @@
|
||||||
<span class="label-icon">ERROR </span>
|
<span class="label-icon">ERROR </span>
|
||||||
<i class="fa fa-times"></i>
|
<i class="fa fa-times"></i>
|
||||||
</button>
|
</button>
|
||||||
<a class="btn btn-tags pull-left hidden" href="{{ url_for('Tags.get_tagged_paste') }}?ltags=submitted" target="_blank" id="submit_result">
|
<a class="btn btn-tags pull-left hidden" href="{{ url_for('Tags.get_tagged_paste') }}?ltags=infoleak:submission="manual"" target="_blank" id="submit_result">
|
||||||
<span class="label-icon">Submitted Pastes </span>
|
<span class="label-icon">Submitted Pastes </span>
|
||||||
<i class="fa fa-paper-plane fa-2x"></i>
|
<i class="fa fa-paper-plane fa-2x"></i>
|
||||||
</a>
|
</a>
|
||||||
|
|
Loading…
Reference in a new issue