Exploit databaseDownload repository ZIP
GH-f31d567a98ed8040bd7a307db426df6b
michaelroland/omapi-cve-2015-6606-exploit
Sources for CVE-2015-6606
1 sourcePreferred order: Exploit-DB, Metasploit, then GitHub repositories by stars.
Repository files5
michaelroland/omapi-cve-2015-6606-exploitRevision 272b669db4a5
Files from this repository share one source choice. Supporting files may cover other vulnerabilities.
app/src/main/java/org/simalliance/openmobileapi/service/terminals/exploit/OmapiInfo.java
Java · 2,444 bytes/*
** Copyright (C) 2015-2016 Michael Roland <[email protected]>
** FH OÖ Forschungs & Entwicklungs GmbH
**
** This program is free software: you can redistribute it and/or modify
** it under the terms of the GNU General Public License as published by
** the Free Software Foundation, either version 3 of the License, or
** (at your option) any later version.
**
** This program is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
** GNU General Public License for more details.
**
** You should have received a copy of the GNU General Public License
** along with this program. If not, see <http://www.gnu.org/licenses/>.
**
*/
package org.simalliance.openmobileapi.service.terminals.exploit;
import java.io.PrintStream;
import java.util.ArrayList;
import org.simalliance.openmobileapi.Reader;
import org.simalliance.openmobileapi.SEService;
public class OmapiInfo extends DumpableInfo {
private final ArrayList<String> mSecureElements;
public OmapiInfo(SEService service, String[] excludeSecureElements) {
mSecureElements = new ArrayList();
Reader[] readers = service.getReaders();
for (Reader reader : readers) {
String terminalName = reader.getName();
mSecureElements.add(terminalName);
if (!nameStartsWith(terminalName, excludeSecureElements)) {
}
}
}
private static boolean nameStartsWith(String name, String[] listOfPrefixes) {
if ((name != null) && (listOfPrefixes != null)) {
for (String prefix : listOfPrefixes) {
if (name.startsWith(prefix)) {
return true;
}
}
}
return false;
}
public void dump(PrintStream out) {
out.println("######################################################################");
out.println("# Open Mobile API");
out.println("######################################################################");
out.println("Available secure elements:");
for (String s : mSecureElements) {
out.println(" " + s);
}
out.println("######################################################################");
out.println();
}
}