PHPackages                             tuupola/corelocation - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. tuupola/corelocation

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

tuupola/corelocation
====================

PHP implementation of Apple location services protocol

0.1.0(9y ago)3602MITPHPPHP ^5.6 || ^7.0

Since May 13Pushed 8y ago1 watchersCompare

[ Source](https://github.com/tuupola/corelocation)[ Packagist](https://packagist.org/packages/tuupola/corelocation)[ Docs](https://github.com/tuupola/corelocation)[ RSS](/packages/tuupola-corelocation/feed)WikiDiscussions master Synced 3d ago

READMEChangelogDependencies (4)Versions (2)Used By (0)

Core Location
=============

[](#core-location)

[![Latest Version](https://camo.githubusercontent.com/1c781eac36cc45656f5ba2ebe29abda6fe50e182d5e229c98de27097c0b16d4b/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f747575706f6c612f636f72656c6f636174696f6e2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/tuupola/corelocation)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE.md)[![Build Status](https://camo.githubusercontent.com/dc7084579605bd82f1312f6ebfe4a1f2816a3e0a9e8cb4cafe1f8e40e7343410/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f747575706f6c612f636f72656c6f636174696f6e2f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/tuupola/corelocation)[![Coverage](https://camo.githubusercontent.com/3339d1d6ca4efa53deca3b85d8f9d540bc86ffca409694538eaba45adbc0e847/687474703a2f2f696d672e736869656c64732e696f2f636f6465636f762f632f6769746875622f747575706f6c612f636f72656c6f636174696f6e2e7376673f7374796c653d666c61742d737175617265)](https://codecov.io/github/tuupola/corelocation)

Proof of concept PHP implementation of [Apple location services protocol](https://appelsiini.net/2017/reverse-engineering-location-services/). This library does **not** do any actual requests. It is used only for creating and parsing requests and responses.

Install
-------

[](#install)

Install the library using [Composer](https://getcomposer.org/).

```
$ composer require tuupola/corelocation
```

Usage
-----

[](#usage)

### Request

[](#request)

Request class returns a binary string. It is up to reader to figure out what to do with it.

```
require __DIR__ . "/vendor/autoload.php";

use Tuupola\CoreLocation\Request;

$request = new Request(["aa:aa:aa:aa:aa:aa", "bb:bb:bb:bb:bb:bb"]);
$hex = bin2hex($request->body());
print_r(str_split($hex, 64));

/*
Array
(
    [0] => 00010005656e5f55530013636f6d2e6170706c652e6c6f636174696f6e64000c
    [1] => 382e342e312e313248333231000000010000002c12130a1161613a61613a6161
    [2] => 3a61613a61613a616112130a1162623a62623a62623a62623a62623a62622064
)
*/
```

### Response

[](#response)

Respons class can be used for unserializing the response. It is up to reader to figure out how to get a response.

```
require __DIR__ . "/vendor/autoload.php";

use Tuupola\CoreLocation\Response;

$data = file_get_contents("response.bin");
$response = (new Response)->fromString($data);

foreach ($response as $router) {
    print_r($router);
}

/*
Array
(
    [mac] => cc:cc:cc:cc:cc:cc
    [latitude] => 27.98785,
    [longitude] => 86.9228374
    [accuracy] => 42
    [channel] => 10
)
...
*/
```

Testing
-------

[](#testing)

You can run tests either manually or automatically on every code change. Automatic tests require [entr](http://entrproject.org/) to work.

```
$ make test
```

```
$ brew install entr
$ make watch
```

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

Security
--------

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity48

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 87.5% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

3289d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/3325405a7d8a43bc40dd0e760a4b7f268fba32a7150cf0327f64f13d1661df0b?d=identicon)[tuupola](/maintainers/tuupola)

---

Top Contributors

[![tuupola](https://avatars.githubusercontent.com/u/21913?v=4)](https://github.com/tuupola "tuupola (21 commits)")[![peter279k](https://avatars.githubusercontent.com/u/9021747?v=4)](https://github.com/peter279k "peter279k (3 commits)")

---

Tags

corelocationgeopositionwifiwlocwifigeopositioncorelocation

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/tuupola-corelocation/health.svg)

```
[![Health](https://phpackages.com/badges/tuupola-corelocation/health.svg)](https://phpackages.com/packages/tuupola-corelocation)
```

###  Alternatives

[alibaba/nacos

阿里巴巴nacos配置中心php客户端

19340.8k1](/packages/alibaba-nacos)[hasanmertermis/milvus-php-client

Milvus 2 Grpc Php Client

142.1k](/packages/hasanmertermis-milvus-php-client)[davidrjenni/scip-php

SCIP Code Intelligence Protocol (SCIP) indexer for PHP

161.2k](/packages/davidrjenni-scip-php)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
