I am trying to write a GreaseMonkey script in which I want to find all of the links that are relative links. It seemed to me that the way to do that would be to match the contents of href against /^https?:///.
But I find that when I access the anchor's href attribute, it's always normalized or cooked into a form that contains "http". ...
Hi all,
I am trying to create a raw socket which send and receive message with ip/tcp header under linux.
I can successfully binds to a port and receive tcp message(ie:syn)
However, the message seems to be handled by the os, but not mine. I am just a reader of it(like wireshark).
My raw socket binds to port 8888, and then i try to telne...
Hello, I want to read the RGB values for each pixel from a raw image. Can someone tell me how to achieve this? Thanks for help!
the format of my raw image is .CR2 which is taken from camera.
...
I am trying to put some logging to capture the raw http request coming to my application. My Java code is inside a SpringMVC controller. I have access to the "HttpServletRequest" object. But I could not find a way to get the raw http request stream out of it. There is a reader but only reads the post content. What I want is the whole she...
I'm trying to send a raw ethernet frame with the length of my data written in the type field. This should be a valid ethernet frame. My code for this looks like this:
ethData = "foobar"
proto =len(ethData)
if proto < 46:
proto = 46
soc = socket.socket(socket.AF_PACKET, socket.SOCK_RAW, proto)
soc.bind((iface, proto))
For some rea...
Hi all,
I want to master certain raw protocols to learn about TCP Stream resuming.
I am versed in .Net sockets, and would like to initiate a TCP stream so:
Socket socket = new Socket(Tcp)
socket.connect(IPAddress);
socket.send(new byte[]{155});
socket.close();
Then be able to read the raw IO network card data sent/recieved and save ...
I'm pretty sure I'm overlooking something totally obvious, but I want to view the raw contents of a point in memory under MSVC9, but I can't find a location in the UI where I can punch in a memory address. How can this be done?
...
I want to have some static numeric and text values as an application resource. For example my data is like this:
Levels 5 First_Level 500 60 1 Second_Level 500 80 1 Third_Level 200 60 1 Fourth_Level 130 30 2 Final_Level 100 30 3
... and another 300 lines...
The format and order of the data is predefined and guaranteed to be valid.
I ...
Sorry I'm a newbie, I think that there's something wrong in this code, or something that can be improved.
This code was designed to upload files from a flash javascript uploader plugin.
It doesn't give me an error but sometimes it does not insert the mysql query.
P.s: every posted variable is cleaned up via javascript (just alphanumeric ...
I'm trying to use the following code to access one byte with offset of 50 bytes in a raw disk.
randomAccessFile = new RandomAccessFile("C:", "r");
randomAccessFile.seek(50);
byte[] buffer = new byte[1];
randomAccessFile.read(buffer);
But all what I get is the following error:
java.io.FileNotFoundException: C: (Acceso denegado)
at jav...
Hi guys,
I have already asked a similar question here:
http://stackoverflow.com/questions/956720/python-open-raw-audio-data-file
Now I want to open, and play, raw audio files with QtPhonon.
The main goal is to open the file and play a certain location in the file, for example from the 10th second to the 20th second. Is it possible usin...
How can I create raw ISO Image ?
I mean I am programming simple system in assembler and I want to create an ISO which could put binary file (whole system is in one file) in BootSector.
Could you help ?
...
I have a generic tree, the generic parameter is the data type stored by the nodes:
class TreeNode<D>{
public D data;
.....
}
Then a visitor interface to use along with a tree transversal:
interface Visitor<D> {
void visit(TreeNode<D> node);
}
Some visitors can take advantage of generics:
class DataListCreator<D>...
Hello, this is my first question here. I have the following jquery code:
$(document).ready(function(){
$("a").click(function(){
$(this).parent("li").css({textDecoration: "line-through"});
return false;
});
});
that works just fine. It strikes through the parent li of any clicked anchor (there are many anchor...
Hi,
I want to implement a simple firewall using raw sockets. I found some sniffer samples but I want to know if it is possible to drop unwanted packets using raw sockets. It is very important for me. Please let me know how can I do that?
...
Hi,
I having been googling for a way to do raw (sometimes called direct) i/o under mac os. Raw i/o turns of the operating system page cache to give the application more direct access to the disk. This is useful because some of the filestructure I am using are not efficient using LRU page replacement. It is fairly straight forward to imp...
I'll start by saying I am a Java (/programming) newbie and this is my first question on the website.
Just learnt how to make an ordered list in Java using recursive nodes.
Everything was easy until I ran into this exercise asking me to write a method that would double whatever value is contained in each node.
Here is the code I tried to...
I have the following code
int ParseData(unsigned char *packet, int len)
{
struct ethhdr *ethernet_header;
struct iphdr *ip_header;
struct tcphdr *tcp_header;
unsigned char *data;
int data_len;
/* Check if any data is there */
if(len > (sizeof(struct ethhdr) + sizeof(struct iphdr) + sizeo...
Hi all. Basically, i have two files.
The first file is an image:
http://www.mediafire.com/file/yzvngmuixum/panzerghost.jpg
![Image][1]
If you download the full sized image, you can see it clearer.
The second file is a .bin of raw data
http://www.mediafire.com/file/dfnumz2dwuf/panzerghost.bin
Now the image is of a Motorstorm level. It...
Hello everyone.
I create a module in kernel space that send a UPD segment using socket RAW, but my problem is read the UDP segment from kernel space.
I can read the UDP segment from user space, but when I prove to use "sock_recvmsg" from kernel space, I obtain as result -512
Please, help me!
...