随机生成 imsi imei mac
来源:互联网 发布:java高并发程序设计 编辑:程序博客网 时间:2024/06/05 18:44
http://blog.csdn.net/argonwu/article/details/42971909
private static String getIMEI() {// calculator IMEI
int r1 = 1000000 + new java.util.Random().nextInt(9000000);int r2 = 1000000 + new java.util.Random().nextInt(9000000);
String input = r1 + "" + r2;
char[] ch = input.toCharArray();
int a = 0, b = 0;
for (int i = 0; i < ch.length; i++) {
int tt = Integer.parseInt(ch[i] + "");
if (i % 2 == 0) {
a = a + tt;
} else {
int temp = tt * 2;
b = b + temp / 10 + temp % 10;
}
}
int last = (a + b) % 10;
if (last == 0) {
last = 0;
} else {
last = 10 - last;
}
return input + last;
}
private static String getImsi() {
// 460022535025034
String title = "4600";
int second = 0;
do {
second = new java.util.Random().nextInt(8);
} while (second == 4);
int r1 = 10000 + new java.util.Random().nextInt(90000);
int r2 = 10000 + new java.util.Random().nextInt(90000);
return title + "" + second + "" + r1 + "" + r2;
}
private static String getMac(){
char[] char1 = "abcdef".toCharArray();
char[] char2 = "0123456789".toCharArray();
StringBuffer mBuffer = new StringBuffer();
for (int i = 0; i < 6; i++) {
int t = new java.util.Random().nextInt(char1.length);
int y = new java.util.Random().nextInt(char2.length);
int key = new java.util.Random().nextInt(2);
if (key ==0) {
mBuffer.append(char2[y]).append(char1[t]);
}else {
mBuffer.append(char1[t]).append(char2[y]);
}
if (i!=5) {
mBuffer.append(":");
}
}
return mBuffer.toString();
}
0 0
- 随机生成imei imsi mac
- 随机生成 imsi imei mac
- imsi imei
- imei imsi
- android IMEI和IMSI,mac地址的获取
- IMSI 和 IMEI
- IMEI、IMSI相关源代码
- 获得手机IMEI IMSI
- Android IMSI和IMEI
- C#获取IMEI,IMSI
- Android IMSI和IMEI
- IMEI && IMSI && APN设置
- 获取手机imsi,imei
- IMSI、IMEI、ESN、MEID
- IMEI & IMSI & TAPI
- android 获得IMSI / IMEI
- IMEI和IMSI区别
- 获取手机IMSI IMEI
- NSURLSession简介
- Socket 通信原理(Android客户端和服务器以TCP&&UDP方式互通)
- 深copy,浅copy
- asterisk realtime更新错误
- java当中的定时器的4种使用方式
- 随机生成 imsi imei mac
- eclipse:关于The connection to adb is down, and a severe error has occured.
- 利用redis + lua解决抢红包高并发的问题
- centos7安装nginx
- 挑战愈艰巨,胜利愈辉煌。 – 尼克·胡哲
- 如何做到让各大搜索引擎收录你的网站!
- 【Java并发编程】之十五:并发编程中实现内存可见的两种方法比较:加锁和volatile变量
- (二)洞悉linux下的Netfilter&iptables:内核中的ip_tables小觑
- Java中使用redis的完整实例及常用命令