Git Product home page Git Product logo

virtuallocation-1's Introduction

VirtualLocation(UI仿共享单车OFO)

博客主页

对Android程序进行虚拟定位,可修改微信、QQ、陌陌以及一些打卡APP等软件,随意切换手机所处位置!(喜欢的给一个star, 有帮助的给一个fork, 欢迎Star和Fork ^_^)

下载 话不多说,试玩应用先。

效果预览

主页


微信虚拟定位演示

1、打开本程序,选择好要穿越的地点,确认穿越即可!
Alt textAlt text

2、再打开微信,这里演示在朋友圈发位置状态,如下:
Alt text


钉钉虚拟定位打卡演示


原理

本程序有两种方式可以实现虚拟定位:

  1. 通过ADB模拟定位功能
  2. 通过Hook修改获取经纬度API的值 (必需安装Xposed以及ROOT)

程序代码设计流程图如下:
Alt text

第一种方式主要是是通过ADB模拟定位功能,再开启线程,不断的更新LocationManager的经纬度值,即可是实现定位模拟定位

	mMockThread = new Thread(new Runnable() {
                @Override
                public void run() {
                    while (true) {
                        try {
                            Thread.sleep(500);
                            if (!hasAddTestProvider) {
                                Log.d("xqf", "针对Android6.0+系统,需要单独把程序调加到ADB模拟定位服务中");
                                continue;
                            }
                            setLocation(LocationUtil.mLatitude, LocationUtil.mLongitude);
                            Log.d("xqf", "setLocation240=latitude:" + mLatitude + "?longitude:" + mLongitude);
                        } catch (Exception e) {
                            e.printStackTrace();
                        }
                 }
                }
            });
            mMockThread.start();

第二种方式主要是采用Hook修改系统API。目前很多程序都调用了isFromMockProvider方法来检测用户是否打开了ADB模拟定位功能,所以我又采用了Hook方式,就不怕不能虚拟定位了,具体如何Hook,可以看我的一篇博客:基于Xposed框架Hook定位功能来破解QQ的LBS红包


测试

在Android测试机 分别是 魅蓝2、华为、SCL-TL00、Vivo xs1、红米note运行正常

版本

v1.0

完成了通过ADB模拟定位功能来虚拟定位,但是新版的一些程序都做了ADB模拟定位检测,所以现在很多新版本程序都不行了

v1.1

完善了通过Hook修改虚拟定位API,提高程序的兼容性和可行性,但同时也必须Android设备要ROOT

issue

如果程序运行有什么问题,可以先查看Issues中的问题回答,这样我就不用重复回答大家的问题了,之前太多人加QQ问问题,工作有点忙实在是来不及一一回复(注:Issues在本网页顶部菜单栏上)

Email:[email protected]

License

Copyright 2016 xuqingfu

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

virtuallocation-1's People

Contributors

littlerich avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.