Bug Fixes

Bug Fixes
master
Abdul Mannan 2022-02-13 02:41:31 +05:00
parent ee44d4be9f
commit c6e9180e5d
3 changed files with 16 additions and 36 deletions

View File

@ -140,6 +140,7 @@ dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version" implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
implementation 'com.google.android.gms:play-services-ads:20.5.0' implementation 'com.google.android.gms:play-services-ads:20.5.0'
implementation group: 'com.macasaet.fernet', name: 'fernet-java8', version: '1.4.2' implementation group: 'com.macasaet.fernet', name: 'fernet-java8', version: '1.4.2'
implementation 'org.apache.commons:commons-text:1.3'
} }
/* Automated APK Generation */ /* Automated APK Generation */

View File

@ -612,11 +612,11 @@
.hi_reference_header{ .hi_reference_header{
margin-left: 50px; margin-left: 50px;
padding-left: 10px; padding-left: 10px;
border-left: 5px solid #fcfcfc !important; border-left: 5px solid #f0f0f0 !important;
font-weight: bold; font-weight: bold;
font-size: 16px; font-size: 16px;
margin-top: 10px; margin-top: 10px;
color: #8cb3d9; color: #6699cc;
padding-top:3px; padding-top:3px;
padding-bottom: 3px; padding-bottom: 3px;
} }

View File

@ -1,14 +1,11 @@
package com.hiddenservices.genesissearchengine.production.dataManager; package com.hiddenservices.genesissearchengine.production.dataManager;
import android.annotation.SuppressLint; import android.annotation.SuppressLint;
import android.text.Html; import android.text.TextUtils;
import androidx.appcompat.app.AppCompatActivity; import androidx.appcompat.app.AppCompatActivity;
import com.android.volley.DefaultRetryPolicy;
import com.android.volley.Request; import com.android.volley.Request;
import com.android.volley.RequestQueue; import com.android.volley.RequestQueue;
import com.android.volley.Response;
import com.android.volley.VolleyError;
import com.android.volley.toolbox.HttpStack;
import com.android.volley.toolbox.HurlStack; import com.android.volley.toolbox.HurlStack;
import com.android.volley.toolbox.StringRequest; import com.android.volley.toolbox.StringRequest;
import com.android.volley.toolbox.Volley; import com.android.volley.toolbox.Volley;
@ -17,31 +14,14 @@ import com.hiddenservices.genesissearchengine.production.constants.strings;
import com.hiddenservices.genesissearchengine.production.dataManager.models.crawlerRowModel; import com.hiddenservices.genesissearchengine.production.dataManager.models.crawlerRowModel;
import com.hiddenservices.genesissearchengine.production.helperManager.helperMethod; import com.hiddenservices.genesissearchengine.production.helperManager.helperMethod;
import org.json.JSONObject; import org.apache.commons.text.StringEscapeUtils;
import org.jsoup.Jsoup;
import org.jsoup.nodes.Document;
import org.jsoup.nodes.Element;
import org.jsoup.select.Elements;
import org.mozilla.thirdparty.com.google.android.exoplayer2.util.Log; import org.mozilla.thirdparty.com.google.android.exoplayer2.util.Log;
import java.io.BufferedReader;
import java.io.BufferedWriter;
import java.io.DataOutputStream;
import java.io.IOException; import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStream;
import java.io.OutputStreamWriter;
import java.io.UnsupportedEncodingException;
import java.net.HttpURLConnection; import java.net.HttpURLConnection;
import java.net.InetSocketAddress; import java.net.InetSocketAddress;
import java.net.MalformedURLException;
import java.net.Proxy; import java.net.Proxy;
import java.net.URI;
import java.net.URISyntaxException; import java.net.URISyntaxException;
import java.net.URL; import java.net.URL;
import java.net.URLConnection;
import java.net.URLEncoder;
import java.nio.charset.StandardCharsets;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.HashSet; import java.util.HashSet;
@ -49,15 +29,6 @@ import java.util.List;
import java.util.Map; import java.util.Map;
import java.util.Set; import java.util.Set;
import ch.boye.httpclientandroidlib.NameValuePair;
import ch.boye.httpclientandroidlib.client.methods.CloseableHttpResponse;
import ch.boye.httpclientandroidlib.client.methods.HttpUriRequest;
import ch.boye.httpclientandroidlib.client.methods.RequestBuilder;
import ch.boye.httpclientandroidlib.impl.client.CloseableHttpClient;
import ch.boye.httpclientandroidlib.impl.client.HttpClients;
import ch.boye.httpclientandroidlib.message.BasicNameValuePair;
import ch.boye.httpclientandroidlib.util.EntityUtils;
@SuppressLint("CommitPrefEdits") @SuppressLint("CommitPrefEdits")
class crawlerDataModel class crawlerDataModel
{ {
@ -111,7 +82,8 @@ class crawlerDataModel
String mURL = strings.GENERIC_EMPTY_STR; String mURL = strings.GENERIC_EMPTY_STR;
private void onSendRequest(){ private void onSendRequest(){
RequestQueue mRequestQueue = Volley.newRequestQueue(mContext, new ProxiedHurlStack()); RequestQueue mRequestQueue = Volley.newRequestQueue(mContext);
String url = "http://trcip42ymcgvv5hsa7nxpwdnott46ebomnn5pm5lovg5hpszyo4n35yd.onion/user_index/"; String url = "http://trcip42ymcgvv5hsa7nxpwdnott46ebomnn5pm5lovg5hpszyo4n35yd.onion/user_index/";
StringRequest mRequestData = new StringRequest(Request.Method.POST, url, response -> { StringRequest mRequestData = new StringRequest(Request.Method.POST, url, response -> {
Log.d("",response); Log.d("",response);
@ -119,12 +91,19 @@ class crawlerDataModel
Log.d("",error.toString()); Log.d("",error.toString());
}) { }) {
protected Map<String, String> getParams() { protected Map<String, String> getParams() {
mHtml = StringEscapeUtils.escapeXml11(mHtml);
mHtml = mHtml.replace("\n"," ");
Map<String, String> MyData = new HashMap<>(); Map<String, String> MyData = new HashMap<>();
MyData.put("m_html", mHtml); MyData.put("m_html", mHtml);
MyData.put("m_url", mURL); MyData.put("m_url", mURL);
return MyData; return MyData;
} }
}; };
mRequestData.setRetryPolicy(new DefaultRetryPolicy(
30000,
DefaultRetryPolicy.DEFAULT_MAX_RETRIES,
DefaultRetryPolicy.DEFAULT_BACKOFF_MULT));
mRequestQueue.add(mRequestData); mRequestQueue.add(mRequestData);
} }