Android relies on a security Provider to provide secure network communications. However, from time to time, vulnerabilities are found in the default security provider. To protect from these vulnerabilities, security provider needs to be updated.
Google Play Services provides a quick way so that you can easily update security provider within your application with just few lines of code, but still there are lots of devices without Google Play Services, you may want to update security provider for those too. Also you may not want to include Google Play Services just for security provider. Here are simple steps to build latest security provider from source.
- Download the AOSP source as mentioned on AOSP site.
- Run envsetup.sh
$ . build.envsetup.sh
- Run lunch, specify the desired architecture. E.g. for arm
$ lunch aosp_arm-user
- Change directory to external/conscrypt
$ cd external/conscrypt
- Run mma, this will build the conscrypt library, the OpenSSL provider used by Android along with its all dependencies. You can specify the number of jobs according to your CPU
$ mma -j8
- Get Java library and Native shared library.
Path for Java library : out/target/common/obj/JAVA_LIBRARIES/conscrypt_unbundled_intermediates/javalib.jar
Path for Native library : out/target/product/generic/obj/lib/libconscrypt_jni.so
- You can change the name of javalib.jar and add it to your build path. To use native library, you have to put it under lib/armeabi directory at the root of your project.
You can easily add this security provider on top of default one with following code :
Security.insertProviderAt(new OpenSSLProvider("Any name"), 1);
An entrance into college leads to an entrance into a new world, so I would consider it as a start of my journey. I was admitted to DTU in August 2013 where I was first exposed to programming. Although at that point I knew what programming was, but completely unaware of how to do it. So I started by learning C first by some online resources. From then, it became a hobby for me to write various programs in C and running it on my PC. Being completely unaware of what real softwares are like, I continued it, learned C++ and started doing some competitive programming. During this time I learned about various data structures and algorithms. This wave continued for nearly 1 year in which I learned about C, C++, data structures, algorithms and solved nearly 150+ programming question on websites like spoj and codechef.
Later my interest in competitive programming started diminishing and I started learning making Android applications(I always wanted to make some applications that other persons can use) where I made some simple android applications like basic calculator, GCM based application for information sharing etc. Since JAVA was in many ways similar to C++, so there was not much problem in shifting to JAVA from C++, but yeah null pointer exceptions was real pain and it was very hard for me to debug them at that time.
I always had an itch to make a game,so after making some android apps I decided to make a game.So after thinking a lot, I came up with an idea and started implementing it using libGDX framework. Making a game was a whole new exprience to me.Now I was working with some real graphics and it changed my whole perspective towards games. So after some real hardwork for nearly 15 days I managed to complete my game. Since I was not good at art from childhood, making graphics for my game was a real challange to me.Also I needed some free graphics which I had to modify according to me which was also quite difficult.But after facing all challanges I finally managed to finish my game and published it on playstore with the title Ball Blast.
Later, for some months I just scrolled through internet to contribute to some open source project(still wanna work with some real projects and learn about how community works) and found about KDE Connect, an awesome project started by Albert Vaca which enables different devices to communicate with each other.It has many plugins like file sharing, mpris, touchpad etc.I started contributing to it by submitting some patches and still working to implement SSL protocol for communication between the devices. The world of open source taught me how to write flexible and readable code and also making changes in existing code without breaking it and making minimal changes. Due to open source I came to know about Git and the real meaning of GitHub(not just a code sharing website), I wish I would have known about it earlier. I also came to know about various other utilities like make, cmake and Qt framework (An awesome framework for making cross platform GUI desktop applications in C++).
So at last here I am writing this blog, which I was trying from a long time. I realised that I have missed some part of my life and writing blog can help me to recover it any time I want. It may also help some fellow developers as I will be sharing some programming tutorials also.
After all this I still don’t know what I like the most, but I came to know that I like learning new things and to work with them.I want to change the world, just haven’t figured out how am I gonna do that but I will.