I have Piwik running on one server, Server A. All my websites run on a different server, Server B. I don't want my users to know Server A's address (including any cookies that would be set), but I want it to do all the statistics. I presume I will have to redirect all the requests to piwik.php from Server B to Server A but I don't know how.
## Piwik Proxy Hide URL
This script allows to track statistics using Piwik, without revealing the
Piwik Server URL. This is useful for users who track multiple websites
on the same Piwik server, but don't want to show the Piwik server URL in
the source code of all tracked websites.
Located in the /path/to/piwik/misc/proxy-hide-piwik-url/ folder.
Should do what your looking for.
Related
Scenario:
My company network has a machines with dedicated IP address. When we enter each IP on our browser within the company network, it takes us to the machine diagnostic page. What i am trying to accomplish is to access these machines remotely from our webserver. I tried adding a link on our website with 10.116.192.5 and it obviously didnt take me to the machine because i was out of that network. Is there anyway i can access these IP on my office network through our website?
I tried using cURL but that does not work with java applet. So i am trying to find an alternate solution to it.
Would using iframe work in this scenario?
Rephrasing the scenario: Trying to redirect our website URL to point to an internal IP address URL. So for instance, if a client types www.scada.example.net/userinfo on browser, this would redirect on the server side internally to x.x.x.x and display on the client side as www.scada.example.net/userinfo.
Suppose server A, via domain A, hosts a website.
Suppose server A, via domain B, also hosts a web service.
The website calls this web service via a PHP/cURL-based API.
Question: even though they live on the same physical server, am I right in thinking the request goes out to the ether and back in, because the domains are different, or does cURL/something have some way of "knowing" it's really the same server, and so there's no reason to go outside?
As far as I know, the request leaves the server no matter what since it's over http - there's no way of it knowing weather the two resources are on the same server or not. You could rip through all the source code but I don't think it would do that - usually if you want to call a resource on the same server you can use absolute file paths as opposed to http requests.
curl source:
curl source
We are running a website behind cloudflare. The website includes community boards (using XenForo engine).
I don't want to reveal real website IP, so I moved mail server to a different server/ip and disabled any functionality that can reveal real server IP address (such as option to upload images to server directly from url).
However, right now we are moving our website to https, and we have to cache all user images and avatars on our server before we show it in html.
So, my question is: Is there any general way to set proxy in php configuration and force php to use this proxy when it's downloading files from url (or making any other connection) using file_get_contents, curl etc?
I know that I can review and rewrite all classes/functions that are using curl and/or file_get_contents, but I am looking for universal solution.
Suppose my website is mywebsite.com and collecting data from remotewebsite.com
I am using loadHtmlFile function to load data from a remote website. The page I am accessing is dynamic and I am calling loadHtmlFile every 3 seconds to get the updated data via ajax call. My concern is, the website owner should not know I am scanning his/her page from my host server ip address.
But the loadHtmlFile script is called from my server only when any visitor visits mywebsite.com.
i) which ip is sent to remotewebsite.com owner? my server ip or the visitors ip who is vising mywebsite.com?
ii) How can I hide myself as I am scanning their site? is there any risk what I am doing?
Yes, your own server IP will most likely appear in the remote site's server logfiles. With Apache it is the access log.
I am not sure about hiding yourself. There's proxy servers for this http://en.wikipedia.org/wiki/Proxy_server.
I am writing a PHP app to fetch all my photos with Instagram using their API. However, what puzzles me is, I run the app on my hosted server it works perfectly fine and the same app running locally does not work.
Here are some points on the app workflow:
The user sees the homepage and he will be prompted with 'sign-in with Instagram'
User signs in with Instagram and authorizes the app.
Instagram redirects the user.
The app then makes a request for access_token and receives it.
Using the access_token, the app will send further requests for user media
The response is parsed and the links to the images are now provided to the user.
All the above mentioned process works fine on my hosted server but fails at 'Step 3.' and redirects user to home page of my app.
The problem is localhost being the redirect_uri. Does anyone have a solution to this problem to use the app locally?
P.S: I have registered two separate clients on Instagram: one for locally hosted development and the other on a web server.
Also, I have tried localtunnel. Did not help either.
I know its a very very very old Question. but for those who get to this page hoping a solution:
instagram currently does not allow to use something like localhost or myvhost.test in redirection url, whats more it requires the url to be certified (https).
so the only working solution I could find is using ngrok. you should download it from the url, open it and type a localhost virtual domain name along with a specific port number like ngrok http myLocalUrl.test/app 80, hit enter and it will gives you two temporary public links.
it will remain valid until you close the ngrok command line. you can direct the link to a specific port number and direct the port number to specific folder path of the application in your localhost.
the tutorials provided by ngrok is simple enough if you did not understand my hints.
I was dealing with this issue trying to develop an Instagram App using NodeJS/Express.
I got around this by using my computer's external local IP rather than localhost, which you can grep for. I assume you're on a *nix machine, so do a very simple (and crude)
$ ifconfig | grep inet
which will return you a few ip and MAC addresses, one of them being your external IP. However this is lousy because it means every time you switch IPs you'll have to update your application's redirect_url with Instagram as well as update any code that relies on it.
Thankfully, there exists services like no-ip that will basically provide free DDNS service to you, so you need simply register a hostname with them and then drop that into your DEV env code as well as your development client's redirect url and you're set to go!