Enable TLS v1.1/1.2 for KitKat devices
This enables modern TLS versions in the collection browser, the Downloader and the Player. This is neccessary because media.ccc.de rejects all older TLS connection attempts, see issue #2777.
This commit is contained in:
parent
88a6e5981f
commit
c0453065e4
3 changed files with 178 additions and 1 deletions
|
|
@ -72,6 +72,7 @@ import org.schabi.newpipe.util.PeertubeHelper;
|
|||
import org.schabi.newpipe.util.PermissionHelper;
|
||||
import org.schabi.newpipe.util.ServiceHelper;
|
||||
import org.schabi.newpipe.util.StateSaver;
|
||||
import org.schabi.newpipe.util.TLSSocketFactoryCompat;
|
||||
import org.schabi.newpipe.util.ThemeHelper;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
|
@ -108,6 +109,10 @@ public class MainActivity extends AppCompatActivity {
|
|||
protected void onCreate(Bundle savedInstanceState) {
|
||||
if (DEBUG) Log.d(TAG, "onCreate() called with: savedInstanceState = [" + savedInstanceState + "]");
|
||||
|
||||
//enable TLS1.1/1.2 for kitkat devices, to fix download and play for mediaCCC sources
|
||||
if (Build.VERSION.SDK_INT == Build.VERSION_CODES.KITKAT)
|
||||
TLSSocketFactoryCompat.setAsDefault();
|
||||
|
||||
ThemeHelper.setTheme(this, ServiceHelper.getSelectedServiceId(this));
|
||||
|
||||
super.onCreate(savedInstanceState);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue