Iosif B. Meyerov

48 papers B 7Misc 2Journal 24Unranked 14
YearRankTypeTitle / Venue / Authors
2026 J jnl
Future Gener. Comput. Syst.
Anna Pirova, Anastasia Vodeneeva, Konstantin Kovalev, Alexander Ustinov, Evgeny Kozinov, Alexey Liniov, Valentin Volokitin, Iosif B. Meyerov
2025 B conf
PaCT
Valentin Volokitin, Evgeny Kozinov, Valentin Petrov, Iosif B. Meyerov
2025 J jnl
CoRR
Anna Pirova, Anastasia Vodeneeva, Konstantin Kovalev, Alexander Ustinov, Evgeny Kozinov, Alexey Liniov, Valentin Volokitin, Iosif B. Meyerov
2024 conf
ICCS (4)
Anastasia Vodeneeva, Iosif B. Meyerov, Yury Rodimkov, Mikhail Ivanchenko, Vladimir Sotskov, Mikhail Krivonosov, Konstantin Anokhin
2024 conf
PPAM (1)
Elena Panova, Valentin Volokitin, Aleksei V. Bashinov, Alexander A. Muraviev, Evgeny Efimenko, Iosif B. Meyerov
2024 J jnl
CoRR
Elena Panova, Valentin Volokitin, Alexei V. Bashinov, Alexander A. Muraviev, Evgeny Efimenko, Iosif B. Meyerov
2024 conf
PPAM (2)
Evgeny Kozinov, Evgeny Vasiliev, Andrey Gorshkov, Valentina Kustikova, Artem Maklaev, Valentin Volokitin, Iosif B. Meyerov
2024 J jnl
CoRR
Evgeny Kozinov, Evgeny Vasiliev, Andrey Gorshkov, Valentina Kustikova, Artem Maklaev, Valentin Volokitin, Iosif B. Meyerov
2023 B conf
PaCT
Valentin Volokitin, Evgeny Kozinov, Valentina Kustikova, Alexey Liniov, Iosif B. Meyerov
2023 J jnl
CoRR
Valentin Volokitin, Evgeny Kozinov, Valentina Kustikova, Alexey Liniov, Iosif B. Meyerov
2023 J jnl
CoRR
Valentin Volokitin, Evgenii Vasiliev, Evgeny Kozinov, Valentina Kustikova, Alexei Liniov, Yury Rodimkov, Alexander Sysoyev, Iosif B. Meyerov
2023 J jnl
CoRR
Valentin Volokitin, Joel Magnusson, Aleksei V. Bashinov, Evgeny Efimenko, Alexander A. Muraviev, Iosif B. Meyerov
2023 J jnl
J. Comput. Sci.
Valentin Volokitin, Joel Magnusson, Alexei V. Bashinov, Evgeny Efimenko, Alexander A. Muraviev, Iosif B. Meyerov
2022 J jnl
CoRR
Elena Panova, Valentin Volokitin, Anton V. Gorshkov, Iosif B. Meyerov
2021 B conf
PaCT
Valentin Volokitin, Alexey V. Bashinov, Evgeny Efimenko, Arkady A. Gonoskov, Iosif B. Meyerov
2021 J jnl
CoRR
Valentin Volokitin, Alexey V. Bashinov, Evgeny Efimenko, Arkady A. Gonoskov, Iosif B. Meyerov
2021 J jnl
Entropy
Yury Rodimkov, Evgeny Efimenko, Valentin Volokitin, Elena Panova, Alexey Polovinkin, Iosif B. Meyerov, Arkady A. Gonoskov
2021 J jnl
Comput. Phys. Commun.
Alexander A. Muraviev, Alexei V. Bashinov, Evgeny Efimenko, Valentin Volokitin, Iosif B. Meyerov, Arkady A. Gonoskov
2021 J jnl
Sensors
Yury Rodimkov, Shikha Bhadoria, Valentin Volokitin, Evgeny Efimenko, Alexey Polovinkin, Thomas Blackburn, Mattias Marklund, Arkady A. Gonoskov, Iosif B. Meyerov
2020 J jnl
CoRR
Valentin Volokitin, Sergei I. Bastrakov, Aleksei V. Bashinov, Evgeny Efimenko, Alexander A. Muraviev, Arkady A. Gonoskov, Iosif B. Meyerov
2020 J jnl
Entropy
Iosif B. Meyerov, Evgeny Kozinov, Alexey Liniov, Valentin Volokitin, Igor I. Yusipov, Mikhail Ivanchenko, Sergey V. Denisov
2019 conf
RuSCDays
Iosif B. Meyerov, Alexander Sysoyev, Anna Pirova, Natalia Shestakova, Mikhail Ivanchenko
2019 conf
PPAM (1)
Iosif B. Meyerov, Alexander Panov, Sergei I. Bastrakov, Aleksei V. Bashinov, Evgeny Efimenko, Elena Panova, Igor A. Surmin, Valentin Volokitin, Arkady A. Gonoskov
2019 J jnl
CoRR
Iosif B. Meyerov, Sergei I. Bastrakov, Aleksei V. Bashinov, Evgeny Efimenko, Alexander Panov, Elena Panova, Igor A. Surmin, Valentin Volokitin, Arkady A. Gonoskov
2019 conf
RuSCDays
Rostislav Povelikin, Sergey Lebedev, Iosif B. Meyerov
2019 J jnl
CoRR
Iosif B. Meyerov, Evgeny Kozinov, Alexey Liniov, Valentin Volokitin, Igor I. Yusipov, Mikhail Ivanchenko, Sergey V. Denisov
2019 J jnl
Comput. Oper. Res.
Antonio Candelieri, Ilaria Giordani, Francesco Archetti, Konstantin Barkalov, Iosif B. Meyerov, Alexey Polovinkin, Alexander Sysoyev, Nikolai Yu. Zolotykh
2018 Misc conf
AIST
Valentina Kustikova, Mikhail Krivonosov, Alexey S. Pimashkin, Pavel Denisov, Alexey Zaikin, Mikhail Ivanchenko, Iosif B. Meyerov, Alexey V. Semyanov
2018 conf
RuSCDays
Valentin Petrov, Sergey Lebedev, Anna Pirova, Evgeniy Vasilyev, Alexander V. Nikolskiy, Vadim Turlapov, Iosif B. Meyerov, Grigory V. Osipov
2018 conf
RuSCDays
Iosif B. Meyerov, Sergei I. Bastrakov, Alexander Sysoyev, Victor Gergel
2017 conf
RuSCDays
Alexey Liniov, Valentin Volokitin, Iosif B. Meyerov, Mikhail Ivanchenko, Sergey V. Denisov
2017 conf
PPAM (1)
Anton Larin, Sergey I. Bastrakov, Alexei V. Bashinov, Evgeny Efimenko, Igor A. Surmin, Arkady A. Gonoskov, Iosif B. Meyerov
2017 J jnl
Optim. Methods Softw.
Anna Pirova, Iosif B. Meyerov, Evgeniy Kozinov, Sergey Lebedev
2017 conf
RuSCDays
Iosif B. Meyerov, Sergey I. Bastrakov, Konstantin Barkalov, Alexander Sysoyev, Victor Gergel
2017 B conf
PaCT
Sergey I. Bastrakov, Igor A. Surmin, Evgeny Efimenko, Arkady A. Gonoskov, Iosif B. Meyerov
2016 ed.
ICA3PP Workshops
Jesús Carretero, Javier García Blas, Victor Gergel, Vladimir V. Voevodin, Iosif B. Meyerov, Juan A. Rico-Gallego, Juan Carlos Díaz Martín, Pedro Alonso, Juan José Durillo, José Daniel García Sánchez, Alexey L. Lastovetsky, Fabrizio Marozzo, Qin Liu, Md. Zakirul Alam Bhuiyan, Karl Fürlinger, Josef Weidendorfer, José Gracia
2016 J jnl
Comput. Phys. Commun.
T. V. Laptyeva, Evgeniy Kozinov, Iosif B. Meyerov, M. V. Ivanchenko, Sergey V. Denisov, Peter Hänggi
2016 conf
ICA3PP Workshops
Igor A. Surmin, Sergey I. Bastrakov, Zakhar Matveev, Evgeny Efimenko, Arkady A. Gonoskov, Iosif B. Meyerov
2016 J jnl
CoRR
Igor A. Surmin, Sergey I. Bastrakov, Zakhar Matveev, Evgeny Efimenko, Arkady A. Gonoskov, Iosif B. Meyerov
2016 J jnl
Supercomput. Front. Innov.
Iosif B. Meyerov, Sergey I. Bastrakov, Igor A. Surmin, Alexey V. Bashinov, Evgeny S. Efimenko, Artem V. Korzhimanov, Alexander A. Muraviev, Arkady A. Gonoskov
2016 J jnl
Comput. Phys. Commun.
Igor A. Surmin, Sergey I. Bastrakov, Evgeny Efimenko, Arkady A. Gonoskov, Artem V. Korzhimanov, Iosif B. Meyerov
2015 B conf
PaCT
Igor A. Surmin, Alexei V. Bashinov, Sergey I. Bastrakov, Evgeny Efimenko, Arkady A. Gonoskov, Iosif B. Meyerov
2015 B conf
PaCT
Sergey Lebedev, Dmitry Akhmedzhanov, Evgeniy Kozinov, Iosif B. Meyerov, Anna Pirova, Alexander Sysoyev
2014 conf
IPDPS Workshops
Victor P. Gergel, Alexey Liniov, Iosif B. Meyerov, Alexander Sysoyev
2013 Misc conf
ICCS
Sergey I. Bastrakov, Iosif B. Meyerov, Victor P. Gergel, Arkady A. Gonoskov, Anton V. Gorshkov, Evgeny Efimenko, M. V. Ivanchenko, Mikhail Yu. Kirillin, A. Malova, Grigory V. Osipov, Valentin Petrov, Igor A. Surmin, A. Vildemanov
2013 B conf
PaCT
Konstantin Barkalov, Alexey Polovinkin, Iosif B. Meyerov, Sergey V. Sidorov, Nikolai Yu. Zolotykh
2012 J jnl
J. Comput. Sci.
Sergey I. Bastrakov, R. Donchenko, Arkady A. Gonoskov, Evgeny Efimenko, A. Malyshev, Iosif B. Meyerov, Igor A. Surmin
2010 conf
MTPP
Iosif B. Meyerov, Andrey Kamaev, Kirill Kornyakov, Artem Zhivoderov
redb/extractors/apk_extractors/apk_manifest.py
← Index redb/extractors/apk_extractors/apk_manifest.py python
import inspect
import json
from datetime import datetime, timezone
from typing import Any

from redb.extractors.enum import Tag
from redb.extractors.apk_extractor import APKExtractor
from redb.models.dataclasses import APKManifest, APKManifestComponent


class APKManifestExtractor(APKExtractor):

    def __init__(
        self, filepath, log, exporters=None, index_prefix=None,
        known_benign=False, known_malicious=False,
        apk=None,
    ):
        super().__init__(
            filepath, log, exporters, index_prefix,
            known_benign, known_malicious, apk,
        )
        self.manifest = None
        self.components = []
        self.log.debug(inspect.currentframe().f_code.co_name)

    def tag(self):
        return Tag.APK_MANIFEST.value

    def _is_component_exported(self, component_type, component_name):
        """Determine if a component is exported.

        Pre-API 31: exported is implicitly True if intent filters exist.
        API 31+: android:exported must be explicit; default is False.
        """
        try:
            exported_attr = None
            # Try to get the exported attribute directly from the XML
            axml = self.apk.get_android_manifest_xml()
            if axml is not None:
                for node in axml.getElementsByTagName(component_type):
                    name = node.getAttributeNS(
                        "http://schemas.android.com/apk/res/android", "name"
                    )
                    if name == component_name:
                        exported_attr = node.getAttributeNS(
                            "http://schemas.android.com/apk/res/android", "exported"
                        )
                        break
        except Exception:
            exported_attr = None

        if exported_attr == "true":
            return True
        if exported_attr == "false":
            return False

        # If not explicitly set, check for intent filters (pre-API 31 behavior)
        try:
            intent_filters = self.apk.get_intent_filters(component_type, component_name)
            if intent_filters:
                actions = intent_filters.get("action", [])
                if actions:
                    return True
        except Exception:
            pass

        return False

    def _get_intent_filters_for_component(self, component_type, component_name):
        """Get intent filters for a specific component."""
        actions = []
        categories = []
        try:
            intent_filters = self.apk.get_intent_filters(component_type, component_name)
            if intent_filters:
                actions = intent_filters.get("action", [])
                categories = intent_filters.get("category", [])
        except Exception:
            pass
        return actions, categories

    def _safe_extract(self, field_name, func, default=None):
        """Extract a single field, logging and returning default on failure."""
        try:
            return func()
        except Exception as e:
            self.log.warning(
                f"Error extracting APK manifest field '{field_name}' for "
                f"{self.hash.sha256}: {e}"
            )
            return default

    def extract(self):
        if not self._is_valid_apk():
            self.log.error(f"Invalid APK for {self.hash.sha256}")
            return None

        activities = self._safe_extract(
            "activities", lambda: list(self.apk.get_activities() or []), []
        )
        services = self._safe_extract(
            "services", lambda: list(self.apk.get_services() or []), []
        )
        receivers = self._safe_extract(
            "receivers", lambda: list(self.apk.get_receivers() or []), []
        )
        providers = self._safe_extract(
            "providers", lambda: list(self.apk.get_providers() or []), []
        )

        # Build component list with intent filter info
        self.components = []
        all_actions = set()
        all_categories = set()
        exported_components = []

        component_map = [
            ("activity", activities),
            ("service", services),
            ("receiver", receivers),
            ("provider", providers),
        ]

        for comp_type, comp_list in component_map:
            for comp_name in comp_list:
                try:
                    is_exported = self._is_component_exported(comp_type, comp_name)
                    actions, categories = self._get_intent_filters_for_component(
                        comp_type, comp_name
                    )
                    all_actions.update(actions)
                    all_categories.update(categories)
                    if is_exported:
                        exported_components.append(comp_name)

                    self.components.append(APKManifestComponent(
                        component_type=comp_type,
                        class_name=comp_name,
                        is_exported=is_exported,
                        intent_actions=list(actions),
                        intent_categories=list(categories),
                    ))
                except Exception as e:
                    self.log.warning(
                        f"Error processing component '{comp_name}' for "
                        f"{self.hash.sha256}: {e}"
                    )
                    # Still add the component with minimal info
                    self.components.append(APKManifestComponent(
                        component_type=comp_type,
                        class_name=comp_name,
                        is_exported=False,
                        intent_actions=[],
                        intent_categories=[],
                    ))

        # Uses-feature
        uses_features = []
        try:
            uses_features = list(self.apk.get_features() or [])
        except Exception:
            pass

        # Meta-data
        meta_data = None
        try:
            axml = self.apk.get_android_manifest_xml()
            if axml is not None:
                md = {}
                for node in axml.getElementsByTagName("meta-data"):
                    name = node.getAttributeNS(
                        "http://schemas.android.com/apk/res/android", "name"
                    )
                    value = node.getAttributeNS(
                        "http://schemas.android.com/apk/res/android", "value"
                    )
                    resource = node.getAttributeNS(
                        "http://schemas.android.com/apk/res/android", "resource"
                    )
                    if name:
                        md[name] = value or resource or ""
                if md:
                    meta_data = md
        except Exception:
            pass

        # Full manifest XML
        manifest_xml = None
        try:
            axml = self.apk.get_android_manifest_xml()
            if axml is not None:
                manifest_xml = axml.toxml()
        except Exception:
            try:
                manifest_xml = self.apk.get_android_manifest_axml().get_xml()
                if isinstance(manifest_xml, bytes):
                    manifest_xml = manifest_xml.decode("utf-8", errors="replace")
            except Exception:
                pass

        self.manifest = APKManifest(
            activity_count=len(activities),
            service_count=len(services),
            receiver_count=len(receivers),
            provider_count=len(providers),
            activities=activities,
            services=services,
            receivers=receivers,
            providers=providers,
            exported_components=exported_components,
            intent_filters_by_action=sorted(all_actions),
            intent_filters_by_category=sorted(all_categories),
            uses_features=uses_features,
            meta_data=meta_data,
            manifest_xml=manifest_xml,
        )
        return self.manifest

    def prepare_export_data(self, exporter_type: str) -> Any:
        if exporter_type == "ClickHouseExporter":
            if not self.manifest:
                return None

            current_time = datetime.now(timezone.utc)
            m = self.manifest

            # Components table (one row per component)
            components_data = []
            for comp in self.components:
                components_data.append([
                    self.sha256,
                    comp.component_type,
                    comp.class_name,
                    int(comp.is_exported),
                    comp.intent_actions,
                    comp.intent_categories,
                    current_time,
                ])

            # Manifest summary table (one row per APK)
            manifest_data = [[
                self.sha256,
                m.activity_count,
                m.service_count,
                m.receiver_count,
                m.provider_count,
                m.intent_filters_by_action,
                m.intent_filters_by_category,
                m.uses_features,
                m.manifest_xml,
                current_time,
            ]]

            return {
                'multi_table': True,
                'manifest': {
                    'table': 'redb_apk_manifest',
                    'data': manifest_data,
                    'column_names': [
                        'sha256',
                        'activity_count', 'service_count', 'receiver_count', 'provider_count',
                        'intent_filters_by_action', 'intent_filters_by_category',
                        'uses_features', 'manifest_xml', 'analysis_date',
                    ],
                    'column_type_names': [
                        'FixedString(64)',
                        'UInt16', 'UInt16', 'UInt16', 'UInt16',
                        'Array(String)', 'Array(String)',
                        'Array(String)', 'Nullable(String)',
                        "DateTime64(3, 'UTC')",
                    ],
                },
                'components': {
                    'table': 'redb_apk_components',
                    'data': components_data,
                    'column_names': [
                        'sha256', 'component_type', 'class_name', 'is_exported',
                        'intent_actions', 'intent_categories', 'analysis_date',
                    ],
                    'column_type_names': [
                        'FixedString(64)', 'LowCardinality(String)', 'String', 'UInt8',
                        'Array(String)', 'Array(String)',
                        "DateTime64(3, 'UTC')",
                    ],
                },
            }

    def get_clickhouse_table(self) -> str:
        return "redb_apk_manifest"