Re: [SCION-community] how to send a scmp packet in SCION

93 views
Skip to first unread message

Stephen Shirley

unread,
Oct 17, 2016, 4:43:00 AM10/17/16
to scion-c...@googlegroups.com
Hi,

I recently did some work on getting SCMP ping closer to working as
part of https://github.com/netsec-ethz/scion/pull/904.
`test/integration/scmp_echo_test.py` is now able to send an SCMP ping
packet, and the dispatcher on the remote end is able to send a reply.
The part that's missing is that the local dispatcher doesn't know how
to deliver the SCMP ping response back to the application.
https://github.com/netsec-ethz/scion/blob/master/endhost/dispatcher.c#L880
is the part that still needs to be done. Hope that helps,

Stephen
--
"You are technically correct, the best kind of correct."
- Bureaucrat 1.0, Futurama

luuhoang27968

unread,
Oct 23, 2016, 1:47:50 PM10/23/16
to SCION community
thank you so much

luuhoang27968

unread,
Oct 25, 2016, 11:25:07 PM10/25/16
to SCION community
Hi kormat
How did you run scmp_echo_test.py ? because i created a python project in pycharm and copied scmp_echo_test code into that project. I ran scion system after that i ran scmp_echo_test in pycharm. everything was good but i did not see any packets when i used wireshark to capture the packets
thanks 


On Monday, October 17, 2016 at 3:43:00 PM UTC+7, kormat wrote:

Stephen Shirley

unread,
Oct 27, 2016, 9:23:45 AM10/27/16
to scion-c...@googlegroups.com
Hi,

It can be run as `PYTHONPATH=. ./test/integration/scmp_echo_test.py`
in the main scion directory, with the scion infrastructure running. It
sounds like it's running fine for you in any case.

Regarding wireshark, one thing to be aware of is that SCION is an
overlay protocol, and the current protocol it runs on top of is
UDP/IP. This means that all SCION packets look like UDP/IP packets to
the network, and to tools like wireshark. Tell wireshark to look for
packets to/from UDP port 30041. The dispatcher is what listens on that
port, and forwards packets to the applications. This is what i see in
logs/dispatcher.zlog.DEBUG when i run scmp_echo_test:

2016-10-27 13:20:17.258406+0000 [DEBUG]
(77255:dispatcher:dispatcher.c:1005) 64 byte packet (l4 = 1) sent to
127.0.0.3:22901
2016-10-27 13:20:17.258452+0000 [DEBUG]
(77255:dispatcher:dispatcher.c:897) send echo reply to 127.0.0.1:22901
2016-10-27 13:20:17.258485+0000 [INFO]
(77255:dispatcher:dispatcher.c:912) SCMP payload has no common header
snippet, ignoring

The first line is the SCMP echo request being sent, the second line is
the dispatcher on the remote end replying, and the first dispatcher
being unable to handle the reply.

On 26 October 2016 at 05:25, luuhoang27968 <luuhoa...@gmail.com> wrote:
> How did you run scmp_echo_test.py ? because i created a python project in
> pycharm and copied scmp_echo_test code into that project. I ran scion system
> after that i ran scmp_echo_test in pycharm. everything was good but i did
> not see any packets when i used wireshark to capture the packets

Message has been deleted
Message has been deleted

Stephen Shirley

unread,
Oct 28, 2016, 6:13:17 AM10/28/16
to scion-c...@googlegroups.com
On 27 October 2016 at 18:07, luuhoang27968 <luuhoa...@gmail.com> wrote:
> i ran into a problem when i ran "python3 test/integration/scmp_echo_test.py"
> command in terminal of the ubuntu. it notified that NAME variable in
> test/integration/base_cli_srv.py was not right so it could go through assert
> function because it was empty. is NAME variable important ? what does it do

My best guess is that you're not using a recent commit of the code
base. Try updating your code to the tip of master, and see if that
helps.

luuhoang27968

unread,
Oct 28, 2016, 10:08:13 AM10/28/16
to SCION community
thanks. i fixed that problem.

luuhoang27968

unread,
Oct 29, 2016, 11:04:46 AM10/29/16
to SCION community
Hi kormat
i have a question. I ran scion and scmp_echo_test after that i watched logs/dispatcher.DEBUG file. I saw that scmp packets were only sent to local addresses such as 127.0.0.178, 127.0.0.80 or 127.0.0.81. So if i build and run scion and dispatcher.c on another server which have ip public address, how is dispatcher on remote server able to listen to some scmp packets which were sent from scmp_echo_test.
thank for your help !

Stephen Shirley

unread,
Oct 31, 2016, 11:23:01 AM10/31/16
to scion-c...@googlegroups.com
On 29 October 2016 at 17:04, luuhoang27968 <luuhoa...@gmail.com> wrote:
> i have a question. I ran scion and scmp_echo_test after that i watched
> logs/dispatcher.DEBUG file. I saw that scmp packets were only sent to local
> addresses such as 127.0.0.178, 127.0.0.80 or 127.0.0.81. So if i build and

The default topology generated only uses loopback addresses, which is
why you see this.

> run scion and dispatcher.c on another server which have ip public address,
> how is dispatcher on remote server able to listen to some scmp packets which
> were sent from scmp_echo_test.

Yes, that should be possible, by doing something like this:

./test/integration/scmp_echo_test.py -c x.x.x.x -s y.y.y.y 1-11 1-11

This uses the same ISD-AS for both client and server so that there's
no complication with the router having to be involved.
Reply all
Reply to author
Forward
0 new messages