Will it be possible to create a Chrome extension that uses a PPAPI plugin without a web server? - plugins

In the tutorial Google provided, they mentioned that you had to use a web server. I want my application to run without an Internet connection. Is this possible?

Yes. You have to set up a web server on your machine though. There are free ones on the Internet:
http://www.google.com/search?rlz=1C1CHKZ_enUS437US437&sourceid=chrome&ie=UTF-8&q=free+web+server&qscrl=1
See this SO question:
stumped on jquery call inside chrome extension
...and here is more information from Google:
http://code.google.com/chrome/extensions/experimental.proxy.html
...and some problems you might run into:
http://osdir.com/ml/chromium-extensions/2011-05/msg00261.html

Related

Mobile DApp connecting to Wallet

I've been trying to create simple mobile app prototype (in Flutter) which would allow you to connect to a Wallet and obtains your address(es). I cannot get the connection working, all the clients I could find are written in JS so my initial approach was to get it working using webview. However none of the libraries worked for me:
WalletConnect - the generated wc: link is not recognized (universal links don't seem to work)
Metamask - doesn't inject the provider into the webview browser (I'm serving the scripts locally)
Web3Modal - requires secure server to run
I'm about to try to get local HTTPS server working in the app just to try the Web3Modal but I kind of have a feeling that I'm approaching this wrong.
Any suggestions appreciated.
There is now walletconnect_dart package which supports WC protocol for Flutter. I have created walletconnect_qrcode_modal_dart package which uses walletconnect_dart to emulate functionality of #walletconnect/qrcode-modal npm package.

Deploying Flutter Web App To Hostgator/normal FTP means?

I have been really interested in Flutter for the last few months and have been following the beta Flutter for web information. I was wondering, other than the ones mentioned in the documentation (Firebase, Github, Google Cloud), is there a way to currently test my app via using my Hostgator hosting and use something like Filezilla to publish the application/site?
I understand this is in a beta state. I only ask because the documentation states that there is a way to publish via those services but doesn't mention the way I am asking. I also understand that this is not production-ready.
Thank you all for any help
You can just run:
flutter build web
And then copy the contents of build/web to your web host's document root via a panel or FTP or something else.

Controlling Google Chrome via Perl script

I was looking for a way to check for changes in a specific URL provided by the user. I wrote a script that I ran at home that can do that successfully using WWW::Mechanize. The thing is, I need to run it in another computer network that has a group policy that blocks all $mech->get($url) requests (it's not firewall problems, I let Perl through), so I thought I'll try and work around this problem by letting Perl control the web browser.
The computers in the network run Google Chrome and IE8 only and I can't install Firefox due to another policy (thought of using WWW::Mechanize::Firefox). I don't want to invoke IE8 in the script because most of the URLs that will be provided will be of websites that don't work well with it, so that leaves me with Chrome only.
Searching for a module that can do that, I only found AnyEvent::Chromi:
which exposes all of the Chrome Extensions API via a websocket connection.
This doesn't work (the policy probably blocks that websocket as well).
Is there another way to work around this problem/control Chrome from within a Perl script?
Is there another way to work around this problem/control Chrome from
within a Perl script?
WWW::Mechanize::Chrome
Like WWW::Mechanize, this module automates web browsing with a Perl object. Fetching and rendering of web pages is delegated to the Chrome (or Chromium) browser by starting an instance of the browser and controlling it with Chrome DevTools.
You can also do this from scratch without using any CPAN modules.
I tested this on Linux (Ubuntu 16.04, Google Chrome version 53) using Unix Domain (UD)
sockets. Unfortunately, it seems Windows does not have UD sockets, but
it should be possible to do same from Windows using named pipes.
First, make sure google-chrome is running in the background. We will
need to create a Chrome App
that will communicate
with a native host through the native messaging
API. The
native host can be any script that reads messages from its STDIN and
returns replies through its STDOUT. I tested both a Python
script and a Perl script.
Now, in order for a standalone Perl script to communicate with the
Chrome browser, it will send request through a UD socket (created by
the native host) to the native host; the native host will then
forward the request to google-chrome through its standard output
pipe. Then the Chrome App (written in JavaScript)
will receive the request. The Chrome App will use the Chrome
JavaScript APIs to get the requested data and return it to the native
host. Finally, the native host forwards the result through the socket to
the Perl script.
As you can see, there are some details required for setting this up, but I can
confirm that it works on my Linux platform. Please let me know if you need more
details.
Since you mentioned IE8, I'm assuming that you're dealing with a Windows system. And since you mentioned that you had considered WWW:Mechanix::Firefox, it sounds like you are not being restricted to just core modules.
Based on that, the only way that I can think of to automate the Chrome broswer would be to use Win32::GuiTest to control the Chrome browser. If you can figure out how to manually drive your testing using only keyboard input (i.e. no mouse), that would make things easier than trying to figure out the mouse emulation to get the cursor to the correct position for various tasks.
I'm not sure if that's necessarily a route that you will like to use or not. It's just the only way that I can think of to accomplish what you want to do with the restrictions that you have to deal with.

How OrientDB Studio Code Works?

I have a question regarding the way the OrientDB studio works.
When I build my own web application to access the OrientDB database, I need to enable CORS and then it works, but how comes that the OrientDB studio app works without having to enable CORS?
That's really puzzling me because I'd like to reuse the code logic of the OrientDB Studio app in my own application and it does not work like the OrientDB Studio app.
Also, it seems that the OrientDB Studio app is using the REST API of OrientDB, not the JavaScript API (orientdb-api.js). Am I right?
Is there any documentation I could read to get a full understanding of how the Studio works?
Regards,
Jeremie
You need to enable CORS because your app it is outside the domain of ODB. if you are running it in localhost is http://localhost:2480.
So if you make a request from a different domain the browser stops you if the server has CORS disabled.
Studio starts as a plugin inside ODB http (http://localhost:2480/studio/index.html) so is allowed to do request without enabling CORS.
If you do not want to enable CORS you can put your html and js under the www directory in
the $ORIENTDB_HOME distribution.
There is no documentation about Studio Code. You can browse it here https://github.com/orientechnologies/orientdb-studio if you need some further information you can ask me as i'm the main maintainer of Studio :D
I can tell you that it does not use the orientdb-api.js as it uses angular.js.
I advice you to not use orientdb-api.js but uses directly the REST api
with JQuery/Angular.

Deliver application's GUI via browser

I need to show to a user an interface of some application running on a server using a browser. It should be like RDP-client for a single application on a server.
Are there any solutions or services that can implement following functionality? Maybe Citrix?
Thanks in advance!
This looks like what you're looking for:
http://freerdp.net/
About FreeRDP-WebConnect
FreeRDP-WebConnect is an open source gateway for accessing RDP
sessions using any HTML5 compliant browser. In particular it relies on
the Canvas and the WebSockets feature. FreeRDP-WebConnect is a
subproject of the FreeRDP project.
On the server side, a standalone daemon - written in C++ - provides a
Web page via HTTPS (or HTTP, if configured) and uses FreeRDP libs to
connect as a client to any RDP session. The server side WebSockets
implementation handles current RFC6455 only, so browsers that
implement the older drafts do not work. With RFC6455 being raised to
the "Proposed Standard" level, this should change now really soon.
I would create an account on the server for the user, and only give it access to the one application it needs access to.
You can use Cameyo. To start, create yourself a free account, and click on "Add App". If your installer supports unattended installation, you simply need to submit it. Otherwise, you can build a Cameyo package locally and send it in. It will then be playable as HTML5.
You don't indicate what server you are running on.
As an alternative to FreeRDP-Webconnect cited above, also open source and also using FreeRDP as rdp client through an HTTP gateway, there is Myrtille.
FreeRDP-WebConnect embeds a standalone daemon written in C++ to provide a web page via HTTP(S), and so will also work on Linux servers, while Myrtille have a IIS/.NET (C#) implementation and an MSI installer, thus is more intended for Windows Servers.