Automatically Send Email from Android App through Exchange Server - android

Has anyone tried sending emails automatically (without user interaction) from your android app through exchange protocol? I saw a lot of examples through SMTP and they are working perfectly. But I am wondering if it's possible to send using Exchange protocol? Does android allow to build our own exchange client?
Are there any libraries to use? Or should I build from scratch? If so, can anyone point me a good starting point?
Can anyone give me a lead? any idea? any suggestion where to start looking at? or anything?
Thanks,
Karthik

The exchange protocal (depending on how things are set up) is nearly always RPC over HTTP/HTTPS as a mobile user. ActiveSync is the alternative but has few advantages.
An issue you may come up against is MS Exchange has client access policies that require the Exchange server to have certain amount of control over the phone (Mandatory PIN Lock, remote wiping of phone etc that probably need root access). There are also Certificate trust requirements.
If you are developing an in house platform it may be quicker to look at IMAP which exchange does reasonably well.

Related

What information gets site from mobile users

I have question about mobile visitors. What information can a website administrator get from mobile user?
For example: when I visit www.site.com from my phone device (I use mobile internet, not WiFi)
what they will know about me? Can they can get my mobile number, imei code, or mobile device information?
This is kind of a broad question, but I will try to explain briefly the general concept.
First of all it's fundamental to understand what a connection is, and what a protocol is.
A protocol, briefly said, is a way the two objects communicate in. I would recommend you to watch this playlist.
https://www.youtube.com/playlist?list=PL6gx4Cwl9DGBpuvPW0aHa7mKdn_k9SPKO
Now about the connection. The connection by itself involves all the path from you/your device to the server you need to communicate with, and thus, summarising these two, we can make a basic conclusion. The server can gets your IP address, which is due to the connection concept, and also info about what program exactly do you use, because of the protocol. The protocol may require your program to send lot's of information from it, but if we are talking about web browsers, they do not share the users private information for privacy and security reasons.
That's it, I hope I could help you somehow.

Peer-to-Peer between desktop and mobile app

Starting to build an app where we will have a desktop and a mobile client applications. These two apps will exchange messages/info on frequent basis. The idea is not to have any server/central entity for this communication. We want to send/receive messages without any server implementation. I googled on these and got peerjs.com, openpeer.org and google project apprtc. Peerjs and apprtc are kind of web based applications which are not in our kind of.
But still it's not very clear on how this things works out as they involve any server or not. Kind of stuck and not sure where to start and how. Is it possible at all?
We are not yet tied to any platform, so open to any kind of implementation. Please share if you have any similar experiences of any applications using this kind of technical stack?
use webrtc ios project, and its what you need
https://github.com/gandg/webrtc-ios
Sockets is what I'd use, assuming the network requirements mentioned above
Those two devices may or may not be on the same network.
Then you need a server of some form, whether you want one or not. That server may simply be a data broker (see PeerJS) or provide more functionality, but it must exist. That server may be one that you host yourself or be some common cloud provider, but it must exist.

C2DM "app server" options

This is an edit of a question I asked about a week ago.
I'm working on an Android app which communicates with the users' home PCs to control some 3rd-party PVR software running on the PCs. The model is as follows...
Android app < - wifi/3g -> Windows Service <- localhost -> 3rd-party PVR software
The Windows Service is written by me (C# .NET) and acts as a proxy between the Android app and the PVR software.
What I'd like to do is use C2DM to notify users of various things - one example is if one family member sets a TV show to record, a C2DM message is sent to other family members' devices so everybody is up to date.
I now seem to have 3 possible options for how to proceed. The Windows Service is a key player in the system so plays a part in them all but I don't know what the best approach is.
Use the Windows Service as the C2DM 3rd-party app server. Downside - I need to embed my C2DM credentials into the software and there will be potentially 100s of servers around the world requesting authentication tokens (not sure if Google would allow that).
I have a hosted web server I could use which allows PHP/MySQL. The Windows Server would simply act as a relay but my PHP experience is minimal and I can't find any comprehensive PHP examples for C2DM.
Use Google App Engine (again with the Windows Service as a relay). The problem is I don't know if Google are happy with GAE being used as a C2DM app server although I've seen a few mentions of it.
I've basically Google'd until my head hurts and keep coming back to the same tutorials and partial code examples. I know how C2DM works and actually have option 1 working in my dev environment but it doesn't seem like a good option to go public with.
So (trying to keep my question as objective as possible)...working on the principle that option 1 is not a good idea, are there any reasonably comprehensive PHP examples out there for a C2DM app server or, alternatively, does anyone know definitively if GAE is an acceptable approach?
With C2DM you can target the device that the message goes. So in you example the one that sets the TV show sends a message to the Windows Service to notify each one of the other users.
You can do that with 1 C2DM server
UPDATE
I whould go with the 3rd server.But of what i can tell you are not sure about the structure. Shared now GAE later maybe finally ec2. What can you actualy do is to create a CNAME that points to the server of choice.(less hard coded). I don't think that GAE cannot be used for C2DM. It's a simple server with http requests.

Android phone to Chrome communication and Google OAUTH

Alright I have two questions which are interrelated.
Using Google OAUTH can I send communications between an android phone and a chrome browser extension? I was thinking that I could write some info somewhere and it would be stored in the account info or something? This was just a theory (not really supported by any info I have read)
If that doesn't work I was going to use Android to node.js communication idea using http://static.brandedcode.com/nws-docs/ documentation for an android to websocket server communication then a chrome extension to the websocket server. I was then going to use the gmail from each device to verify they belong to each other and pass the message that way.
Does anyone have any knowledge about how feasible this is/how challenging it is? I also need to know how secure the communication is if I only rely on a gmail account. Is there any information done by using OAUTH or another method that I could use to secure it more?
Finally is there a method to turn a chrome extension into a websocket server? That way I could just bypass the need for an external server and any sort of verification method.
I'm willing to do some work and/or research if necessary so list anything you think I should look into and any ideas you might have. I'm thinking of having a nice coding weekend so I will be playing around with this A LOT!
I appreciate any help that anyone can give.

Android: Verifying the application's integrity on the server side

I'm writing an Android app that communicates via HTTPS with a server application. On the server side, I have to be absolutely sure about the Android app's integrity. This means that the server app needs to be sure that it's communicating with the Android app that I developed and not with a re-written one (e.g. after decompiling the original app or after having rooted the device).
Is there a possibility to ensure that? Maybe there is a possibility with the signature of the apk file?
Any hint is appreciated.
Regards,
Peter
You are trying to address a known problem:
You can never trust an application on an open device (mobile phone, desktop computer). In order to trust it, it should be tamper proof. An example of such device is a SmartCard. Mobile devices are certainly not it.
You should never send data to device that user is not supposed to see. The implication of this is that all business logic must be done on the server.
All requests to the server should be authenticated with user's credentials (username/password) and made via a secure protocol (HTTPS/SSL).
No way. Whatever is in user's hands, is not yours anymore. Even if you somehow manage to transfer the APK to the server for validation, nothing prevents the hacked program send an original copy to the server.
In order to validate that your software is running, the client devices need to be able to provide remote attestation services, which is one of many piles of acronyms in the TPM world. I found that someone has been working on providing TPM services, including IBM's IMA, which is almost good enough for what you want.
Details here: http://www.vogue-project.de/cms/upload/vogueSoftware/Manual.pdf (Google Quickview).
Of course, this is emulating the TPM, and requires patching the Android kernel. But perhaps one of the various manufacturers would be willing to build a model with the TPM hardware included for you?

Categories

Resources