[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ns] calling deque() for a very special queueing strategy



You can schedule events according to the Time-to-send, and the handler
could call deque(). But here you have to be careful not to queue packets
in your queueing class, since the scheduler is not holding them.

Regards,
Sudhin.

On Fri, 20 Apr 2001, Stefan Penz wrote:

> Hello all,
>
> I'm trying to install a concept called "SG-Mix" into ns2.
>
> SG-Mixes are used to provide some kind of anonymity in a network.
> The basic idea is to collect some encrypted packets from some senders,
> decrypting them and sending them in a different order.
> So an attacker is not able to match the sender and the receiver of a packet.
>
> An SG-Mix provides this by holding a received packet for a time that is
> randomly
> chosen from an exponential distribution.
>
> I've implemented this concept by defining a new type of queue (class
> Queue/SGMix).
> enque() choses the waiting time for every incoming packet and stores the
> pair (Packet,Time-to-send)
> into a (time-ordered) data strucure.
> deque() gets the current time and compares it with the minimal Time-to-send
> in the structure.
> If the Time-to-send has passed, it returns the associated packet, else it
> returns NULL.
>
> My implementation runs quite fine, but one there's one problem left:
> deque() is not called often enough !
> When deque() is called, the Time-to-send may be past for a while.
>
> The first packet, for example, remains in the first SG-Mix-Queue
> until the next packet arrives, because deque() is not called
> since the arrival of the first packet.
> (deque() is called directly after the first packet is enqueued,
> but then the Packet's Time-to-send is certainly not reached.)
>
> So I need a solution to get deque() called more often, at best exactly
> at the next Time-to-send, or at least periodicaly every x milliseconds.
>
> Any suggestions how to solve this problem ?
>
> Thanks,
> Stefan
>
> --
> | Stefan Penz
> | Wildbachstr. 4
> | 52074 Aachen
> | Germany
>
>

****************** Sudhindra Suresh Bengeri ********************
Graduate Research Assistant   | Home:                          |
to Dr. George N. Rouskas      | 2110, Gorman St.,              |
EGRC 454H, Computer Sci. dept.| Raleigh, NC - 27606            |
NCSU, Raleigh, NC 27695       | Ph. (919) 852-1961             |
(919)515-3655(P) / 515-7925(F)
My web projection: http://www4.ncsu.edu/~ssbenger

* Always glad to share my ignorance - I've got plenty. *