# Geolocation Problem with Crosswalk and Ionic

**URL:** <https://forum.ionicframework.com/t/geolocation-problem-with-crosswalk-and-ionic/36054>\
**Category:** cordova\
**Created:** [November 1, 2015, 8:17am UTC](https://forum.ionicframework.com/t/geolocation-problem-with-crosswalk-and-ionic/36054 "2015-11-01T08:17:42Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Darmie](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/darmie/32/71340_2.png) [@Darmie](https://forum.ionicframework.com/u/Darmie)\
**Post date:** [November 1, 2015, 8:17am UTC](https://forum.ionicframework.com/t/geolocation-problem-with-crosswalk-and-ionic/36054/1 "2015-11-01T08:17:42Z")

</div>

Hi I am having a problem with geolocation, I tried both the `cordova-plugin-geolocation`and the normal `navigator.geolocation` . None of them worked. I installed Whitelist and used this Meta tag  
`<meta http-equiv="Content-Security-Policy" content="default-src *; script-src 'self' 'unsafe-inline' 'unsafe-eval' *; style-src 'self' 'unsafe-inline' *">` It didn’t work still. I have set the android permissions

`<uses-permission android:name="android.permission.ACCESS_LOCATION_EXTRA_COMMANDS" /> <uses-permission android:name="android.permission.READ_PHONE_STATE" /> <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> <uses-permission android:name="android.permission.ACCESS_WIFI_STATE" /> <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" /> <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />`

With all my efforts so far, Geolocation is not working. This is how I am using Geolocation with ngCordova

`$cordovaGeolocation.getCurrentPosition(posOptions) .then(function (position) { var lat = position.coords.latitude; var long = position.coords.longitude; console.log({lat: lat, long: long}); $scope.$broadcast('isFoundPosition', {lat: lat, lng: long}); // $mdBottomSheet.hide(); }, function (err) { console.log(err); });`

When I checked the logs I am getting this error :  
`11-01 08:59:52.232: E/LocationProvider(8786): Caught security exception while registering for location updates from the system. The application does not have sufficient geolocation permissions.`

What am I doing wrong?

---

<div class="post-metadata">

**Author:** ![Darmie](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/darmie/32/71340_2.png) [@Darmie](https://forum.ionicframework.com/u/Darmie)\
**Post date:** [November 1, 2015, 11:24am UTC](https://forum.ionicframework.com/t/geolocation-problem-with-crosswalk-and-ionic/36054/2 "2015-11-01T11:24:13Z")

</div>

Problem fixed. I had to downgrade from `android-23` to `android-21`
