Compare commits

...

2 Commits

Author SHA1 Message Date
Ubujira 66a2d4c2f1
Merge remote-tracking branch 'origin/main' 2022-07-06 00:38:48 +02:00
Ubujira f9bcf2ef4e
ye 2 2022-07-06 00:38:23 +02:00
3 changed files with 24 additions and 5 deletions

View File

@ -2,6 +2,7 @@ plugins {
id 'java'
id 'application'
id "com.github.johnrengelman.shadow" version "7.1.2"
id 'maven-publish'
}
group 'dev.ubujira.ps3d'
@ -28,3 +29,15 @@ dependencies {
implementation 'org.pcap4j:pcap4j-core:2.0.0-alpha.6'
implementation 'org.pcap4j:pcap4j-packetfactory-static:2.0.0-alpha.6'
}
publishing {
publications {
maven(MavenPublication) {
groupId = 'dev.ubujira.ps3d'
artifactId = 'AuthObtainer'
version = '1.1'
from components.java
}
}
}

2
settings.gradle Normal file
View File

@ -0,0 +1,2 @@
rootProject.name = 'AuthObtainer'

View File

@ -10,10 +10,10 @@ import java.util.List;
public class AuthObtainer {
static String sessionTicket = "";
static String playFabId = "";
public String sessionTicket = "";
public String playFabId = "";
public static void main(String[] args) {
public AuthObtainer() {
//First find Wi-Fi / Ethernet Interface
List<PcapNetworkInterface> allDevices = null;
@ -30,8 +30,8 @@ public class AuthObtainer {
try {
InetAddress address = InetAddress.getLocalHost();
for(PcapAddress pcapAddress : d.getAddresses()) {
if(pcapAddress.getAddress().getHostAddress().equals(address.getHostAddress())) {
for (PcapAddress pcapAddress : d.getAddresses()) {
if (pcapAddress.getAddress().getHostAddress().equals(address.getHostAddress())) {
device = d;
break;
}
@ -88,4 +88,8 @@ public class AuthObtainer {
}
}
public static void main(String[] args) {
new AuthObtainer();
}
}