Hooking loadlibrary - Xposed General

I have a hook that redirects the loading of a library to the sdcard or any other location and it works fine mostly fine (like if the app has sdcard read or I have to put in hooked applications data folder). But what I would like to do is redirect this to a library that is packaged within my xposed app apk install location. There seems to be a couple problems with this though.
1) Since I'm within a hook, how do I get the location of my library(since this may change with different phone builds)
2) Android doesn't allow application to access resources from other application for obvious reasons. If I'm within the hook what would be a elegant way of access this. I have permission injection but I feel like this is convoluted(mostly because it requires a reboot).
And ideas would be greatly appreciated, ty!

Related

[Q] windows share via mapped drive

Hi,
Is there a way to create an SMB connection to a shared windows folder and create a permanent map to say a virtual folder on the sdcard that can be accessed from within other apps?
I'd like to be able to access a windows shared folder from within other apps, specifically office apps (quick office, office pro) rather than having to use ES File explorer or the like to access the files first.
I've used google docs via the office apps which is great, but need to find a way to access local network files on a per user (login) basis for apps.
Thanks
The only thing I have found that works OK is CIFsManager.
It is a pain to launch on VEGAn 5.1 beta (I can't launch it from the app drawer, I have to go into Market or Titanium Backup to start it), but it works to map drives over so my multi-terabyte store of video and music files on my home server are "local" files.
The app mounts the shares under /mnt/cifs/<share-name> by default, but you can mount them anywhere I think. If you are not using VEGAn 5.1 beta, make sure your ROM has cifs.ko capability (can probably check the release notes for whatever ROM you are using). If you are using the stock TnT, I am not sure if CIFsManager will work, but it might work with one of the enhancement packs for the stock image.
If you hve questions you can PM me or just post back. I'll check the thread again later today.
Weird....I use VEGAn 5.1 beta and have no problems launching CIFsManager from the app drawer or the shortcut on the homescreen.
huntar said:
The only thing I have found that works OK is CIFsManager.
It is a pain to launch on VEGAn 5.1 beta (I can't launch it from the app drawer, I have to go into Market or Titanium Backup to start it), but it works to map drives over so my multi-terabyte store of video and music files on my home server are "local" files.
Click to expand...
Click to collapse
Thanks Huntar,
Works a treat, although I do get the same issue you report, unable to launch from the app drawer, have to launch from the Market. Be interesting to get to the bottom of that (i'm running vegan 5.1 beta also)
Now I need the next step, which is to provide a simple interface to get users to 'login' to their shared folders then 'logout' once finished. It's a multi user per device scenario, thus need the ability to have dynamic mapping per user...
Any ideas or developers willing to write something? Can be paid development if anyone is interested....?
Nik
That is definitely a lot of heavy lifting if the device is used my multiple people with different access rights. My scenario is simple as everyone has full access to the media server.
I don't understand the launch issue, I have uninstalled and reinstalled, tried different things, but can't get it to launch from the app drawer or a shortcut.
Good luck, I'm sure that someone here (I'm NOT a programmer) can whip up something to script out the drive mappings. You might try a more general Android development thread elsewhere on XDA, you might have better chance of finding that programmer.
You might look at Mount Manager also... seems like it might work better, as it can mount shares based on location and task (with the paid license) triggers. I just found it in the Market while I was twiddling with the CIFsManager install. I might try it myself as CIFsManager is tedious even for me.
Permission Denied
I don't mind the launch from Market (as I have the same issue, tnt lite 3.1.4, with clemsyn #77 kernel). I put in the address and share name, which I can log into my router and pull all that info as the hard drive is connected to my router, and when I try to mount I get Permission Denied?? Thoughts?
msieg080 said:
I don't mind the launch from Market (as I have the same issue, tnt lite 3.1.4, with clemsyn #77 kernel). I put in the address and share name, which I can log into my router and pull all that info as the hard drive is connected to my router, and when I try to mount I get Permission Denied?? Thoughts?
Click to expand...
Click to collapse
Any help on getting this working? I too have the marketplace launch issue (not a big deal) but eveytime I try to mount I get a no such file or directory error. I am used to CIFS in Windows so what am I missing?
Thanks!
huntar said:
You might look at Mount Manager also... seems like it might work better, as it can mount shares based on location and task (with the paid license) triggers. I just found it in the Market while I was twiddling with the CIFsManager install. I might try it myself as CIFsManager is tedious even for me.
Click to expand...
Click to collapse
Bought it and like it so far - works better then CIFsManager but then you get what you pay for - you hope.
I installed two free apps - "es file explorer" and "androexplorer", interesting enough I had to leave user name and password blank, but then I was able to get my network drives!!! Works great!
I am trying to get mountmanager to work, but it is FC every time and seems like it will not load the module. CIFSmanger works, but I can't get mount manager to do anything but crash
TNT 4.2.3- Clemsyn Kernel
Not sure what happened, but it's running now. Some crashes but it would not even run before.

[Q] Can I hook methods in ContentProvider?

I'd like to hook the query() method in ContentProvider in order to get to know which applications are accessing the personal information(e.g: contacts, sms) stored in the device. By reading the tutorial, we know that we can hook methods in app packages. However, what can we do when the methods we want to hook are in those system components? Any suggestion is appreciated.
x11911778 said:
I'd like to hook the query() method in ContentProvider in order to get to know which applications are accessing the personal information(e.g: contacts, sms) stored in the device. By reading the tutorial, we know that we can hook methods in app packages. However, what can we do when the methods we want to hook are in those system components? Any suggestion is appreciated.
Click to expand...
Click to collapse
Well first off, you can't hook ContentProvider.query() because it's an abstract method (at least one of the two variants). So you would have to hook the subclasses that provide an implementation for this method.
You would also need to clarify what you mean with "system components". I think some of these providers are implemented in system apps, so you would hook them like any other app. Others might be part of the system process (system_server), which also hosts all the system services like package manager etc. Simply use the special package name "android" for these, otherwise handle it like a normal app. And then there might be cases where you want to hook a Android framework method on the whole system. You would do that in initZygote().
In all cases, you would first have do identify a good place to hook into, then find out when to place the hook (as described above) and then use findAndHookMethod().
rovo89 said:
Well first off, you can't hook ContentProvider.query() because it's an abstract method (at least one of the two variants). So you would have to hook the subclasses that provide an implementation for this method.
You would also need to clarify what you mean with "system components". I think some of these providers are implemented in system apps, so you would hook them like any other app. Others might be part of the system process (system_server), which also hosts all the system services like package manager etc. Simply use the special package name "android" for these, otherwise handle it like a normal app. And then there might be cases where you want to hook a Android framework method on the whole system. You would do that in initZygote().
In all cases, you would first have do identify a good place to hook into, then find out when to place the hook (as described above) and then use findAndHookMethod().
Click to expand...
Click to collapse
Thanks a lot, that really helps~
Problem
would you mind give me a example (like a code) about how to hook the query() method? I really confused about that. Thanks a lot!!!!

how to create task that will monitor system wide app installation...

so basically i want to monitor system wide app installation and uninstallation, including sideloading with dates? if possible to have it create a log and store it in a specific folder that is locked or can't be accessed or deleted without code. and to do a daily or weekly check to see if any changes were made.
also is there a task to block all installations including sideloading?
any help would be appreciated.
@ktmom
So tracking installed and uninstalled apps is straightforward.
I'm not aware of a way to lock the resulting file per se. Encrypt it, probably. But to prevent any other app from accessing it, I don't know how to do that. It could be uploaded to the cloud, e.g. Google drive. Then the local copy deleted. That's kinda fussy. Saving it as a variable array is doable, then Tasker can be locked.
If on every install / uninstall, the log is updated, why does there need to be a daily/weekly check?
I would have to test and see if the package manager can be "locked".
Is the device in question rooted?
This kinda sounds like something I might do to my kids phone [emoji6]. If this is actually the case, the file could be sent to your device or email on update. It wouldn't matter if the local copy was edited. You also could know immediately if an app had changed.
I asked in the other thread, do you have any familiarity with tasker?
@ktmom
device is non rooted,
file sent to email would be fine if that will get rid of daily/weekly checks. (<--- this was just something I wanted that maybe i'll just use in notepad++ to highlight the differences for a quick way of seeing changes.)
i have dabbled in tasker many years ago, only to enable/disable wifi and turn on vpn in geo fenced locations.
I haven't forgotten you. I should post a solution by the weekend. I'm just spending some time to make sure the kinks are out. You will need the MailTask plugin. I personally use a script in termux (requires cURL) to send via Google servers, but that is harder to setup, particularly with OATH. The plugin makes life much easier.
ktmom said:
I haven't forgotten you. I should post a solution by the weekend. I'm just spending some time to make sure the kinks are out. You will need the MailTask plugin. I personally use a script in termux (requires cURL) to send via Google servers, but that is harder to setup, particularly with OATH. The plugin makes life much easier.
Click to expand...
Click to collapse
ok great, thank you!
@BobMcGeez
Finally, I think I have this stable and able to handle multiple consecutive app installations and removals. I am working under the assumption that the use for this project is to monitor possible dangerous activity on a child’s device. I do not condone the use of this for monitoring a device without adult consent.
This project will send an email notification when a new app is installed or an existing app is removed. The email will include a CSV file with the remaining still installed apps. It should ignore apps that are being updated (they remove then install). The emails are sent silently and there should not be any indication to the user this is happening in the background. The CSV file is saved in the {storage}/Tasker/tasks/ directory. Each time an email is sent, the stored file is also updated. One instance of the previous file is saved as well.
First, you need MailTask installed. Please ensure that the MailTask plugin is fully configured and tested before installing this project. We are using OAuth Gmail authentication, so ignore SMTP stuffs.
Also, IMHO, I would use a GMail account maybe even created for this purpose, but at least one not setup to routinely access by the device user. This way, the user’s account will not reflect the sent messages.
To configure and test MailTask
Open MailTask from the app drawer on your device
Perform “Authorize Gmail Access” Use the account for the “from” you want to use in this project
Perform “Grant access to primary storage”
If your device has an SDcard, perform “Grant access to Sd card”
Now if you want, you can create a task in your Tasker installation to test the MailTask plugin
Create a test task
Add a MailTask action (Plugin -> MailTask -. send email)
Configuration:
From = Account used to Authorize Gmail Access above
To = Account where to send email
Subject = Testing MailTask
Body = Some text to take up space
Attachments = choose a basic file using the paperclip icon just for there to be an attachment
Test plugin by manually running the task.
If all is good, you can delete this test
Now install the project (taskernet link). On install, accept enabling the profiles. If you do, then the Installation task should run automatically. If you prefer not to, or if you need to re-run the installation, manually run the “Initial Setup” task.
This project may be shared under GNU v2. You may share, modify and use it provide you don't charge, the code is open and credit is provided.

[APP][NST/G] Mantano Reader [MOD]

Edit 1-8-23: I've updated the Mantano apk file. Seems there were still some issues with the aspect ratio of the default.png (book cover) image. Fixed now at 1.5!
I keep my NSTG on FW 1.2.1 because there are issues with Tasker and plugins on FW 1.2.2. The resulting apps are OK, but development is a problem unless I do it on FW 1.2.1. So that one device has B&N apps removed. AlReader has been my go-to reader app. Until now.
While working on some thorny issues with a Tasker app update I came across a book I wanted to read. Unfortunately it was only available in PDF format and AlReader can't handle that. I soon found that something like EBookDroid really couldn't deal well with a PDF file that begged for text reflow (problematic as that is). I wanted something that was at least as good as the stock reader. I could have just picked up one of my other NSTs and read the book that way, but when you abandon the B&N system you should at least break even, not lose. So I went searching through the forum for some ideas.
Mantano Reader caught my interest. Not only can it reflow PDF text (pretty much like the stock reader-don't get too excited), it can also display PDFs as a continuous scroll, with zoom. It can handle Adobe DRM books! And the TTS works (not a big deal). So I looked around and started with version 2.2.12 from Apkpure. This is the last version for Android 2.1. I found that full-screen reading was broken in this version and I couldn't see why, so I worked my way back until it wasn't broken. That was version 2.2.3.
Not for everyone
Those are some of Mantano's virtues, but it's not for everyone. I think it's chief drawback is the absence of full font support. There is only the default (admittedly not bad) and although there is provision for user fonts, there are issues. More on that later. Then there is the really tiny user interface. The colors render somewhat muddy on the NST also. Those are really tough issues to address, certainly beyond my pay grade. Also, none of the syncing, cloud, downloading of dictionaries, OPDS books, fulfilling of .acsm files, additional fonts, user manuals, etc., works. Can't be fixed. I looked. Finally, the reader options are pretty simple, about what is available for the stock reader (except for fonts). So if you like the hundreds of setting combinations in something like AlReader or FB Reader, this app is not for you. If you want something straightforward so you can just read a book without all the B&N hoopla, Mantano may be worth a look.
Mods
When I started getting serious about this I decided to try to learn by doing. My goal was to remove (or at least hide/disable) stuff that did not work. Almost all of my modifications were in the resources folder of the apk file. There was also one annoying issue with the aspect ratio of book covers that required a minor change in two smali files (thanks to @Renate). Here's a short list:
1. Removed Bookstore (OPDS) tab on home screen (formerly "My Catalogs" as described in User Guide)
2. Removed menu icons for sync and cloud
3. Disabled sections in Settings that don't work (Login, Sync, Dictionary download, Fonts, User Manual download)
4. Corrected font colors in some local dialogs so text is visible
5. Made the page number black, smaller, and with a transparent background for less visual distraction
Also, there were a few dialogs with invisible text that used the system framework to generate the window. The only way to fix this was to make a few very minor changes in framework-res.apk. This worked well and even helped with a few other apps that formerly had invisible text. A win-win. You can update your framework-res.apk using the CWM zip provided below. Despite its filename, it is not an "update" zip. You'll just be installing a zip file with CWM.
Making do
Overdrive Library epubs: No app will be able to fulfill .acsm files on the NST/G. The SSL is just not up to it. So there's no point in registering the device with Adobe. That just wastes one of your allowed devices and so I disabled that first Settings selection. However, the app can read Adobe DRM books, understands due-dates, etc. You just need to introduce your device to ADE running on your PC (ver. 3.0 works well for me on Windows) and transfer fulfilled books from there, just as you would with the stock reader.
Fonts: You can, in theory, supply your own TrueType fonts and place them in /sdcard/Mantano/fonts. When a book is opened, the lower menu options include "Themes". This odd term is for adjusting the appearance of the book (fonts, margins, justification, line spacing, colors). You can make a new theme or edit the default one. Either way, you will get to select a font. You will see the font you added in the folder (you can copy any font you like from /system/fonts or from anywhere else). The problem is that Mantano has no way to deal with font families. For example, I prefer Malabar. Of course, there is the base font, the bold instance, italic, bold italic. Mantano makes you choose one of these. Clearly you choose the base font (no need to copy over the others). If there are italics or bold type in a book, the reader uses the default font. This would not be such an issue for small sections of emphasized text, but the font scales are not the same. Malabar is larger than the default font. So any italics is obviously smaller. I tried a software package for scaling the font but it just turned it into rubbish. I am learning to like the default font. This issue was fixed in version 2.4.6, based on what I've read. But that won't run on the NST, of course.
Dictionaries: The reader has the ability to go out to find definitions on the WWW. Big pain. Although you can't download any dictionaries from within the app, Mantano does play nicely with ColorDict and there are plenty of dictionary options for that. Easy fix.
User Guide: I poked around and found a guide labeled "Version 2.1". That was the best I could do. It seems pretty close, although what was the "Bookstore" tab in this version (which I have removed) is referred to as "My Catalogs" in the manual. Either way, it's non-functional and gone. The same goes for references to cloud, accounts and sync. None of it works and all of it has either been removed from view or disabled in this mod.
Extras
Unlike AlReader and FB Reader, Mantano's main activity is the library view. That means there is no simple way to use the "reading now" status bar button to go directly to your current book.
I also like to be able to use the current book cover as a screensaver. AlReader and CoolReader both have this capability. Mantano does not, but it does create thumbnails for each book (if you let it) and one of those is screensaver size (default.png). For some unknown reason, all the thumbnails of various sizes for display in the library have the correct aspect ratio except for default.png. I fixed this in the app with a view to using it as a screensaver image.
To address these issues, I have used Tasker to create two small apps. Mantano_Extras1 enables a listener for when the reader is closed (either by two presses of the back button or simply by pressing the "n" button). When that happens, the Mantano database is queried for the last reading point/book. This is stored in a variable. Accessing Mantano_Extras1 after setup sends a command to open that file. If Mantano is your default app for epubs and/or pdfs, the book will open automatically to the right place without passing through the library. Thus assigning Mantano_Extras1 to the "reading now" button with NookTouch ModManager restores the function of that button.
Mantano_Extras2 does everything described above. During setup it also creates the folder /media/screensavers/CurrentBookCover. When the reader is exited and the database information stored in a variable, it copies the default.png for the current book to that folder. If you select that folder in your NST Settings app for the screensaver, the current cover will be displayed during sleep.
I should add that both apps check to see if the current book has changed before they do anything. If there is no change, they simply stop.
As these are Tasker-generated apps (but don't require Tasker to run), they have a dependency on two small library files. If you don't have one of my other Tasker apps already, you need to copy the two files in the zip as below:
/system/etc/permissions/com.google.android.maps.xml
/system/framework/com.google.android.maps.jar
Set permissions for both files to rw-r--r-- and reboot. Without these files resident, the app will not install.
The apps also use sqlite3 and busybox. If you rooted with NookManager you already have busybox. A few other special packages probably include it. If you have it, you will find it in /system/xbin. If it's not there, copy the file from the zip to that location and set permissions to rwx-rwx-rwx.
If you don't already have sqlite3, move the file from the zip to /system/bin and set the permissions to rwx r-x r-x.
When you have prepared the way, reboot and then install whichever of the two "Extras" apps you want. When you first tap on the app icon there will be a pause while things are set up and then a request for root access. Once that's done they are good to go. Use NTMM to assign the app to the "reading now" status bar button and set your screensaver directory to "CurrentBookCover" (if you installed Mantano_Extras2).
This is nice work. I have heard good thing about Mantano reader before. I believe it still exists although under new name I think. Its sad that you had to remove app options to make it work on NST. Still I am glad that you make some improvement that could if exploited properly make this device better than before. I believe that solving invisible text message is best of what you did and if understood properly can make number of apps that had this problem before usable again for this device. I would not dismiss even TTS working as I remember that someone tried to implement that on NST before yet I do not remember it was solved. So if it work out of box with Mantano reader it might be prudent to see what makes it work if it is fine TTS not some hardly intelligible sound generator. This options you removed how did you confirmed that they are not working? For cloud I believe it was NST lockout and now enforced TLS1.2 it can not reach that gives you hard time. Yet for syncing it is little harder to understand. For the rest like OPDS and such I guess my knowledge is not sufficient to guess how that even work so if you know more than me I am more than ready to listen.
SJT75 said:
I believe it still exists although under new name I think.
Click to expand...
Click to collapse
Now Bookari.
SJT75 said:
Its sad that you had to remove app options to make it work on NST.
Click to expand...
Click to collapse
I didn't so much remove options to make it work. It worked as-is, but not the login/download components, and they are not necessary for the reading functions.
SJT75 said:
I believe that solving invisible text message is best of what you did and if understood properly can make number of apps that had this problem before usable again for this device
Click to expand...
Click to collapse
It's possible. I noticed improvement in dialog boxes for ES File Explorer. But there are other types of dialog boxes and I only dealt with what was needed for this app. Spillover is a gift.
SJT75 said:
I would not dismiss even TTS working as I remember that someone tried to implement that on NST before yet I do not remember it was solved. So if it work out of box with Mantano reader it might be prudent to see what makes it work if it is fine TTS not some hardly intelligible sound generator.
Click to expand...
Click to collapse
Well, that could have been me. Pico TTS (if not removed) always worked on the NST if you downloaded some voices. I have a post about this somewhere with links. But the quality is really wretched. I looked at this further awhile back and found that Google TTS began with Android 2.2 (of course). There is a "bridge" system involving a custom settings app but each application must include this custom code to work. I did a MOD for AlReader to enable this, but it's not easy and would be (nearly) impossible for Mantano as very few of the smali files have descriptive names. Most are just "a.smali, b.smali", etc. So it's really difficult to track down what you want.
SJT75 said:
This options you removed how did you confirmed that they are not working? For cloud I believe it was NST lockout and now enforced TLS1.2 it can not reach that gives you hard time. Yet for syncing it is little harder to understand. For the rest like OPDS and such I guess my knowledge is not sufficient to guess how that even work so if you know more than me I am more than ready to listen.
Click to expand...
Click to collapse
It's not all SSL. Or it may be that also. The URLs in the apk file don't go anywhere, even on my PC browser. So far I've gotten up to version 4.5 and still no working URLs. Perhaps when Bookari emerged as the name the old URLs were abandoned and the old Mantano apps became crippled in this way.
Thanks nmyshkin you clarified some things. I agree that change to new platform and abandoning the URL domain for cloud use could be cause for that option not functioning anymore. Yet unless the syncing have not be performed through a same route (login account on the same domain) sync should function fine from one device to another for example. About the rest you are correct I have come to a same conclusion that even slight upgrade of Android on this device would make vast improvement in options available to exploit. Sadly B&N did not go that way. I will look upon PicoTTS to see if something about the way it actually work can be understood to evaluate if it is worth the effort or it maybe can be discarded as irrelevant for this device.
Just crossed my mind... nmyshkin did you tried to hunt down inside apk file exact spot where that URL is written/coded and change it to something else like IP address of your computer/drive/*/*/sync folder ?
SJT75 said:
Just crossed my mind... nmyshkin did you tried to hunt down inside apk file exact spot where that URL is written/coded and change it to something else like IP address of your computer/drive/*/*/sync folder ?
Click to expand...
Click to collapse
No, it didn't occur to me. I only read on one device so that's not the kind of thing that interests me. Also, I just transfer books over from my PC to the Nook when I get them, usually via FTP.
I did see cloud, sync, etc., URLs but I suspect that just changing them would not produce the capability you seem to be hinting at. It's likely a lot more complicated than that. It seems to me that syncing implies active communications from both ends. Teaching your PC to respond to the overtures of the Nook would be a whole other rats nest.
You are correct. Using URLs to connect to PC is not safe. Therefore some home workgroup network or SFTP access are more reasonable way. Maybe if you change cloud sink URL to Dropbox folder you get something?
SJT75 said:
You are correct. Using URLs to connect to PC is not safe. Therefore some home workgroup network or SFTP access are more reasonable way. Maybe if you change cloud sink URL to Dropbox folder you get something?
Click to expand...
Click to collapse
I don't think so. The app innards were designed for negotiating with certain remote servers and expect a certain dialog. Just changing the URL doesn't address these issues. Using Dropbox as an example, there are login credentials to be supplied and other issues to be addressed before files can be freely moved in either direction.
Well yes unless dropbox folder is public shared one what I wrote will not work. What if you link sync/cloud to internal folders on device inside Dropbox application that also initiate script written to execute Dropbox synchronization? Then login credentials would come from Dropbox app I think.
SJT75 said:
Well yes unless dropbox folder is public shared one what I wrote will not work. What if you link sync/cloud to internal folders on device inside Dropbox application that also initiate script written to execute Dropbox synchronization? Then login credentials would come from Dropbox app I think.
Click to expand...
Click to collapse
1. I am not a Java programmer. What you are suggesting is going to require significant changes in the app. It's not in the same league as the modifications I made.
2. I have no interest in the feature. People who must have synchronization with myriad other devices would be better served by selecting an app that currently has this feature working (like FB Reader).
3. If someone who is a Java programmer and is interested in this feature wants to take a crack at it, more power to them. I personally think it's a dead end. Just about the time you get it figured out, Dropbox will no longer work on the NST. Any modification that relies on exchange with an external commercial server has a built-in self-destruct timer, just waiting for tightening external server access rules. It's over for Android 2.1.
nmyshkin said:
Just about the time you get it figured out, Dropbox will no longer work on the NST. Any modification that relies on exchange with an external commercial server has a built-in self-destruct timer, just waiting for tightening external server access rules. It's over for Android 2.1.
Click to expand...
Click to collapse
Amen to that. Making NST more cooperative with Calibre is much better option anyway. Commercial server could be also a trap. There was an outcry when Remarkable for example started charging access to their services out of blue and without warning.

Access dynamic data within the hook

What is the best method to pass some data to the hooked method in recent android versions?
I want to set some variables through ADB and I thought I could simply add a file with the variable contents.
As I understand, the method runs as the App I am hooking so this does not seem to be trivial.
File access is most likely limited.
I have seen people use shared preferences by setting MODE_WORLD_READABLE but this does not seem to work anymore in recent versions.
It could be possible to use a ContentProvider but I think here it is needed that the hooked app requests permissions in the AndroidManifest for this to work since Android 11.
Is there a method that is still usable?

Categories

Resources