WEBVTT

00:00.000 --> 00:01.860
So can you hear me everyone?

00:02.180 --> 00:03.500
Perfect.

00:03.500 --> 00:06.220
So hello everyone, thank you for coming to my talk.

00:06.220 --> 00:09.520
So I'm going to briefly present myself.

00:10.540 --> 00:18.020
So my name is Gabrielle Bodbol and I am an offensive security advisor for a Canadian banking cooperative.

00:18.420 --> 00:27.540
And alongside my full-time work, I freelance and offer various cyber security related services such as training and consulting.

00:27.540 --> 00:34.040
And in addition to my professional activities, I'm very involved in the cyber security community.

00:34.040 --> 00:45.300
And so in recent years, I have also been recognized with awards such as the top 20 women in cyber security in Canada and woman hacker of the year in 2022.

00:45.540 --> 00:55.300
So today I wanted to share with you my journey in AI and specifically AI in the Android system.

00:55.300 --> 01:14.240
So what I want to share with you today is how as a pen tester I trained myself, but also how I explored and tested how AI was going to change my profession and how it was going to impact Android and of course Android security.

01:17.170 --> 01:21.130
So first let's have a quick reminder on what is Android.

01:21.130 --> 01:27.490
So Android is a mobile operating system which is based on a modified version of the Linux kernel.

01:27.670 --> 01:29.410
And it's developed by Google.

01:29.410 --> 01:33.310
And the most used language for Android app is Java.

01:33.410 --> 01:37.350
But since 2019, the official language is Kotlin.

01:37.490 --> 01:44.390
And so the Android architecture is divided into five main layers that you can see on the screen.

01:44.950 --> 01:51.090
So now that this is all cleared up, we're going to chat about the pen test of the Android app.

01:51.790 --> 01:54.350
So what is Android app pen test?

01:54.350 --> 02:03.770
So along with mobile pen test, it is a type of pen test that it is part of the list we usually provide as pen testers.

02:03.770 --> 02:11.490
So it's different from other pen tests because most of the time we get an executable that we need to analyze.

02:14.330 --> 02:16.530
So why is this important?

02:16.530 --> 02:19.890
So here you can see two articles that I invite you to read.

02:19.890 --> 02:22.930
The links are going to be in the resources that I will provide at the end.

02:22.930 --> 02:26.190
You will have like a QR code to scan or you can just take a picture.

02:26.190 --> 02:29.890
You will have a link as well if you don't trust QR code.

02:30.590 --> 02:50.570
But to summarize the first article, it's about gold pickaxe, which is a sophisticated malware for Android and iOS that uses social engineering tactics to deceive users and trick them into scanning their face and identity document.

02:50.570 --> 03:01.110
So this malware is suspected of using this information to generate deepfakes or to illegally access banking services.

03:01.110 --> 03:17.790
The other article is also very interesting and in summary it highlights the discovery of a new Android malware family called Autolikos which has been downloaded more than three million times from the Google Play Store.

03:17.790 --> 03:30.430
And so this malware was embedded in at least eight applications and some of which stayed available on the Google Play Store for several months even after being reported to Google.

03:31.150 --> 03:41.850
So to my knowledge there hasn't been major breach caused by AI directly malfunctioning or being compromised in Android application.

03:41.850 --> 03:58.610
However what we're seeing are significant privacy issues when installing Gen AI apps and more concerning cyber criminals are increasingly using AI to enhance their attacks.

03:59.290 --> 04:05.350
And so additionally AI apps themselves are going to pose security risk.

04:05.350 --> 04:15.050
So for example it could lead to some vulnerabilities were found to popular AI apps like Pairplicity.

04:15.110 --> 04:18.830
We are going to talk about this a little on later.

04:18.910 --> 04:24.570
And this could lead to data theft and account takeover.

04:24.570 --> 04:37.570
So really what's interesting today is how AI is being weaponized by bad actors and also how AI applications are creating new attack surfaces.

04:39.550 --> 04:41.930
So here are some figures.

04:41.930 --> 04:49.090
They come from Zimberium's Global Mobile Threat Report that was published in early 2025.

04:49.170 --> 04:53.190
And so I really think that all of these are quite alarming.

04:53.690 --> 05:07.470
But to mention only two, I would say that first according to the report 61.2% of Android devices were running out-of-date operating systems during 2024.

05:07.470 --> 05:27.770
So now what's even more critical is that over half of these devices, about like 35%, where it could have been avoided because they could have the update but they were just not updated.

05:27.950 --> 05:34.770
So the other 25% of the devices were too old to be updated.

05:34.810 --> 05:36.610
So they could not be updated.

05:36.610 --> 05:41.810
And you know this is really problematic because phones are expensive today.

05:42.150 --> 05:47.950
And when people can't update their older device, well it creates a gap.

05:48.150 --> 05:52.630
And security is not something you should sacrifice.

05:53.090 --> 06:00.650
And so I think it's really problematic because we have to use phone, we have to use smartphone every day, we do everything with smartphone.

06:01.030 --> 06:08.230
And I will go, I have a next slide actually about what so much we do about our cell phones.

06:08.230 --> 06:20.770
And also another really important and typical of the AI era we are in today is that the AI usage grew by 160% in apps on enterprise devices.

06:21.190 --> 06:27.730
So what is interesting is that 12% of these apps are related to finance.

06:27.970 --> 06:31.390
So I think it's really important to stress that out.

06:32.050 --> 06:40.670
To go further with AI security risk, I wanted to also present these figures taken from the report Top AI Security Incidents by Adversa.

06:40.670 --> 06:44.590
I also have the link for you in the end.

06:44.650 --> 06:49.310
And so as you can see here, prompt injection is the new skill to learn.

06:49.630 --> 06:55.690
And so I'm going to explain briefly a few terms here because they are essential in AI security.

06:55.690 --> 07:07.070
So prompt injection is basically when someone with malicious intent tricks an AI system by sneaking harmful comments into their input.

07:07.930 --> 07:21.850
And so you can think of it like the developers are going to give the AI a set of rules to follow but bad actor can try to give new instructions to override those original rules.

07:21.850 --> 07:25.110
So this could lead to jailbreaking for example.

07:25.110 --> 07:37.320
And it happens because the AI can't always tell the difference between the legitimate instruction it's supposed to follow and the sneaky ones that are hidden and that the user input.

07:38.460 --> 07:44.280
Hallucination is when an LLM makes up information because they just don't know the answer of what you're asking.

07:45.080 --> 07:51.260
And so yeah, that's pretty much it for this one.

07:51.260 --> 07:57.520
So finally, as I quickly mentioned before, we cannot deny the place that smartphones have today.

07:57.580 --> 08:00.940
They are much more than simple communication device.

08:01.020 --> 08:15.880
They play really a central role in many essential daily activities, whether it's for managing our finances, whether it's for browsing the internet, whether it's for interacting on social media, it's real gateways to the world.

08:15.880 --> 08:29.060
And so an unsecured smartphone, it's not just a risk to your personal information, but it can also be a gateway to broader attacks on your financials and social life.

08:29.060 --> 08:44.160
So they contain sensitive data and they could have, so now let's see how AI is actually built into Android and mobile devices.

08:44.160 --> 08:47.840
So there are essentially four main ways this work.

08:47.840 --> 08:52.080
So first we have what's called embedded or on-device AI.

08:52.080 --> 09:02.680
So that is where AI models run directly on your Android devices, hardware, like without needing to send any data to the cloud.

09:02.680 --> 09:04.200
So this is on-device.

09:04.920 --> 09:07.060
Second, there's cloud-based AI.

09:07.060 --> 09:09.860
So it's also known as enhanced AI.

09:09.860 --> 09:17.320
And this is where your device sends data to the cloud servers for AI processing, and then you get the result back.

09:17.460 --> 09:29.420
And third, you have many Android AI features that will use hybrid approaches, and it will combine both on-device and cloud-based AI to get the best of both worlds.

09:29.420 --> 09:42.260
And finally, what's important to note is also that Google provides various AI tools and framework to help developers integrate AI into their Android app.

09:44.220 --> 09:51.680
So before diving into this slide, I want to briefly mention the difference between AI and Gen AI.

09:51.680 --> 10:02.200
So traditional AI will analyze existing data to make prediction and classifications and answer questions like, what is this?

10:02.200 --> 10:04.600
Or what will happen next?

10:04.600 --> 10:10.700
And so generative AI will create entirely new content from learned patterns.

10:10.700 --> 10:18.280
So it's going to produce original text, images, and code, and also other material based on user prompts.

10:18.280 --> 10:20.120
So what you will ask it.

10:20.120 --> 10:29.300
So on this slide, I wanted to show where we can find AI on a mobile device, because this is not something you can see right away.

10:29.420 --> 10:46.720
So the meta-category, user interface and interaction, will encompass all AI features that directly facilitate how users will communicate with and control their Android device through various input methods and interfaces.

10:46.720 --> 11:01.160
The meta-category, core system intelligence, it covers the foundational AI systems that will manage the resources, the security, and overall system optimizations behind the scenes.

11:01.480 --> 11:13.620
And the meta-category, content creation and media, will focus on AI features that enhance creative expressions, media consumption, and generation on Android devices.

11:13.620 --> 11:23.720
And finally, the connected experience meta-category covers AI integration that extends beyond the device itself to connect with external services.

11:23.720 --> 11:29.320
So this can be IoT devices, this can be health monitoring systems, and so on.

11:31.170 --> 11:38.750
So before the attack surface, I wanted to mention briefly the difference between the ML security risk and the LLM security risk.

11:38.750 --> 11:48.410
So as you probably know, OWASP has published multiple top 10s, and they published a top 10 for ML and a top 10 for LLM.

11:48.410 --> 11:59.230
And so when I started to get into AI red teaming, which is another of my current passions as a red teamer, I was wondering about the difference between these two top 10s.

11:59.230 --> 12:10.550
And at some point, I saw that the OWASP top 10 for LLM was more focused on post-deployment, and that the ML one was more focused on pre-deployment.

12:10.550 --> 12:26.090
But however now, I realized that if an attacker is able to fingerprint a model or get a model file, they could actually use the attacks like the one in the OWASP top 10 ML, which is after deployment as well.

12:26.390 --> 12:31.470
And also recently, I found this table on Riya Mashiwari's repository.

12:31.810 --> 12:35.950
And so you will also have it on the slide, on the resources.

12:35.950 --> 12:40.890
And so it highlights the differences between the same, both top 10s.

12:40.890 --> 12:48.950
And here we can see, for example, that the attack she mentioned could be both done post-deployment and pre-deployment

12:52.330 --> 12:52.850
.

12:52.850 --> 12:59.670
So now that we have seen this, what does the Android attack surface look like today?

12:59.670 --> 13:10.170
Well, it is the sum of its traditional vulnerabilities and a whole new set of threats that are introduced by the integration of artificial intelligence.

13:10.470 --> 13:32.770
So the traditional vulnerabilities would be any app on your phone, the core Android software itself, how your phone talks to the outside world with Wi-Fi, with Bluetooth, with cellular data, the specific permissions the apps are granted, or just simple human error like phishing or scam or installing malware,

13:32.770 --> 13:33.500
for example.

13:34.350 --> 13:45.810
And so today we can say that the AI layer will add new dimensions to these existing areas and expand the attack surface on various levels.

13:46.310 --> 13:51.070
So the AI-enhanced application will introduce new ways to be tricked or exploited.

13:51.070 --> 13:56.390
So, for example, as we mentioned before, prompt injection or adversarial examples.

13:56.390 --> 14:05.710
And so for the AI data flow over the networks, because AI models communicate with cloud services, and so they will receive updates.

14:05.710 --> 14:10.010
So the network is even a more critical point than it used to be.

14:10.250 --> 14:15.970
And so here we can have data leakage and we can also find model tampering.

14:16.050 --> 14:27.310
And also the AI models and their inference engine, so this is the software and hardware that runs the AI, they reside within the phone system.

14:27.310 --> 14:42.610
So now a traditional OS vulnerability could be exploited to directly steal the AI model's intellectual property, tamper with its operation, or extract sensitive data it processes.

14:43.750 --> 14:56.030
Then the AI-driven data inference means that AI can figure out private details about you from data that seems harmless.

14:56.070 --> 14:58.530
So I really want to stress this.

14:58.530 --> 15:08.390
So if you have an AI photosorter and it has only permission to see your images, what could go wrong?

15:08.390 --> 15:26.130
Except it can deduce your location and it can deduce who you are based on social circles, for example, or on facial recognitions, and even without explicit location or contact permissions.

15:26.130 --> 15:31.950
So we have the permissions that control this, but we don't know what the AI is going to do.

15:32.630 --> 15:45.590
And so the AI model itself, in other words, the AI brain, we can say, it becomes a direct target because it can be targeted with a model theft or backdoors.

15:45.650 --> 15:52.390
And so the AI training data is a new vulnerability point and it could be targeted with data poisoning.

15:53.310 --> 16:01.130
And finally, the AI development and deployment pipeline can also have vulnerabilities.

16:01.130 --> 16:07.630
So they can exist in the tools, in the processes, or in environments where the AI models are built.

16:07.630 --> 16:10.810
So where they are tested and where they are deployed.

16:10.810 --> 16:16.270
And so this could be compromised even before the AI reaches your phone.

16:19.230 --> 16:38.730
So to summarize, we could say that the Android attack surface is like a complex interplay of hardware, of operating systems, of applications, network, and the entire life cycle of embedded and cloud-connected AI systems.

16:38.730 --> 16:45.650
And so each of these elements are opportunities for attackers to exploit it.

16:45.650 --> 17:06.690
And also something worth noting that we will see implicitly through the presentation is that, in essence, AI security demands a shift from a purely technical lens to a more holistic socio-technical perspective because it requires new tools, new skills,

17:06.690 --> 17:13.430
and also to have a continuous adaptive approach to risk management and reporting.

17:15.980 --> 17:17.580
So what about APIs?

17:17.580 --> 17:25.640
So as you know, a lot of developers are going to use APIs to develop their Android applications for various reasons.

17:25.640 --> 17:27.640
So you can see them on the screen.

17:27.640 --> 17:36.600
And finally, today, APIs are also used for tests related to artificial intelligence.

17:37.200 --> 17:45.260
So machine learning, computer vision, speech recognition, and natural language understanding.

17:48.070 --> 17:56.790
So to go a little further about APIs related to AI, I wanted to give an overview of how AI changed Android APIs.

17:56.790 --> 18:03.410
So you know, AI has really transformed how APIs work in Android apps.

18:03.410 --> 18:06.490
So I'm going to walk through the main changes.

18:06.490 --> 18:14.250
So first, Google realized that developers needed easier ways to add AI features to their apps.

18:14.250 --> 18:17.950
So they created brand new APIs for this.

18:18.030 --> 18:19.890
But there's another interesting element.

18:19.890 --> 18:25.910
It's that Android itself had to change at the system level.

18:25.910 --> 18:39.050
So they introduced something called the neural network API, which is basically a way for apps to talk directly to the specialized AI ships that are now built into many phones.

18:39.050 --> 18:49.810
So now, one of the biggest shifts has been that this move from cloud to what we call edge processing, as I presented before.

18:49.810 --> 19:00.030
So in the past, if you wanted to use AI features, your app would send data to Google servers, process it there, and then send the result back.

19:00.030 --> 19:03.410
But now, a lot of this happens on your phone.

19:03.410 --> 19:05.630
So this is supposed to be better for privacy.

19:05.730 --> 19:09.310
Not that I'm saying it is supposed to be better for privacy.

19:09.830 --> 19:16.330
Because your photos and voice recordings are not supposed to leave your phone.

19:16.670 --> 19:22.610
So essentially, AI didn't just add new features to Android.

19:22.610 --> 19:29.450
It fundamentally changed how the whole API ecosystem works.

19:29.690 --> 19:32.090
So what does this mean for us as pen testers?

19:32.890 --> 19:36.870
Well, there are a few elements that we can take into account.

19:37.190 --> 19:39.690
So you can see some of these elements on the screen.

19:39.690 --> 19:41.870
And this is only for the application layer.

19:41.870 --> 19:47.290
But these changes also add potential vulnerabilities on the OS framework.

19:48.350 --> 19:51.830
And also the hardware layer.

19:52.170 --> 19:56.410
So for example, is privacy actually respected?

19:56.690 --> 19:59.930
Does the data actually stay on the local device?

20:00.190 --> 20:02.670
And does it go to the cloud later on?

20:02.870 --> 20:06.190
What happens if we try adversarial inputs?

20:06.330 --> 20:08.750
Can we fool face recognition?

20:08.750 --> 20:10.570
Can we fool text recognition?

20:10.570 --> 20:13.230
And image classification models.

20:16.080 --> 20:26.020
So now that we have seen how AI impacts API, let's see the difference between traditional APIs and model APIs that handle the AI functionality.

20:26.020 --> 20:29.780
So first, let's talk about what they're actually designed to do.

20:29.780 --> 20:33.000
So traditional APIs, they're pretty straightforward.

20:33.120 --> 20:42.280
So they handle basic operations like pulling data from a database, processing a payment , or managing user accounts.

20:42.320 --> 20:54.660
Model APIs, on the other hand, they are specifically built to tap into AI models and give you intelligent productions or output.

20:54.820 --> 20:58.540
So now the type of data they work with, it's also really different.

20:58.540 --> 21:04.560
Because traditional API will use traditional data like JSON or XML formats.

21:04.560 --> 21:07.860
And it's predictable and it's organized.

21:07.860 --> 21:10.760
But models APIs, they are more flexible.

21:10.760 --> 21:16.060
So you can input image, you can input audio files, you can input text, or even videos.

21:16.060 --> 21:20.580
And they'll give you back things like classification or generated content.

21:20.620 --> 21:25.980
Also, traditional APIs, they're doing relatively simple tasks.

21:25.980 --> 21:30.740
So which are database lookup, as we say, data transformation and everything.

21:30.880 --> 21:35.660
But model APIs, they run more complex tasks.

21:35.840 --> 21:41.340
And so they use mathematical operation using neural networks.

21:41.360 --> 21:45.410
So this leads to another big difference, which is the resources.

21:45.900 --> 21:49.500
So traditional APIs, they are generally lightweight and fast.

21:49.500 --> 21:55.840
But model APIs will need more resources and sometimes special hardware.

21:56.200 --> 22:00.500
So another difference also is predictability.

22:00.500 --> 22:05.420
With traditional API, if you send the same input, you always get the same output.

22:05.420 --> 22:07.860
It's really deterministic.

22:07.860 --> 22:12.640
But model APIs, they can be probabilistic.

22:12.640 --> 22:20.340
So especially with generative AI, you might send the exact same input twice and you will get different results.

22:20.340 --> 22:30.440
So for example, traditional API might be send your location and get back weather data, send payment details, and get a transaction status.

22:30.440 --> 22:32.800
So model APIs, it will work differently.

22:32.800 --> 22:38.200
You will send an image and you will get what objects are detected in it.

22:38.200 --> 22:43.620
You can send text to get a translation, and you can send audio to get the transcribed task.

22:44.380 --> 22:53.100
So even error handling is different, because traditional API will give you clear errors, such as invalid input or server dumps.

22:53.100 --> 22:59.780
But model API will probably give you confidence scores or tell you the prediction is uncertain.

22:59.780 --> 23:01.720
So the bottom line is this.

23:02.020 --> 23:14.360
Traditional API are like efficient data processors, while model APIs are more like having some sort of assistant that can understand and make decisions about your data.

23:17.580 --> 23:28.100
So when you are pen testing an AI-enhanced Android application, each phase of the traditional methodology gets significantly expanded.

23:28.100 --> 23:33.420
So for more details, I also made another comparison that you can find in the resources I will provide.

23:33.420 --> 23:37.940
But in the reconnaissance phase, we have a few things that change.

23:37.940 --> 23:49.800
We will basically need to identify the AI system architecture to map the endpoints and to analyze the models we find, including the input and the output formats.

23:49.800 --> 23:56.640
And it also changes a few things for the dynamic analysis and static analysis and the report phase, of course.

23:57.280 --> 24:06.740
We will see a little more what happens for this specific topic in a few slides, but the bottom line here is that AI doesn't replace your methodology.

24:06.800 --> 24:10.660
It kind of layers on top of it.

24:11.260 --> 24:20.300
So each phase now has specific AI components that will require new tools, new techniques, and sometimes new skills as well.

24:20.300 --> 24:27.300
So you're not just testing an app anymore, you're testing the app and the AI model that lives in it.

24:27.300 --> 24:35.200
So this typically adds, I would say, 30 to 50 percent more time to your full pen test engagement.

24:37.560 --> 24:46.920
So before getting into the threat modeling framework, which is dedicated to AI, I just want to make a quick reminder on what threat modeling is.

24:46.920 --> 24:58.240
So threat modeling is the process to identify, understand, and address potential threats to the security of a system, an application, or an infrastructure.

24:58.300 --> 25:03.380
So it's a process that can be carried out by different security professionals.

25:03.380 --> 25:07.380
And so depending on who is doing it, the process will be different.

25:07.380 --> 25:17.700
So for example, some companies will have a dedicated team to threat modeling, but it can be done also before a pen test by pen testers themselves.

25:17.700 --> 25:20.140
This is something that I do myself.

25:21.460 --> 25:27.440
So there are various frameworks for threat modeling in traditional cybersecurity.

25:27.440 --> 25:31.080
So we can, for example, mention Stride or PASTA.

25:31.120 --> 25:34.820
But when AI arrived, these frameworks were not enough.

25:35.300 --> 25:44.300
And on the screen you can see that the OWASP AI threat model that aims to provide a more comprehensive framework for this specific topic.

25:44.300 --> 25:46.360
So it has three types of threats.

25:46.360 --> 25:55.440
The one during development time, the one for using the model, and the one by attacking the system during runtime, so in production.

25:55.440 --> 26:02.940
And it also identifies six types of impact, and for three types of attackers, of attacker goals.

26:03.360 --> 26:10.480
So as you probably know, attackers have three main objectives related to the CIA triad.

26:10.480 --> 26:19.240
So they call it disclose for the confidentiality, deceive for the integrity, and disrupt for the availability.

26:19.380 --> 26:32.980
So for the disclose category, the impacts are hurt confidentiality, or trained test data, hurt confidentiality of model intellectual property, and hurt confidentiality of input data.

26:33.280 --> 26:38.900
So for the deceive category, the impact is that it hurts the integrity of the model behavior.

26:38.900 --> 26:44.100
So in other words, users and system rely on AI decisions.

26:44.100 --> 26:48.980
So of course, wrong decisions could cause real harm.

26:49.080 --> 26:59.200
And finally, for the disrupt category, the impacts are hurt availability of the model, disrupt disclose non-specific, non-AI specific assets.

26:59.200 --> 27:06.760
So for the defense strategy, they develop various controls that form a summary of how to address AI security.

27:06.760 --> 27:13.070
And so there, we find AI governance to implement governance processes for AI risk application.

27:13.650 --> 27:28.170
So it's a conventional technical IT security control, since an AI system is an IT system, and data scientists also should apply data science security control, but risk-based.

27:28.170 --> 27:35.730
So the aim is to minimize data and to limit the amount of data in rest and in transit.

27:35.730 --> 27:45.890
And finally, to control behavior impact, as the model can behave in unwanted ways by mistake or by manipulation.

27:47.730 --> 27:58.650
So now that we have seen how we can threat model this new AI risk, I wanted to introduce you a very useful tool for us as pen testers, which is the OWASP AI testing guide.

27:58.650 --> 28:04.990
So this is a guide that was created to help professional test AI systems.

28:04.990 --> 28:15.810
So we can think of it as a comprehensive playbook for ensuring that AI is reliable, secure, and behave ethically.

28:15.810 --> 28:27.990
So the guide outlines a robust suite of tests, including data-centric validation, fairness assessment, adversarial business, and continuous performance monitoring.

28:28.030 --> 28:34.550
And so on the screen you can see a visual that I created to show how we as pen testers can use this guide.

28:34.550 --> 28:40.730
So it will of course be in the resources that I will give you in the end, if you want to have a look.

28:40.810 --> 28:48.990
But it covers attack vectors, testing phase, arsenal high value targets, and also sample exploits.

28:49.110 --> 28:56.970
So finally we can say that in terms of AI security perspective, as pen testers we are looking for various things.

28:56.970 --> 29:20.110
We are looking for high risk findings, which could be embedded API keys or secrets in model weights, training data samples that are accidentally baked into the model, an encrypted model that would reveal some business logic, poor input validation that could lead to crashes or buffer overflows,

29:20.110 --> 29:42.070
model version info that maps to known vulnerabilities, model-specific attack vectors, which could be model extraction, like can you copy or can you use the model elsewhere, can you fool the model with crafted inputs, and can you also reverse engineer what data was used to train it.

29:42.890 --> 29:48.330
And does the model show also unfair bias that you could exploit?

29:51.930 --> 30:01.210
So also I wanted to make a table of the various possible tools, and of course I also wanted to mention AI-enhanced tools that can be used for a pen test.

30:01.210 --> 30:04.430
So on the screen you have various tools split in three categories.

30:04.530 --> 30:16.550
The traditional tools that we use for Android application pen test, the AI-enhanced tools that we can use for Android application pen test as well, and the tools that can be used to pen test AI.

30:16.910 --> 30:21.150
So one specific tool that I wish to mention is Android MEDA.

30:21.150 --> 30:28.330
So this tool is an LLM tool which is designed to de-obfuscate Android app code and find vulnerabilities.

30:28.430 --> 30:33.260
And it has been created by Vibhav Agrawal who works for Google.

30:36.270 --> 30:40.090
So now how do we proceed for the static analysis?

30:40.090 --> 30:52.090
So we have of course to check the manifest and the strings XML files and we can also enumerate database and you can find of course some tools on GitHub that can help you for this purpose.

30:52.570 --> 30:55.450
And of course we need to check for sensitive data.

30:55.450 --> 31:03.070
So for AI-enhanced app we can search for AI model and configuration files and we can analyze them.

31:03.150 --> 31:14.530
And to go further on this I shared in the resources an article on how to integrate custom PyTorch model in an Android app that was done by Gabriel Mongaras.

31:14.530 --> 31:19.970
And this way you can have an idea on how developer will integrate AI in their code.

31:23.450 --> 31:30.630
So now I wanted to provide a reminder on how to check the code because I will show some example in the next upcoming slides.

31:30.630 --> 31:38.870
But to check the code you can use JADX or APK tools and this tool will decompile the APK and will offer some level of deobfuscation.

31:38.990 --> 31:43.090
So for JADX you just need to launch the command you see on the screen and you're good to go.

31:43.090 --> 31:53.150
And for APK tools you can also use this command and it will all put everything in a folder and it will have the name of your app and you will get similar files to what you see on the screen.

31:53.690 --> 31:55.290
Similar files and folders.

31:56.550 --> 32:11.070
So once you have the code you can share it for keywords such as HTTP, HTTPS to identify API end points and additionally you can look for functions or classes that will handle network requests and responses.

32:11.230 --> 32:23.450
And also the Android manifest file in the applications APK package will contain metadata about the application and so it will also have the declared permissions, the services and the activities.

32:23.450 --> 32:32.370
So you can look for permissions related to network communication which would help you to identify API endpoint, sorry.

32:33.110 --> 32:39.790
And finally you can analyze the application JavaScript file to identify API endpoints.

32:39.790 --> 32:48.750
So it's worth checking there for AI APIs endpoint because they could look like something you can see, something like this that you can see on the screen.

32:50.770 --> 32:54.930
So now I want to present an app that I created.

32:55.010 --> 33:04.490
So as you probably know the number of AI-generated mobile applications on the market will increase significantly in the coming years.

33:04.490 --> 33:11.150
So indeed with the company that provides tools to build an application in just a few minutes with AI.

33:11.150 --> 33:18.910
So we have both businesses and individuals who will be able to publish their applications in the wild, just like that.

33:19.230 --> 33:24.790
And so recently Google also launched Opal which is an AI app builder.

33:25.690 --> 33:39.770
So whether it's for commercial or personal purposes these applications that are based on things like vibe coding and produce rapidly will of course have security problems.

33:40.270 --> 33:46.190
And a few days ago I read an analysis by Veracode that highlighted this specific issue.

33:46.190 --> 33:49.210
I think I put the link in my resources.

33:50.070 --> 33:52.410
If I did not I will put it.

33:52.550 --> 34:01.110
So indeed the analysis mentioned that AI-generated code introduced security vulnerabilities in 45% of cases.

34:01.190 --> 34:07.710
So when given a choice between a secure and insecure coding method, so what does this mean?

34:07.710 --> 34:16.730
It means that the researchers they presented AI model with coding scenarios where they had to choose how to implement a functionality.

34:16.730 --> 34:28.530
And they found out that when given a choice between a secure and insecure method to write code, GenAI model chose the insecure option 45% of the time.

34:28.530 --> 34:32.250
So that gives us some work as pen testers.

34:32.550 --> 34:46.610
So to simulate this, which is already existing and which is a growing situation, and to demonstrate this in this talk, I wanted to try building an application using this type of process.

34:46.950 --> 34:57.750
And even though a few platforms offer applications in Kotlin, we can still create applications quickly with the help of generative AI.

34:57.890 --> 35:08.950
So what I wanted to do was demonstrate just how fragile this is in terms of security, which is why I'm going to present two examples of vulnerabilities that I inserted into this app.

35:10.430 --> 35:17.410
So this way you will be able to see the risk of AI-enhanced applications and, of course, applications coded with AI.

35:17.410 --> 35:20.490
So the first example is for the static analysis phase.

35:20.590 --> 35:29.350
And in a few slides I will show you another example with prompt injection that can be done during the dynamic analysis phase.

35:31.450 --> 35:33.990
So here we have the static analysis example.

35:33.990 --> 35:37.630
So the app as I created is called Oracle.

35:38.510 --> 35:49.570
And so I decompiled my APK and I was able to get all the files, including the model file that was built with TensorFlow.

35:49.570 --> 35:53.870
So it's the tf.light files that you can see here.

35:55.910 --> 36:10.550
So here with just a string, so one of the first commands we learn when we do CTF, we were able to find an API key.

36:12.250 --> 36:22.110
So here a string is the job for this specific demo, but if you wanted to do a more comprehensive analysis of a model file, you could use an app like Netrun.

36:22.110 --> 36:37.210
So Netrun is a graphical viewer for neural networks and it will help visualize the model's architecture, the layers and connection, and it can sometimes reveal metadata or layer names.

36:37.610 --> 36:43.510
And also you get a visualization , sorry for the French accent.

36:43.790 --> 36:52.730
And so also for a very deep dive, you could also convert the tf.light file into a human-reliable JSON format.

36:52.730 --> 36:57.290
And so you have tools like flat buffers to JSON that will do this for you.

36:57.430 --> 37:05.930
And so this would expose all internal details including any custom metadata fields.

37:05.930 --> 37:10.850
So I'm going to go a little faster because I see it's almost time.

37:10.850 --> 37:15.970
So here this is a traditional vulnerability that you can have hard-coded secrets.

37:15.970 --> 37:19.250
This is from Injured Android CTF.

37:19.830 --> 37:28.070
You probably all know how to grep, but I think it's really useful to do this.

37:28.630 --> 37:33.870
And I added a link to my resources on various tips on how to grep.

37:34.590 --> 37:38.190
And as you know the dynamic analysis part, so you will intercept traffic.

37:38.190 --> 37:42.350
So these are the things that you can check when you are doing the dynamic analysis.

37:43.490 --> 37:47.950
What's nice is also to try to find and identify API endpoints.

37:47.950 --> 37:50.730
So on the screen you can see what it could look like.

37:51.050 --> 37:53.290
And it can be efficient to use a list.

37:53.290 --> 38:00.370
And for AI API endpoints, as we saw in the static analysis, they often follow the same design pattern that common APIs use.

38:02.030 --> 38:05.090
And so this is the prompt injection I mentioned to you.

38:05.090 --> 38:08.830
So this is a classical example from the Oracle app I created.

38:08.910 --> 38:13.110
And so the chatbot is really, really happy to give us its API key.

38:13.410 --> 38:20.270
And so in a real context, of course, it's more subtle and sometimes we even need to interact a little more with the chatbot to get what we want.

38:23.050 --> 38:31.550
For the curious minds who want to discover a new attack vector, it is highlighted in this research paper from researchers of Monash University in Australia.

38:31.770 --> 38:34.470
And it's called the Smart App Attack Framework.

38:34.510 --> 38:37.590
And so you will find it in the list of resources I'll provide at the end.

38:37.590 --> 38:40.610
I'm not going to explain it because obviously I don't have time.

38:40.610 --> 38:44.770
But it's so interesting that it would require a full talk about it.

38:44.770 --> 38:49.010
So I have summarized it in a visual form and you will find it in the resources.

38:50.130 --> 38:56.690
So one other important thing I wanted to mention is that traditional Android app and test is not dead.

38:58.510 --> 39:05.970
So in this slide, I used another research that shows that traditional vulnerabilities can still be found in AI apps.

39:05.970 --> 39:22.330
I don't know if any of you read a paper that was done by AppNox, but they were able to find classical Android vulnerabilities in the DeepSeq Android app and the Perplexity Android app.

39:22.390 --> 39:41.870
So this is really concerning because this is not just because they found numerous issues, but because they represent a lack of basic app hardening, insecure defaults, and almost no resistance to reverse engineering or controlled environment attacks.

39:42.050 --> 39:57.150
So this kind of raises the question of how today we find ourselves in a dilemma between... it's been here since the beginning of IT.

39:57.370 --> 40:04.350
So we have to marry speed and we have to marry security because people want things in production for yesterday.

40:04.730 --> 40:13.290
So even though we've been asking ourselves this question for a long time, it's even more pressing today because we are in the AI era and everything is going even faster.

40:14.030 --> 40:27.910
So I hope that all the time we save by automating our task, we will be able to invent solutions that we have no longer to chase for security, but instead we will anticipate risk.

40:30.130 --> 40:36.810
And so I wanted to quickly mention all the standards and frameworks that we need to take into account when we are doing a pen test.

40:36.830 --> 40:39.070
You can see them on the screen.

40:39.810 --> 40:45.490
And so today we also need to add standards for AI and some for security.

40:45.510 --> 40:48.670
And also I wanted to do a quick mention of trustworthiness.

40:48.730 --> 40:50.810
It includes AI safety.

40:50.810 --> 41:01.350
So in other words, trustworthy artificial intelligence refers to artificial intelligence that all stakeholders can trust throughout its entire life cycle.

41:01.350 --> 41:03.970
So to achieve this, it must be aligned.

41:03.970 --> 41:10.310
So it means that it should be lawful, it should be ethical, and it should be transparent.

41:10.570 --> 41:13.330
And also explainable and robust.

41:13.530 --> 41:21.330
And so for example, when we test a model for an adversarial attack, we are checking its robustness.

41:21.330 --> 41:28.070
So this determines how well the model can handle slight changes to its input without producing a different input.

41:28.070 --> 41:34.450
On the other hand, bypassing safety measure with prompt injection will test the model's alignment.

41:35.030 --> 41:39.350
So I'm not going to go further on this.

41:41.840 --> 41:53.600
I just wanted to say that this is why AI pen test isn't just a technical process anymore, but more a holistic and socio-technical one.

41:56.740 --> 42:00.620
So I wanted to conclude on the attack phase by giving a general tip.

42:00.620 --> 42:09.400
When I do my pen test, I really like to use checklists because it gives me a way to stay on track and to make sure that I cover as many aspects of the target as possible.

42:09.400 --> 42:14.900
So the top tens are always a nice thing you can add into your list.

42:15.640 --> 42:18.000
And these are all basic checks.

42:18.520 --> 42:24.300
And also every context is different, so in this AI era, we have to be even more careful.

42:24.380 --> 42:34.360
And the traditional approach isn't enough anymore, so we also need to test mobile vulnerabilities, AI vulnerabilities, and API vulnerabilities.

42:34.360 --> 42:36.520
Lucky for us, all of these have a top tens.

42:37.640 --> 42:41.380
So you just have to customize your checklist.

42:42.320 --> 42:43.300
It sounds easy, but...

42:47.920 --> 42:52.640
So when you do traditional Android pen test, the report stays the same.

42:53.080 --> 42:57.840
So I have to wrap it up, but it should look like what you see on the screen.

42:58.460 --> 43:01.620
And for AI vulnerabilities, the scoring is different.

43:01.620 --> 43:07.040
So we can use the AIVSS score, and it was published recently by the OWASP.

43:07.040 --> 43:22.840
And just because I cannot and I have to be done, this is the famous QR code that you can have to get the resources, but you can also take a picture so you don't have to scan something shady.

43:25.490 --> 43:27.970
Thank you very much for coming.

