idea for a framework - Off-topic

hello,
what i dont like about developing apps for phones is that you dont have such a broad choices of programming languages
here is the idea to circumvent this:
progamm a phonegap app that exposes its api to a certain web server.
the actually app code is on the server.
we only need some sort of bridge to use the javascript from the web server script
what do you think?

nomoral said:
hello,
what i dont like about developing apps for phones is that you dont have such a broad choices of programming languages
here is the idea to circumvent this:
progamm a phonegap app that exposes its api to a certain web server.
the actually app code is on the server.
we only need some sort of bridge to use the javascript from the web server script
what do you think?
Click to expand...
Click to collapse
Way too serious for off-topic. Maybe the other programming sections?

Related

TOR (The Onion Router) for android?

anyone heard of a tor (http://www.torproject.org/index.html.it) porting to android? do you know about such similar project for the android platform?
thx
fl3xo said:
anyone heard of a tor (http://www.torproject.org/index.html.it) porting to android? do you know about such similar project for the android platform?
thx
Click to expand...
Click to collapse
I suspect something malicious seeing as how that link ends in .html.it
xsnipuhx said:
I suspect something malicious seeing as how that link ends in .html.it
Click to expand...
Click to collapse
its just a language thing.
Just go here: http://www.torproject.org/index.html
.it prolly stands for Italian.
xsnipuhx said:
I suspect something malicious seeing as how that link ends in .html.it
Click to expand...
Click to collapse
sorry, i'm of italian language.
fl3xo said:
anyone heard of a tor (http://www.torproject.org/index.html.it) porting to android? do you know about such similar project for the android platform?
thx
Click to expand...
Click to collapse
There's nothing to "port". You download the source, compile it for ARM, run it, and configure your system to use it. Should work fine.
Note: You don't actually need to run tor locally on your phone if you don't want to... you can actually forward a port over SSH to some tor server (i.e., your home computer).
U're absolutely in right. Tor and provoxy, cross compiled for armv6, really works. It's really really slow, but i can't expect nothing more (i compiled various linux application for android, clamav for example, and they are all very slow).
The real problem is another. The default browser and other browsers found on the market, do not support SOCKS so i'm forced to set an HTTP proxy with provoxy.
Read https://wiki.torproject.org/noreply/TheOnionRouter/TorFAQ#SOCKSAndDNS can discover that's a real nonsense: compile tor, install it, but you're not anonimazed at 100% against a clever attacker.
any idea!?
Right... the problem is that in using HTTP proxy, it uses the system-configured DNS server, which means that there is the potential to trace your activities (at least partially) based on the DNS servers you look up.
Using tor-dns-proxy.py (not torDNS since it is a windonkey-only prog) as your DNS server should do the trick... two issues there though; 1) you need a python interpreter to run this -- either compiler fun, debian, or ssh tunnel, 2) Networking is a little funny on 'droid -- I'm not sure that replacing the 4.2.2.2->4.2.2.4's from the resolv.conf would actually do it. Probably not. There is a property (getprop/setprop) for DNS which will probably work. Alternative is you rewrite tor-dns-proxy.py in C and that should definitely work.
This is actually quite strange... 4.2.2.2->4.2.2.4 are public DNS servers owned by level 3 communications. The DNS server set in the system properties is the one set by DHCP.... can't quite understand the use of the L3C servers except maybe as a fallback? Or commandline programs bypass the 'droid systems and use the L3C servers whereas the 'droid apps use the DHCP provided servers, i.e. put something in there so that terminal apps aren't broken by unavailability of 'droid system DNS server...
About your performance issues.... I've always found the tor network to be brutally slow, are you sure it is a hardware performance issue and not simply the network?
fl3xo said:
U're absolutely in right. Tor and provoxy, cross compiled for armv6, really works. It's really really slow, but i can't expect nothing more (i compiled various linux application for android, clamav for example, and they are all very slow).
The real problem is another. The default browser and other browsers found on the market, do not support SOCKS so i'm forced to set an HTTP proxy with provoxy.
Read https://wiki.torproject.org/noreply/TheOnionRouter/TorFAQ#SOCKSAndDNS can discover that's a real nonsense: compile tor, install it, but you're not anonimazed at 100% against a clever attacker.
any idea!?
Click to expand...
Click to collapse
lbcoder said:
This is actually quite strange... 4.2.2.2->4.2.2.4 are public DNS servers owned by level 3 communications. The DNS server set in the system properties is the one set by DHCP.... can't quite understand the use of the L3C servers except maybe as a fallback? Or commandline programs bypass the 'droid systems and use the L3C servers whereas the 'droid apps use the DHCP provided servers, i.e. put something in there so that terminal apps aren't broken by unavailability of 'droid system DNS server...
Click to expand...
Click to collapse
I've confirmed that.... terminal apps use L3C servers from resolv.conf, 'droid apps use DHCP provided server, so if you run a tor DNS proxy locally, you can "setprop net.dns1 127.0.0.1", "setprop net.dns2 127.0.0.1", "echo "nameserver 127.0.0.1>/etc/resolv.conf"" ... etc.
lbcoder said:
About your performance issues.... I've always found the tor network to be brutally slow, are you sure it is a hardware performance issue and not simply the network?
Click to expand...
Click to collapse
I think because of static linking used for compiling libevent, openssl and tor source. I'm lack of free time to learn about ndk and android shared library, but probably this can be the first step to increase performance of a lot of application not specifically written for android.
With tor in background is quite impossible doing anything else.
I often use torpark for surfing (both win and linux version) and i think the incredible slowness on the phone is not justified by transit of streams on the onion network.
fl3xo said:
With tor in background is quite impossible doing anything else.
I often use torpark for surfing (both win and linux version) and i think the incredible slowness on the phone is not justified by transit of streams on the onion network.
Click to expand...
Click to collapse
Use a performance analyzer like top to see how much cpu your tor process is eating. Probably significant.
Using top, the tor load remains over 90%, even not actively surfing. What the mess?

How to make a website only viewable by android phones?

Does anyone know how to make a website that can only be viewed by an android phone? Like how the iPhone has websites only viewable by iPhones & iPod Touches? If you do can you post a tutorial on how it could be done? Thanks
Check the "User-Agent" from the HTTP request.
Short php code that switch the site (not tested, should work)
PHP:
<?php
if(preg_match("/android/", $_SERVER['HTTP_USER_AGENT']))
{
header('Location: androidSite.php');
}
else
{
header('Location: normalSite.php');
}
?>
Or you use getBrowser()
And then you have just to fit the design of the design or do what you want
The only way to actually stop non-android devices from accessing the website is to force the android users to install an android-only plugin to be installed in the browser (not supported by default browser) or to use a custom browser. Said plugin will authenticate with your service using only-you-know credentials, thus preventing any non-android device from accessing it. The user agent is REALLY REALLY simple to fake.
lbcoder said:
The only way to actually stop non-android devices from accessing the website is to force the android users to install an android-only plugin to be installed in the browser (not supported by default browser) or to use a custom browser. Said plugin will authenticate with your service using only-you-know credentials, thus preventing any non-android device from accessing it. The user agent is REALLY REALLY simple to fake.
Click to expand...
Click to collapse
If you want to be absolute about it, it would not be outside the realm of possibility to reverse engineer the authentication output of the hypothesized plugin and create a workaround. Furthermore, as the plugin would likely be an arm binary library, there's probably not that much preventing it from being run (reasonably) on any arm-based system.
user-agent is probably (i'm guessing) enough for what the OP has in mind.
Here you can generate your own script:
http://detectmobilebrowsers.mobi/
For example: iPhone devices redirect to ebay for buying a android device
and Android Browsers comes in.
PHP:
include('mobile_device_detect.php');
mobile_device_detect('http://shop.ebay.com/i.html?_nkw=android&_armrs=1&_from=&_ipg=','http://website.com/android.html',false,false,false,false,false,false);
Download the PHP script for non commercial sites here:
http://detectmobilebrowsers.mobi/#download
It may be possible to reverse engineer it (not necessarily in case it is actually well designed), but even if it is, it would be non-trivial, even if implemented by an idiot. Changing the UA *is* trivial, even to a complete moron.
And who says it has to be an arm binary library? Maybe go with something in javadroid instead.... and link it to the device IMEI... using a time-based crypto function that only runs on your server, i.e. device --> server crypto service --> device with magic enabler key --> web server authentication. You can make something REALLY MESSY that nobody would bother to reverse, and something that can only run in android (i.e. dalvik). Sure dalvik can be run on other 'nix systems, but by doing so, they become quasi-droid anyways...
jashsu said:
If you want to be absolute about it, it would not be outside the realm of possibility to reverse engineer the authentication output of the hypothesized plugin and create a workaround. Furthermore, as the plugin would likely be an arm binary library, there's probably not that much preventing it from being run (reasonably) on any arm-based system.
user-agent is probably (i'm guessing) enough for what the OP has in mind.
Click to expand...
Click to collapse

Permanent Ad Blocks in computer

I used a different way to block ads on my laptop using Google Chrome. This works differently from AdBlock. This is a manual way. A bit difficult to grasp hold off though.
So basically using Google Chrome's JavaScript console you take off the bits of code that represent the ads and the ads vanish.
I was wondering whether this could be implemented somehow in an application. This app would run the website. Then you would get a similar version of the Javascript console, you would take off the ads and then the app would let you access the rest of the website.
This could be an amazing add-on for a web browser.
Here's link to a How-to I made
http://www.youtube.com/watch?v=K59MI4e7J3w&context=C364178cADOEgsToPDskKvHDuKcmE4emuZg8UD6I7g
[PLEASE A MOD MOVE THIS TO A DEVELOPMENT FORUM] Sorry, did not realise while posting.
You should do some reading and learn (if you need to) Javascript (and jQuery) and look into writing a Chrome extension that would remove elements from a page with a right-click -> delete type action. Also, with Chrome you can get to the element much quicker. Right-click and do "Inspect element". It opens the dom explorer with the selected element highlighted so you can just right-click it and "delete node". Much quicker than manually scrolling through the dom.
Incidentally, the only problem with doing it manually is that the hidden elements are there next time you visit the site, or if you refresh the page.
Thanks. Im just a 17 year old kid with big dreams
Just working on getting my way around VB and Java. Will try to learn something about jQuery after my prelims end.
hateem said:
Thanks. Im just a 17 year old kid with big dreams
Just working on getting my way around VB and Java. Will try to learn something about jQuery after my prelims end.
Click to expand...
Click to collapse
If you're going to be doing some Java then that would be a good intro for JavaScript, which is a web based scripting language, but it has its origins in the same roots as Java so there are similarities in syntax.
I was an 8 year old kid with big dreams I stuck with them and I've now been working as a professional developer, writing windows software, mobile software and web applications for about 16 years. If it's what you want then stick at it. You're post proves you have the right mix of creativity and curiosity needed to persist with development. I just hope you're good at maths too
thanks it was helpfull
Blocking just the visible page content will never be a 100% proof. There are plenty of javascript ads that generate the content on the fly.
[email protected] said:
Blocking just the visible page content will never be a 100% proof. There are plenty of javascript ads that generate the content on the fly.
Click to expand...
Click to collapse
So you just hide it once it's generated. There's always ways round it. Just nothing generic.
hateem said:
I used a different way to block ads on my laptop using Google Chrome. This works differently from AdBlock. This is a manual way. A bit difficult to grasp hold off though.
So basically using Google Chrome's JavaScript console you take off the bits of code that represent the ads and the ads vanish.
I was wondering whether this could be implemented somehow in an application. This app would run the website. Then you would get a similar version of the Javascript console, you would take off the ads and then the app would let you access the rest of the website.
This could be an amazing add-on for a web browser.
Here's link to a How-to I made
http://www.youtube.com/watch?v=K59MI4e7J3w&context=C364178cADOEgsToPDskKvHDuKcmE4emuZg8UD6I7g
[PLEASE A MOD MOVE THIS TO A DEVELOPMENT FORUM] Sorry, did not realise while posting.
Click to expand...
Click to collapse
thanks for sharing this with us, this will come in handy
Archer said:
So you just hide it once it's generated. There's always ways round it. Just nothing generic.
Click to expand...
Click to collapse
If you don't mind do it on each page refresh, go for it...dealing with the source is the way to go, not like this.
I personally don't use Chrome, I prefer Firefox and AdBlock there works magic, it works at the root of the ads and also allows block visible parts on the page as well.
Revenue generation
You know you shouldn't really be blocking those ads as it helps pay for these sites, including xdadevelopers. Those ads are the key to keeping these very informative sites free to everyone. If there are certain advertisements that bother you, then I suggest finding something that blocks only certain ads, say just block popups but not the banner types.
I don't mind ads at all on websites like XDA and most others. I was referring to websites that ask you to complete surveys and select ads in order to reveal their content. I was frustrated with the general concept and the limitations that Ad blockers had.
The regular ad is ok, but ad infested websites is what I dislike.
They wish to monetise from the content they have, that is ok. But when people start getting greedy, that becomes a problem.

[Q] Hidden APIs to access public folders

Hi,
Write file access on Windows Phone 8 is very restricted. In fact 3rd party apps can only write pictures to the public picture folders. Other types, such as music, documents, or video folders cannot be accessed.
Are there hidden API calls available for accessing these folders (I am aware that applications using these APIs will probably fail Marketplace submission)?
Greetings,
Yes, there are but you need special permission from MS to use them.
Do you have more details about these API calls?
No...not really. I know there are APIs for everything we can't do as ordinary devs, but MS only releases these to certain groups (typically recognized development studios).
These include:
Native compiled APIs, to use with C++/C#
Appointment API (other than live calendar)
Bluetooth APIs
and some others.
thanks, this really explain a LOT of things.
Do you have an idea how to get access to these APIs? I already tried it with the MS developer support but they say that they don't know
I don't know exactly. But you can't get them through the usual ways. Maybe if you send them a physical letter asking xD?
There are native APIs accessible to regular users. You can read all Calendars since WP7.5 and starting with WP8 you at least can create a new Appointment in a Calendar but only through a Task so the user has the ability to edit it and he must confirm it. Bluetooth-APIs are also open in WP8 although not everything can be done through them.
There might be additional APIs you can gain access too if you work with Microsoft directly. I would suggest you contact one of the Microsoft Dev Champs near you (there is a "Find my Champ" App in the Marketplace) and get into contact with him.
But unless your App gains special permissions through Microsoft even though you might know about those APIs your App would not be able to use them.
And then they cry that Google won't give them the API for a youtube app....the irony
The problem with YouTube is more that there are APIs but that YouTubes Terms of Service prohibit using those APIs for competitors in the search engine space. So Microsoft is specifically prohibited because they own Bing. I hope you can understand the difference but I have a feeling you won't.
Thanks for all your comments. Please don't abuse this thread with company bashing because the situation is often more difficult than it seems. Thanks :good:.
I think wp8.5 may see some more APIs open up. Wp8 is rushed and many existing APIs on win8 simply does not exist on wp8.
Ms is taking a more cautionary approach for APIs as they don't want junior devs mess up the phones user experience like they did with Android.
Sent from my RM-820_nam_canada_246 using Board Express

Implementing Sender application using javascript

Does anybody know if it would be possible to write a Google Cast sender application that runs inside a standard web browser just using javascript? Is there anything in the Sender-Receiver communication that could not be implemented using javascript?
(as long as no there is no javascript Cast Sender API available from Google this would mean writing the thing more or less from scratch)
Arne S said:
Does anybody know if it would be possible to write a Google Cast sender application that runs inside a standard web browser just using javascript? Is there anything in the Sender-Receiver communication that could not be implemented using javascript?
(as long as no there is no javascript Cast Sender API available from Google this would mean writing the thing more or less from scratch)
Click to expand...
Click to collapse
I assume you mean not in chrome. If so then you would need to implement thevram client yourself usung javascript.
I would suggest you look at the fling app. It no longerworks but i beleive it uses a custom client, of course its in java so good luck.
Seems like a lot of effort, what are trying to do?
gottahavit said:
Seems like a lot of effort, what are trying to do?
Click to expand...
Click to collapse
Not for me to implement, but if it is possible I'm sure someone will do it since it will mean that you could Google cast from any webpage regardless of browser and OS and without the user installing any software.

Categories

Resources