Primer paso de la investigacion. Se aportan el .apk, las carpetas con el apk extraido y el apk descompilado. El archivo API_DOCUMENTATION.md es un archivo donde se anotaran los descubrimientos del funcionamiento de la API, y los .py son scripts para probar la funcionalidad de la API con los métodos que vayamos encontrando. Finalmente, los archivos .js son scripts de Frida para extraer informacion de la APP durante la ejecucion.

This commit is contained in:
2025-12-04 13:59:54 +01:00
parent f2fd1c3bf5
commit e0133d2ca2
10432 changed files with 1019085 additions and 1 deletions

View File

@@ -0,0 +1,32 @@
package com.adif.elcanomovil.repositories.stationObservations;
import com.adif.elcanomovil.domain.entities.stationObservations.StationObservation;
import com.adif.elcanomovil.domain.entities.utils.AsyncResult;
import com.adif.elcanomovil.domain.repositories.stations.StationsObservationsRepository;
import com.adif.elcanomovil.serviceNetworking.stationObservations.StationObservationsService;
import java.util.List;
import kotlin.Metadata;
import kotlin.coroutines.Continuation;
import kotlin.jvm.internal.Intrinsics;
import kotlinx.coroutines.flow.Flow;
import kotlinx.coroutines.flow.FlowKt;
import x1.C0657a;
@Metadata(d1 = {"\u00002\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0002\u0010 \n\u0002\u0018\u0002\n\u0000\n\u0002\u0010\u000e\n\u0002\b\u0002\u0018\u00002\u00020\u0001B\u0015\u0012\u0006\u0010\u0002\u001a\u00020\u0003\u0012\u0006\u0010\u0004\u001a\u00020\u0005¢\u0006\u0002\u0010\u0006J.\u0010\u0007\u001a\u0014\u0012\u0010\u0012\u000e\u0012\n\u0012\b\u0012\u0004\u0012\u00020\u000b0\n0\t0\b2\f\u0010\f\u001a\b\u0012\u0004\u0012\u00020\r0\nH\u0096@¢\u0006\u0002\u0010\u000eR\u000e\u0010\u0004\u001a\u00020\u0005X\u0082\u0004¢\u0006\u0002\n\u0000R\u000e\u0010\u0002\u001a\u00020\u0003X\u0082\u0004¢\u0006\u0002\n\u0000¨\u0006\u000f"}, d2 = {"Lcom/adif/elcanomovil/repositories/stationObservations/DefaultStationsObservationsRepository;", "Lcom/adif/elcanomovil/domain/repositories/stations/StationsObservationsRepository;", "stationsObservationsService", "Lcom/adif/elcanomovil/serviceNetworking/stationObservations/StationObservationsService;", "stationObservationMapper", "Lcom/adif/elcanomovil/repositories/stationObservations/StationObservationsMapper;", "(Lcom/adif/elcanomovil/serviceNetworking/stationObservations/StationObservationsService;Lcom/adif/elcanomovil/repositories/stationObservations/StationObservationsMapper;)V", "observations", "Lkotlinx/coroutines/flow/Flow;", "Lcom/adif/elcanomovil/domain/entities/utils/AsyncResult;", "", "Lcom/adif/elcanomovil/domain/entities/stationObservations/StationObservation;", "stations", "", "(Ljava/util/List;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;", "repositories_proNon_corporateRelease"}, k = 1, mv = {1, 9, 0}, xi = 48)
/* loaded from: classes.dex */
public final class DefaultStationsObservationsRepository implements StationsObservationsRepository {
private final StationObservationsMapper stationObservationMapper;
private final StationObservationsService stationsObservationsService;
public DefaultStationsObservationsRepository(StationObservationsService stationsObservationsService, StationObservationsMapper stationObservationMapper) {
Intrinsics.checkNotNullParameter(stationsObservationsService, "stationsObservationsService");
Intrinsics.checkNotNullParameter(stationObservationMapper, "stationObservationMapper");
this.stationsObservationsService = stationsObservationsService;
this.stationObservationMapper = stationObservationMapper;
}
@Override // com.adif.elcanomovil.domain.repositories.stations.StationsObservationsRepository
public Object observations(List<String> list, Continuation<? super Flow<? extends AsyncResult<? extends List<StationObservation>>>> continuation) {
return FlowKt.flow(new C0657a(list, this, null));
}
}

View File

@@ -0,0 +1,77 @@
package com.adif.elcanomovil.repositories.stationObservations;
import com.adif.elcanomovil.domain.entities.stationObservations.StationObservation;
import com.adif.elcanomovil.domain.entities.stationObservations.StationObservationType;
import com.adif.elcanomovil.serviceNetworking.stationObservations.model.ObservationDTO;
import com.adif.elcanomovil.serviceNetworking.stationObservations.model.ObservationTypeDTO;
import com.adif.elcanomovil.serviceNetworking.stationObservations.model.StationObservationsDTO;
import com.adif.elcanomovil.serviceNetworking.stationObservations.model.StationObservationsRequest;
import com.adif.elcanomovil.serviceNetworking.stationObservations.model.StationObservationsResponse;
import java.util.ArrayList;
import java.util.List;
import kotlin.Metadata;
import kotlin.NoWhenBranchMatchedException;
import kotlin.collections.CollectionsKt;
import kotlin.jvm.internal.Intrinsics;
import kotlin.jvm.internal.SourceDebugExtension;
@Metadata(d1 = {"\u0000(\n\u0002\u0018\u0002\n\u0002\u0010\u0000\n\u0002\b\u0002\n\u0002\u0018\u0002\n\u0000\n\u0002\u0010 \n\u0002\u0010\u000e\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\u0018\u00002\u00020\u0001B\u0005¢\u0006\u0002\u0010\u0002J\u0014\u0010\u0003\u001a\u00020\u00042\f\u0010\u0005\u001a\b\u0012\u0004\u0012\u00020\u00070\u0006J\u0014\u0010\b\u001a\b\u0012\u0004\u0012\u00020\t0\u00062\u0006\u0010\n\u001a\u00020\u000b¨\u0006\f"}, d2 = {"Lcom/adif/elcanomovil/repositories/stationObservations/StationObservationsMapper;", "", "()V", "domainToRequest", "Lcom/adif/elcanomovil/serviceNetworking/stationObservations/model/StationObservationsRequest;", "stations", "", "", "responseToDomain", "Lcom/adif/elcanomovil/domain/entities/stationObservations/StationObservation;", "obs", "Lcom/adif/elcanomovil/serviceNetworking/stationObservations/model/StationObservationsResponse;", "repositories_proNon_corporateRelease"}, k = 1, mv = {1, 9, 0}, xi = 48)
@SourceDebugExtension({"SMAP\nStationObservationsMapper.kt\nKotlin\n*S Kotlin\n*F\n+ 1 StationObservationsMapper.kt\ncom/adif/elcanomovil/repositories/stationObservations/StationObservationsMapper\n+ 2 _Collections.kt\nkotlin/collections/CollectionsKt___CollectionsKt\n*L\n1#1,35:1\n1855#2:36\n1549#2:37\n1620#2,3:38\n1856#2:41\n*S KotlinDebug\n*F\n+ 1 StationObservationsMapper.kt\ncom/adif/elcanomovil/repositories/stationObservations/StationObservationsMapper\n*L\n15#1:36\n17#1:37\n17#1:38,3\n15#1:41\n*E\n"})
/* loaded from: classes.dex */
public final class StationObservationsMapper {
@Metadata(k = 3, mv = {1, 9, 0}, xi = 48)
/* loaded from: classes.dex */
public /* synthetic */ class WhenMappings {
public static final /* synthetic */ int[] $EnumSwitchMapping$0;
static {
int[] iArr = new int[ObservationTypeDTO.values().length];
try {
iArr[ObservationTypeDTO.INCIDENCE.ordinal()] = 1;
} catch (NoSuchFieldError unused) {
}
try {
iArr[ObservationTypeDTO.INFO.ordinal()] = 2;
} catch (NoSuchFieldError unused2) {
}
$EnumSwitchMapping$0 = iArr;
}
}
public final StationObservationsRequest domainToRequest(List<String> stations) {
Intrinsics.checkNotNullParameter(stations, "stations");
return new StationObservationsRequest(stations);
}
public final List<StationObservation> responseToDomain(StationObservationsResponse obs) {
StationObservationType stationObservationType;
Intrinsics.checkNotNullParameter(obs, "obs");
ArrayList arrayList = new ArrayList();
for (StationObservationsDTO stationObservationsDTO : obs.getObservations()) {
List<ObservationDTO> observations = stationObservationsDTO.getObservations();
ArrayList arrayList2 = new ArrayList(CollectionsKt.g(observations));
for (ObservationDTO observationDTO : observations) {
boolean avldmd = observationDTO.getAvldmd();
boolean cercanias = observationDTO.getCercanias();
String observation = observationDTO.getObservation();
if (observation == null) {
observation = "";
}
String stationCode = stationObservationsDTO.getStationCode();
int i = WhenMappings.$EnumSwitchMapping$0[observationDTO.getType().ordinal()];
if (i == 1) {
stationObservationType = StationObservationType.WARNING;
} else {
if (i != 2) {
throw new NoWhenBranchMatchedException();
}
stationObservationType = StationObservationType.INFO;
}
arrayList2.add(new StationObservation(avldmd, cercanias, observation, stationCode, stationObservationType));
}
arrayList.addAll(arrayList2);
}
return arrayList;
}
}