No description, website, or topics provided.
Java
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
res
src/com
.classpath
.gitignore
.project
AndroidManifest.xml
LICENSE
README.markdown
proguard.cfg
project.properties

README.markdown

PolicyServer

This is a sample application that shows how to provide URL policy for a given URL. On running this application, it takes the url sent by the client app, verifies it and responds back with the URL policy. If the url contains ".xxx", the policy will recommend to block the url.

IURLPolicyService.aidl

This contains IURLPolicyService.aidl, the Android Interface Definition File (AIDL) file for the URL policy. You can copy this file to your project's /src folder to generate the IBinder interface.

Constants.java

This class contains the constants used by the application. You can copy this file or its contents to create the request bundle and process the response bundle.

URLPolicyService.java

Sample class that shows how to handle the URL sent by the client app and send a response

AndroidManifest.xml

The service should declare that the client apps requesting the policy should have this permission. ...

The sample server code declares the permission "android.permission.READ_URL_POLICY" here. If the Android system supports this permission, it should not be here.

Running the application

Import the project to eclipse as an Android project. You can build the project and export as an Android application. This can run both on device and emulator. Install the PolicyClient app also to see it working end to end.