w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
Spoofing & Rotating MAC address using Applescript
airport -z Quit system preferences. Run scselect -n on terminal. -n Delay changing the system's "location" until the next system boot (or the next time that the system configuration preferences are changed). run sudo ifconfig en2 ether 4E:53:50:4F:4F:46

Categories : Osx

How to get host address in jsp?
How about trying with: <a href="<s:url action="~/signup"/>">Sign Up</a> Above seems to work in ASP.NET and i believe it should work in JSP as well!! The simple thing, when you put ../SomeMethod then the server looks up for SomeMethod in same directory where the link was clicked.

Categories : Java

How to get the IP address from a DNS for a host name?
The big difference between these two versions of Delphi is that the modern Delphi natively uses wide UTF-16 encoded strings, and the older version has ANSI encoded strings. Many API functions have both wide and ANSI versions. But the functions you are calling in Winsock are steadfastly 8 bit only. You can make your code work as before by explicitly using 8 bit text encoding. function GetIP(const HostName: string): string; var WSAData: TWSAData; R: PHostEnt; A: TInAddr; begin Result := IPNULL; // '0.0.0.0' WSAStartup($101, WSAData); R := Winsock.GetHostByName(PAnsiChar(AnsiString(HostName))); if Assigned(R) then begin A := PInAddr(r^.h_Addr_List^)^; Result := WinSock.inet_ntoa(A); end; end; Now, observant readers will say: What if the host

Categories : Delphi

How to get the IP address used by a Parallels VM from the host?
if you want to access the machine using SSH there is a built in command that can help with this. prlctl enter <VM_ID|VM_NAME> This will open a prompt as root to the VM if you want the IP for any other reason there is another way to get it prlctl exec <VM_ID|VM_NAME> ifconfig The exec command from prlctl will execute the ifconfig command on the host linux machine (if using windows do ipconfig instead of ifconfig) All the output of the ifconfig will be printed on your terminal and the ip will be clearly visible in the output

Categories : Misc

Node.js - Getting the host IP address while on Amazon EC2
You can use DescribeInstances in the API as per the documentation using the filter ip-address to get the public IP of your instance.

Categories : Javascript

Have the same IP address for android emulator and Host PC
I guess the purpose is that you want to connect to your emulator from out side devices. But this is not called "have the same IP with host PC", you might want to configure the network to bridged mode in your emulator. Thus you can get an IP address which is in the same subnet of your host PC. However, I would like you to try a better way to achieve the same goal, check this: adb forward <local> <remote> - forward socket connections forward specs are one of: tcp:<port> localabstract:<unix domain socket name> localreserved:<unix domain socket name> localfilesystem:<unix domain socket name>

Categories : Android

Apache virtual host for browsing with IP address
I am personally using this one for IP Vhost NameVirtualHost *:80 <VirtualHost *:80> ServerAdmin contact@steelbrain.com.pk DocumentRoot /var/www/ipbased/ ServerName 192.168.1.1 ServerAlias 192.168.1.1 192.168.1.2 </VirtualHost>

Categories : Apache

Unable to resolve host: URL No address associated with hostname
I fixed it by removing these lines HttpParams httpParams = new BasicHttpParams(); HttpConnectionParams.setConnectionTimeout(httpParams, 3000); HttpConnectionParams.setSoTimeout(httpParams, 7000); DefaultHttpClient httpClient = new DefaultHttpClient(httpParams); And replacing it with this code HttpClient httpClient = MainActivity.createHttpClient(); public static HttpClient createHttpClient(){ try { KeyStore trustStore = KeyStore.getInstance(KeyStore.getDefaultType()); trustStore.load(null, null); SSLSocketFactory sf = new MySSLSocketFactory(trustStore); sf.setHostnameVerifier(SSLSocketFactory.ALLOW_ALL_HOSTNAME_VERIFIER); HttpParams params = new BasicHttpParams(); HttpConnectionParams.setConnectionTimeout(params, 15000);

Categories : Android

how to replace IP address on remote host using expect
Quote the “EOF” (here document marker) in the line where you use it, that is, change expect_transfer=`cat << EOF into expect_transfer=`cat << EOF or expect_transfer=`cat << 'EOF' When you do not quote the here document marker, the shell interpolates variable references like $ENV inside the here document. In your case, ENV='$HOME/.kshrc' so that Perl does not see $ENV{OLD} but $HOME/.kshrc{OLD} which is clearly wrong.

Categories : Linux

Warning: Permanently added the RSA host key for IP address
If you are accessing your repositories over the SSH protocol, you will receive a warning message each time your client connects to a new IP address for github.com. As long as the IP address from the warning is in the range of IP addresses , you shouldn't be concerned. Specifically, the new addresses that are being added this time are in the range from 192.30.252.0 to 192.30.255.255. The warning message looks like this: Warning: Permanently added the RSA host key for IP address '$IP' to the list of

Categories : GIT

contact form showing my host address. when i got message
you were in the correct path but have overwritten your headers. here is the fix for it $headers=""; $headers.="Reply-to:$replyto "; $headers .= "From: $email "; $headers .= 'MIME-Version: 1.0'; $headers = "Content-Type: text/html; charset=iso-8859-1 ".$headers;

Categories : PHP

Virtual Host not serving up correct website with same IP address
You can create a virtual network interface and add another IP to the second virtual host / server name: <VirtualHost 123.123.123.123:80> ServerAdmin webmaster@localhost ServerName myNEWsite DocumentRoot "/home/webmaster/development/myNEWsite.co.uk/user/htdocs" ErrorLog "/home/webmaster/development/myNEWsite.co.uk/logfiles/error_log" CustomLog "/home/webmaster/development/myNEWsite.co.uk/logfiles/access_log" common <Directory "/home/webmaster/development/myNEWsite.co.uk/user/htdocs/"> AllowOverride All </Directory> </VirtualHost> and ... <VirtualHost <virtual interface IP>:80> ServerAdmin webmaster@localhost ServerName temp.co.uk DocumentRoot "/home/webmaster/development/temp" ErrorLog "/home

Categories : Ubuntu

setting default host address for mongo client
If you are on a *nix os you can use alias (http://en.wikipedia.org/wiki/Alias_(command)): alias mongo='mongo --host 127.0.0.1' You might want to call you alias something else than mongo though.

Categories : Mongodb

How do you get host's broadcast address of the default network adapter? C#
If you get the local IP and subnet, it should be no problem to calculate. Something like this maybe? using System; using System.Net.NetworkInformation; public class test { public static void Main() { NetworkInterface[] Interfaces = NetworkInterface.GetAllNetworkInterfaces(); foreach(NetworkInterface Interface in Interfaces) { if(Interface.NetworkInterfaceType == NetworkInterfaceType.Loopback) continue; if (Interface.OperationalStatus != OperationalStatus.Up) continue; Console.WriteLine(Interface.Description); UnicastIPAddressInformationCollection UnicastIPInfoCol = Interface.GetIPProperties().UnicastAddresses; foreach(UnicastIPAddressInformation UnicatIPInfo in UnicastIPInfoCol) { Console.WriteLine(" IP Address is {0}", UnicatIPInfo.Address); Console.Wr

Categories : C#

Can WCF endpoint address config use 'localhost' when client is Java on another host?
Check this out: http://msdn.microsoft.com/en-us/library/ee816894.aspx Also what happens if you do not add base address at all? Note that the problem you experience is just in the import process. The runtime will work fine. So you could have the java client do the import from a fixed url (or local wsdl file).

Categories : Wcf

'urllib2.urlopen' adding Host header
You might want to check out the urllib2 missing manual for more information, but basically you create a dictionary of your header labels and values and pass it to the urllib2.Request method. A (slightly) modified version of the code from the linked manual: from urllib import urlencode from urllib2 import Request urlopen # Define values that we'll pass to our urllib and urllib2 methods url = 'http://www.something.com/blah' user_host = 'example.com' values = {'name' : 'Engineero', # dict of keys and values for our POST data 'location' : 'Interwebs', 'language' : 'Python' } headers = { 'Host' : user_host } # dict of keys and values for our header # Set up our request, execute, and read data = urlencode(values) # encode for sending URL request req =

Categories : Python

Accessing WAMP's localhost from another device via host's IP address stopped working
Open your httpd.conf file, find "Controls who can get stuff from this server." it is the section that defines which IP address gets access to your Apache server. By default, it only allows access from localhost or 127.0.0.1, you need to add the line Allow from all at the end of this section. Now save the file, close it, and restart Wamp. Viola! You'd be able to access Apache server installed on your machine via IP address. Please mark it as an answer if it solves your question.

Categories : Iphone

How do manually set the host header when using SimpleBrowser webdriver with Selenium?
In the Selenium way of thinking, this should not be something that you should do anything for. Your test code should mimic user behavior. The Selenium driver should connect you up to the browser and the browser (be it Firefox, Chrome or SimpleBrowser) should automatically add the Host header. Always actually. We should incorporate this in the default headers SimpleBrowser adds. As a workaround, SimpleBrowser has a SetHeader() method that you could use to add any headers you need. You can instantiate the driver passing in a specific version of the Browser as a parameter, so you could call the SetHeader method at the right time. But really, we should fix this in SimpleBrowser itself. https://github.com/axefrog/SimpleBrowser/pull/60 On some further inspection: SimpleBrowser does this just

Categories : Dotnet

java.net.UnknownHostException(Unable to resolve host "play.googleapis.com": No address associated with hostname)
Most common reason for UnknownHostException is missing Internet-Permission. Check your AndroidManifest.xml for <uses-permission android:name="android.permission.INTERNET"></uses-permission> Update: later comment says, internet connectivity is allowed and it works on device. So it's emulator issue. Possible solutions: use IP instead of hostname (for a test) re-create the AVD check min-SDK seetings against AVD sdk version

Categories : Android

How do I block an ip address from seeing a group of webpages?
You only want to block the directory /foo/, so create an .htaccess file in /foo/ (which, intuitively, will only apply to /foo/). Then, use the same syntax to block IP addresses as usual: order allow, deny deny from 127.0.0.1 allow from all I believe this returns a 403 - Forbidden. Not sure how you'd go about returning a 404. (You could just use the same page for 403 errors as you do for 404 errors, and it's unlikely the user will check the response status code) Edit: does user4035's answer work if you begin with RewriteEngine On?

Categories : Htaccess

How to Block an IP address range using the .htaccess file
You could use: Order Allow,Deny Deny from 66.249.74.0/24 Allow from all Or you could use this: RewriteEngine on RewriteCond %{REMOTE_ADDR} ^66.249.74. RewriteRule ^ - [F]

Categories : File

Selenium Webdriver: INFO: I/O exception (java.net.BindException) caught when connecting to the target host: Address already in use: connect
This question solves this problem It's the info-level message. Don't worry about it.

Categories : Java

Is GPS Spoofing possible in iOS sdk?
As far as i know gps gives you lat long and you show it on map. What you can do is add your code in between to spoof obviously iam not talking about the default app. Look at heversine formula it will be helpfull take care of water bodies and buildings you dont want to spoof the position of car in ocean iguess

Categories : Iphone

Bzip2 block header: 1AY&SY
BZIP2 looks at a bit stream. From http://blastedbio.blogspot.com/2011/11/random-access-to-bzip2.html: Anyway, the important bits are that a BZIP2 file contains one or more "streams", which are byte aligned, each containing one (zero?) or more "blocks", which are not byte aligned, followed by an end of stream marker (the six bytes 0x177245385090 which is the square root of pi as a binary coded decimal (BCD), a four byte checksum, and empty bits for byte alignment). The bzip2 wikipedia article also alludes to bit-block alignment (see the File Format section), which seems to be inline from what I remember from school (had to implement the algorithm...).

Categories : Misc

Color a block in header
I combine your html and css, try the following: <html> <header class="nav"> <style> body { background-color: $yellowLighter; font-family: "Helvetica Neue",Helvetica,Arial,sans-serif; font-size: 14px; line-height: 20px; color: #333; margin: auto auto; } header { display:block; } h1 { color: $orangeDarker; } .container { margin-right: auto; margin-left: auto; } .nav { padding: 0 0; border-bottom: 1px solid #eee; box-shadow: 0 0 5px rgba(0,0,0,0.1); background: #fffcf5; position: fixed; width: 100%; height: 50px; top: 0; z-index: 1; margin-left: 0; margin-bottom: 20px; list-style: none; } .n-menu { float: right; list-style: none; font-weight: bold; } .n-menu li {

Categories : HTML

Session spoofing (PHP)
It is not possible for anyone but your code to manipulate values in a session. For someone to bypass that, he'd have to have permission to run code on the server or exploit a security hole in your code or the server (either way a security exploit). If a user is able to do that, he probably doesn't need to bother with fiddling with session values, since he can do virtually anything else on the server directly as well.

Categories : PHP

ios/objective C ip spoofing sample
In order to modify an IP header, you need access to what's known as "raw sockets". Raw sockets aren't allowed on most operating system without elevated privileges. Unfortunately for you, iOS apps don't run with the required privilege for raw sockets. You might be able to do something like this from the simulator running as root, using low level C sockets: int sockfd = socket(AF_INET, SOCK_RAW, 0); But you'll get an error if you try to run this on an iOS device (not jailbroken). Spoofing an IP address has very limited use anyway. When you send data to a server from a spoofed IP address, you never see the response. Using a spoofed IP address, you'll never be able to establish any connection that requires any kind of handshake, including TCP and VPN connections. About the best use of a

Categories : Iphone

Referrer Spoofing in Django
I wrote a redirection script. The steps are: Setup some url handler. Setup a view for this handler. Setup a meta refresh html template. Metarefresh template will blank the referrer before sending the end user to the target url. If you want to get an idea, follow this question and the accepted answer: django get complete url in query string

Categories : Django

Making header act like google chrome mobile app address bar
Prototype Using jQuery - Version 2 I worked on this problem again and made the action a lot smoother. The jQuery code looks like: init = { previousTop: 0, headerHeight: 52 } $(window).scroll(init,function () { var currentTop = $(window).scrollTop(); var scrollMax = $(document).height() - $(window).outerHeight(true); var bodyHeight = $(window).outerHeight(true); var scrollType = ""; if (currentTop < init.previousTop) { $(".offset b").text(currentTop); $(".offset em").text("Up"); scrollUp = true; } else { $(".offset b").text(currentTop); $(".offset em").text("Down"); scrollUp = false; } if (scrollUp == true) { $(".header").css({"color": "blue"}); $(".header").css({"

Categories : Jquery

Mangle http without using a proxy (ARP Spoofing?)
I found a tool that will handle this perfectly including ssl negotiation: http://mitmproxy.org/doc/certinstall/android.html It was android I'm testing but it's a general problem.

Categories : Android

Shopify Rails App - Querystring Spoofing
This question may be too localized, but I'll try to give you a direction. If you are using the query string as the only authentication method, then yes, you will get hacked/spoofed, etc. You need to do some form of authentication. - Shopify provides an API that can probably handle some/most of this for you. https://github.com/shopify/shopify_api

Categories : Ruby On Rails

orde links by their hosts - from a multi link textarea to a table ordred by host (colomn n = host n contains all links of that host)
According to what you've described , you just need a function that will sort the links by the abc. function just_host($link) { return array_shift( explode( '.', str_replace('www.', '', parse_url($link, PHP_URL_HOST)))); } $multi = $_POST['multi_links']; //$_Post is not right , all upper-case! $links = explode(" ", $multi); $links = array_map($links , 'just_host'); //Call the 'just_host' for every link and update the value in the array. sort($links); //Sort the array foreach($links as $link) //Instead of 'for' , use 'foreach' { echo $link . "<br />"; } Should work , please update me if not and I'll edit it.

Categories : PHP

In SAS, how do I connect to a remote Oracle database by specifying the IP address of the Oracle's host?
To use SAS/Access to Oracle on your server "A", that server must have the Oracle networking client software installed and configured. Normally that is managed by an Oracle administrator on that server. It can be as simple as adding an entry into the tnsnames.ora file on your server that "points" to the Oracle instance running on your Windows machine "B". The details of what needs to be added should come from your Oracle DBA. Once you can successfully connect to that Oracle environment from your server "A" (using something like sqlplus or testing with the tnsping command), SAS will use the same connection. The point is that this does not have anything directly to do with SAS; you must set up the environment first. However, note that there are certain posit-installation steps that must

Categories : Oracle

Alternative to an each block to avoid printing header for each instance of a subcategory?
What you have looks perfectly workable, except that your amenity has a singular item. If instead it's a collection of items then your template can be modified slightly to match the original: <% Bus.find(10).amenities.each do | amenity | %> <strong><%= amenity.category %></strong> <ul class="square_list"> <% amenity.items.each do |item| %> <li><%= item %></li> <% end %> </ul> <% end %>

Categories : Ruby

Magento custom module adds HTML block to header
<reference name="header"> <block type="your_module/yourblockclass" name="yourblockname" template="your_module/yourtemplate.phtml"/> </reference> Add the code above to the default-layout-handle in your custom layout.xml file. Fetch the block via $this->getChildHtml('yourblockname') from within the header.phtml file. Good luck!

Categories : PHP

HMAC in client side JavaScript and identity spoofing
JavaScript now has WebRTC where two clients can communicate peer-to-peer, this would be a scenario where clients can generate and use their own "secret". There are some cases where client -> server could be usable as well. If your server was "dynamically" serving the JavaScript then it could insert a "secret" based on the clients current session/login. Assuming you are using HTTPS (if not there could be a man in the middle slurping up the "secret") then it's not unreasonable to assume that communication to the server signed with that specific "secret" (even over unsecured HTTP) belongs to only that client.

Categories : Javascript

Const static variable defined in header file has same address in different translation unit
9.4.2 defines the rules for static data members: 9.4.2/3 defines that a static const literal `can specify a brace-or-equal-initializer.' Meaning, that you can define it similar to X::x below. 9.4.2/4 defines that only one definition can exist (`one definition rule' (odr), see 3.2). And finally, 9.4.2/5 further defines that all static data members of a class in namespace scope will have external linkage. Example: // test.h struct X { static const int x = 10; }; // main.cpp #include <iostream> #include "test.h" void f(); int main(int argc, const char* argv[]) { std::cout << &X::x << std::endl; f(); return 0; } // test.cpp #include <iostream> #include "test.h" void f() { std::cout << &X::x << std::endl; } Output: 001

Categories : C++

How could a local user on a host use a buffer overflow attack to get root access to the host?
Usually, it's about exploiting a vulnerability in a process that runs as root: Either a server that accepts connections (sockets, pipes, etc.) or an executable with the SETUID flag. If by "gain root access" you mean take control of a shell running as root, the buffer overflow payload must start a shell and use dup2 to redirect its input and output to something the attacker controls (such as a socket connection to a "command and control" server running on the attacker's machine).

Categories : C

How to transfer a Wordpress site from Bitnami (local host) to a live host online?
I had a similar problem. To get my particular site working, I added the following code to my configuration file: define('WP_HOME','http://example.com'); define('WP_SITEURL','http://example.com'); After adding the lines, my CSS and uploaded images came back. Don't forget to replace example.com with your site's domain name. I found that code at: http://codex.wordpress.org/Changing_The_Site_URL. Actual user results may vary.

Categories : Wordpress

PHP verify Baidu search engine by host when web host DNS server returns only IP
I was able to use a different DNS server via the host command via shell... $p = trim(trim(explode(' pointer',shell_exec('host -W 2 180.76.5.168 68.238.96.12'))[1]),'.');

Categories : PHP



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.