skip to main content
10.1145/3341216.3342206acmconferencesArticle/Chapter ViewAbstractPublication PagescommConference Proceedingsconference-collections
research-article

Runtime Verification of P4 Switches with Reinforcement Learning

Published: 14 August 2019 Publication History

Abstract

We present the design and early implementation of p4rl, a system that uses reinforcement learning-guided fuzz testing to execute the verification of P4 switches automatically at runtime. p4rl system uses our novel user-friendly query language, p4q to conveniently specify the intended properties in simple conditional statements (if-else) and check the actual runtime behavior of the P4 switch against such properties. In p4rl, user-specified p4q queries with the control plane configuration, Agent, and the Reward System guide the fuzzing process to trigger runtime bugs automatically during Agent training. To illustrate the strength of p4rl, we developed and evaluated an early prototype of p4rl system that executes runtime verification of a P4 network device, e.g., L3 (Layer-3) switch. Our initial results are promising and show that p4rl automatically detects diverse bugs while outperforming the baseline approach.

Supplementary Material

MP4 File (p1-shukla.mp4)

References

[1]
P4 Language Consortium. https://p4.org/specs/.
[2]
R. Stoenescu, D. Dumitrescu, M. Popovici, L. Negreanu, and C. Raiciu. Debugging P4 programs with Vera. In ACM SIGCOMM, 2018.
[3]
J. Liu, W. Hallahan, C. Schlesinger, M. Sharif, J. Lee, R. Soulé, H. Wang, C. Caşcaval, N. McKeown, and N. Foster. P4v: Practical verification for programmable data planes. In ACM SIGCOMM, 2018.
[4]
M. Neves, L. Freire, A. Schaeffer-Filho, and M. Barcellos. Verification of P4 Programs in Feasible Time Using Assertions. In ACM CoNEXT, 2018.
[5]
L. Freire, M. Neves, L. Leal, K. Levchenko, A. Schaeffer-Filho, and M. Barcellos. Uncovering Bugs in P4 Programs with Assertion-based Verification. In ACM SOSR, 2018.
[6]
Michal Zalewski. American fuzzy lop: a security-oriented fuzzer. URl: http://lcamtuf.coredump.cx/afl/ (visited on 06/21/2017), 2010.
[7]
P. Godefroid, M. Y. Levin, and D. Molnar. SAGE: whitebox fuzzing for security testing. Comm. of the ACM, 55(3), 2012.
[8]
A. Sapio, I. Abdelaziz, A. Aldilaijan, M. Canini, and P. Kalnis. In-network Computation is a Dumb Idea Whose Time Has Come. In ACM HotNets, 2017.
[9]
S. Salman, C. Streiffer, H. Chen, T. Benson, and A. Kadav. DeepConf: Automating Data Center Network Topologies Management with Machine Learning. In ACM NetAI, 2018.
[10]
S. Russell and P. Norvig. Artificial Intelligence: A Modern Approach. Prentice Hall Press, 3rd edition, 2009.
[11]
Hado Van Hasselt, Arthur Guez, and David Silver. Deep reinforcement learning with double q-learning. In Thirtieth AAAI Conference on Artificial Intelligence, 2016.
[12]
T. Schaul, J. Quan, I. Antonoglou, and D. Silver. Prioritized experience replay. arXiv preprint arXiv:1511.05952, 2015.
[13]
P4 Tutorial. https://github.com/p4lang/tutorials.
[14]
Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Alex Graves, Ioannis Antonoglou, Daan Wierstra, and Martin Riedmiller. Playing atari with deep reinforcement learning. arXiv preprint arXiv:1312.5602, 2013.
[15]
Long-Ji Lin. Reinforcement learning for robots using neural networks. Technical report, CMU PA School of Computer Science, 1993.
[16]
Keras: The Python Deep Learning library. https://keras.io/.
[17]
Scapy. https://scapy.net/.
[18]
P4 Behavioural model. https://github.com/p4lang/behavioral-model.
[19]
P4Runtime. https://p4.org/p4-runtime/.
[20]
VirtualBox. https://www.virtualbox.org/.
[21]
Mininet. http://mininet.org/.
[22]
P4 Language Consortium. P416 language specs, version 1.1.0, 2018.
[23]
Changhoon Kim et al. Inband Network Telemetry (INT). Technical specification, Barefoot Networks, Jun 2016.
[24]
Leonid Ryzhyk, Nikolaj Bjørner, Marco Canini, Jean-Baptiste Jeannin, Cole Schlesinger, Douglas B Terry, and George Varghese. Correct by construction networks using stepwise refinement. In 14th {USENIX} Symposium on Networked Systems Design and Implementation ({NSDI} 17), pages 683--698, 2017.
[25]
Peyman Kazemian, George Varghese, and Nick McKeown. Header Space Analysis: Static Checking for Networks. In Proc. USENIX NSDI, 2012.
[26]
Peyman Kazemian, Michael Chang, Hongyi Zeng, George Varghese, Nick Mckeown, and Scott Whyte. Real Time Network Policy Checking Using Header Space Analysis. In Proc. USENIX NSDI, 2013.
[27]
Ahmed Khurshid, Xuan Zou, Wenxuan Zhou, Matthew Caesar, and P. Brighten Godfrey. VeriFlow: Verifying Network-Wide Invariants in Real Time. In NSDI, 2013.
[28]
Hongyi Zeng, Peyman Kazemian, George Varghese, and Nick McKeown. Automatic test packet generation. In Proceedings of the 8th international conference on Emerging networking experiments and technologies, pages 241--252. ACM, 2012.
[29]
Mohit Rajpal, William Blum, and Rishabh Singh. Not all bytes are equal: Neural byte sieve for fuzzing. arXiv preprint arXiv:1711.04596, 2017.
[30]
Patrice Godefroid, Hila Peleg, and Rishabh Singh. Learn&fuzz: Machine learning for input fuzzing. In Proceedings of the 32nd IEEE/ACM International Conference on Automated Software Engineering, pages 50--59. IEEE Press, 2017.
[31]
Chris Cummins, Pavlos Petoumenos, Alastair Murray, and Hugh Leather. Compiler fuzzing through deep learning. In Proceedings of the 27th ACM SIGSOFT International Symposium on Software Testing and Analysis, pages 95--105. ACM, 2018.

Cited By

View all
  • (2023)P4Testgen: An Extensible Test Oracle For P4-16Proceedings of the ACM SIGCOMM 2023 Conference10.1145/3603269.3604834(136-151)Online publication date: 10-Sep-2023
  • (2023)Advancing SDN from OpenFlow to P4: A SurveyACM Computing Surveys10.1145/355697355:9(1-37)Online publication date: 16-Jan-2023
  • (2023)P4Chain: A Multichain Approach for Real-Time Anomaly Traffic Detection in P4 Network2023 IEEE 14th Annual Ubiquitous Computing, Electronics & Mobile Communication Conference (UEMCON)10.1109/UEMCON59035.2023.10316086(0163-0170)Online publication date: 12-Oct-2023
  • Show More Cited By

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM Conferences
NetAI'19: Proceedings of the 2019 Workshop on Network Meets AI & ML
August 2019
96 pages
ISBN:9781450368728
DOI:10.1145/3341216
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than the author(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected].

Sponsors

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 14 August 2019

Permissions

Request permissions for this article.

Check for updates

Author Tags

  1. Fuzzing
  2. Machine Learning
  3. Network Verification
  4. P4

Qualifiers

  • Research-article
  • Research
  • Refereed limited

Funding Sources

Conference

SIGCOMM '19
Sponsor:
SIGCOMM '19: ACM SIGCOMM 2019 Conference
August 23, 2019
Beijing, China

Acceptance Rates

NetAI'19 Paper Acceptance Rate 13 of 38 submissions, 34%;
Overall Acceptance Rate 13 of 38 submissions, 34%

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)61
  • Downloads (Last 6 weeks)12
Reflects downloads up to 01 Mar 2025

Other Metrics

Citations

Cited By

View all
  • (2023)P4Testgen: An Extensible Test Oracle For P4-16Proceedings of the ACM SIGCOMM 2023 Conference10.1145/3603269.3604834(136-151)Online publication date: 10-Sep-2023
  • (2023)Advancing SDN from OpenFlow to P4: A SurveyACM Computing Surveys10.1145/355697355:9(1-37)Online publication date: 16-Jan-2023
  • (2023)P4Chain: A Multichain Approach for Real-Time Anomaly Traffic Detection in P4 Network2023 IEEE 14th Annual Ubiquitous Computing, Electronics & Mobile Communication Conference (UEMCON)10.1109/UEMCON59035.2023.10316086(0163-0170)Online publication date: 12-Oct-2023
  • (2023)Runtime Verification for Programmable SwitchesIEEE/ACM Transactions on Networking10.1109/TNET.2023.323493131:4(1822-1837)Online publication date: Aug-2023
  • (2023)AI-Driven Packet Forwarding With Programmable Data Plane: A SurveyIEEE Communications Surveys & Tutorials10.1109/COMST.2022.321761325:1(762-790)Online publication date: Sep-2024
  • (2023)Packet processing and data plane program verification: A survey with tools, techniques, and challengesInternational Journal of Communication Systems10.1002/dac.555436:14Online publication date: 14-Jun-2023
  • (2022)A Deep Learning Model for Detecting Cage-Free Hens on the Litter FloorAnimals10.3390/ani1215198312:15(1983)Online publication date: 5-Aug-2022
  • (2022)A survey on security applications of P4 programmable switches and a STRIDE-based vulnerability assessmentComputer Networks: The International Journal of Computer and Telecommunications Networking10.1016/j.comnet.2022.108800207:COnline publication date: 16-May-2022
  • (2022)Reinforcement Learning Based Routing in Software Defined NetworkAdvances in Distributed Computing and Machine Learning10.1007/978-981-19-1018-0_16(179-191)Online publication date: 28-Jul-2022
  • (2021)Component-based Error Detection of P4 programsActa Cybernetica10.14232/actacyb.289731Online publication date: 4-Aug-2021
  • Show More Cited By

View Options

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Figures

Tables

Media

Share

Share

Share this Publication link

Share on social media