Skip to main content

The Program Counter Security Model: Automatic Detection and Removal of Control-Flow Side Channel Attacks

  • Conference paper
Information Security and Cryptology - ICISC 2005 (ICISC 2005)

Part of the book series: Lecture Notes in Computer Science ((LNCS,volume 3935))

Included in the following conference series:

Abstract

We introduce new methods for detecting control-flow side channel attacks, transforming C source code to eliminate such attacks, and checking that the transformed code is free of control-flow side channels. We model control-flow side channels with a program counter transcript, in which the value of the program counter at each step is leaked to an adversary. The program counter transcript model captures a class of side channel attacks that includes timing attacks and error disclosure attacks.

Further, we propose a generic source-to-source transformation that produces programs provably secure against control-flow side channel attacks. We implemented this transform for C together with a static checker that conservatively checks x86 assembly for violations of program counter security; our checker allows us to compile with optimizations while retaining assurance the resulting code is secure. We then measured our technique’s effect on the performance of binary modular exponentiation and real-world implementations in C of RC5 and IDEA: we found it has a performance overhead of at most 5× and a stack space overhead of at most 2×. Our approach to side channel security is practical, generally applicable, and provably secure against an interesting class of side channel attacks.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. Agat, J.: Transforming Out Timing Leaks. In: Proceedings on the 27th ACM Symposium on the Principles of Programming Languages (2000)

    Google Scholar 

  2. Agat, J.: Type Based Techniques for Covert Channel Elimination and Register Allocation. PhD thesis, Chalmers University of Technology (2001)

    Google Scholar 

  3. Benini, L., Macii, A., Macii, E., Omerbegovic, E., Poncino, M., Pro, F.: A Novel Architecture for Power Maskable Arithmetic Units. In: Proceedings of the 13th ACM Great Lakes symposium on VLSI (2003)

    Google Scholar 

  4. Benini, L., Macii, A., Macii, E., Omerbegovic, E., Poncino, M., Pro, F.: Energy-aware Design Techniques for Differential Power Analysis Protection. In: Proceedings of the 40th conference on Design automation (2003)

    Google Scholar 

  5. Bernstein, D.J.: Cache-timing attacks on AES (2005), http://cr.yp.to/papers.html#cachetiming

  6. Black, J., Urtubia, H.: Side-Channel Attacks on Symmetric Encryption Schemes: The Case for Authenticated Encryption. In: Proceedings of the 11th USENIX Security Symposium (2002)

    Google Scholar 

  7. Bleichenbacher, D.: Chosen ciphertext attacks against protocols based on RSA encryption standard PKCS #1. In: Krawczyk, H. (ed.) CRYPTO 1998. LNCS, vol. 1462, p. 1. Springer, Heidelberg (1998)

    Chapter  Google Scholar 

  8. Blömer, J., Merchan, J.G., Krummel, V.: Provably secure masking of AES. In: Handschuh, H., Hasan, M.A. (eds.) SAC 2004. LNCS, vol. 3357, pp. 69–83. Springer, Heidelberg (2004)

    Chapter  Google Scholar 

  9. Boneh, D., Brumley, D.: Remote Timing Attacks Are Practical. In: Proceedings of the 12th USENIX Security Symposium (2003)

    Google Scholar 

  10. Chari, S., Jutla, C., Rao, J.R., Rohatgi, P.: A Cautionary Note Regarding Evaluation of AES Candidates on Smart-Cards. In: Proceedings of the Second AES Candidate Conference (1999)

    Google Scholar 

  11. Coron, J.-S., Goubin, L.: On Boolean and Arithmetic Masking Against Differential Power Analysis. In: Paar, C., Koç, Ç.K. (eds.) CHES 2000. LNCS, vol. 1965, p. 231. Springer, Heidelberg (2000)

    Chapter  Google Scholar 

  12. Handschuh, H., Heys, H.: A timing attack on RC5. In: Tavares, S., Meijer, H. (eds.) SAC 1998. LNCS, vol. 1556, pp. 306–318. Springer, Heidelberg (1999)

    Chapter  Google Scholar 

  13. Hennessy, M.: The Semantics of Programming Languages: an Elementary Introduction using Structural Operational Semantics. John Wiley and Sons, New York (1990)

    MATH  Google Scholar 

  14. Kelsey, J., Schneier, B., Wagner, D., Hall, C.: Side Channel Cryptanalysis of Product Ciphers. Journal of Computer Security 8, 141–158 (2000)

    Article  Google Scholar 

  15. Klima, V., Pokorny, O., Rosa, T.: Attacking RSA-based sessions in SSL/TLS. In: Walter, C.D., Koç, Ç.K., Paar, C. (eds.) CHES 2003. LNCS, vol. 2779, pp. 426–440. Springer, Heidelberg (2003)

    Chapter  Google Scholar 

  16. Klima, V., Rosa, T.: Side channel attacks on CBC encrypted messages in the PKCS #7 format. Cryptology ePrint Archive, Report 2003/098 (2003), http://eprint.iacr.org/

  17. Kocher, P.: Timing Attacks on Implementations of Diffie-Hellman, RSA, DSS, and Other Systems. In: Koblitz, N. (ed.) CRYPTO 1996. LNCS, vol. 1109, pp. 104–113. Springer, Heidelberg (1996)

    Google Scholar 

  18. Kocher, P., Jaffe, J., Jun, B.: Differential Power Analysis. In: Wiener, M. (ed.) CRYPTO 1999. LNCS, vol. 1666, p. 388. Springer, Heidelberg (1999)

    Chapter  Google Scholar 

  19. Lampson, B.W.: A Note on the Confinement Problem. Communications of the ACM 16(10), 613–615 (1973)

    Article  Google Scholar 

  20. Manger, J.: A chosen ciphertext attack on RSA optimal asymmetric encryption padding (OAEP) as standardized in PKCS #1 v2.0. In: Kilian, J. (ed.) CRYPTO 2001. LNCS, vol. 2139, p. 230. Springer, Heidelberg (2001)

    Chapter  Google Scholar 

  21. Messerges, T.S.: Securing the AES Finalists Against Power Analysis Attacks. In: Schneier, B. (ed.) FSE 2000. LNCS, vol. 1978, p. 150. Springer, Heidelberg (2001)

    Chapter  Google Scholar 

  22. Messerges, T.S., Dabbish, E.A., Sloan, R.H.: Investigations of Power Analysis Attacks on Smartcards. In: Proceedings of the USENIX Workshop on Smartcard Technology (1999)

    Google Scholar 

  23. Messerges, T.S., Dabbish, E.A., Sloan, R.H.: Power Analysis Attacks of Modular Exponentiation in Smartcards. In: Koç, Ç.K., Paar, C. (eds.) CHES 1999. LNCS, vol. 1717, p. 144. Springer, Heidelberg (1999)

    Chapter  Google Scholar 

  24. Micali, S., Reyzin, L.: Physically observable cryptography. In: Naor, M. (ed.) TCC 2004. LNCS, vol. 2951, pp. 278–296. Springer, Heidelberg (2004)

    Chapter  Google Scholar 

  25. Möller, B.: Security of CBC ciphersuites in SSL/TLS: Problems and countermeasures (May 2004), http://www.openssl.org/~bodo/tls-cbc.txt

  26. Molnar, D., Piotrowski, M., Schultz, D., Wagner, D.: The program counter security model: Automatic detection and removal of control-flow side channel attacks (full version) (2005); IACR eprint archive report 2005/368

    Google Scholar 

  27. Necula, G., McPeak, S., Rahul, S.P., Weimer, W.: CIL: Intermediate Language and Tools for Analysis and Transformation of C Programs. In: Proceedings of the Conference on Compilier Construction (2002)

    Google Scholar 

  28. Rakers, P., Connell, L., Collins, T., Russell, D.: Secure Contactless Smartcard ASIC with DPA Protection. In: Proceedings of the Custom Integrated Circuits Conference (2000)

    Google Scholar 

  29. Sabelfeld, A., Myers, A.C.: Language-Based Information-Flow Security. IEEE Journal on Selected Areas in Communications 21(1), 5–19 (2003)

    Article  Google Scholar 

  30. Shamir, A.: Protecting Smart Cards from Passive Power Analysis with Detached Power Supplies. In: Paar, C., Koç, Ç.K. (eds.) CHES 2000. LNCS, vol. 1965, p. 71. Springer, Heidelberg (2000)

    Chapter  Google Scholar 

  31. Simonet, V.: Flowcaml (2005), http://cristal.inria.fr/~simonet/soft/flowcaml/

  32. Vaudenay, S.: Security flaws induced by CBC padding - applications to SSL, IPSEC, WTLS... In: Knudsen, L.R. (ed.) EUROCRYPT 2002. LNCS, vol. 2332, p. 534. Springer, Heidelberg (2002)

    Chapter  Google Scholar 

  33. Zheng, L., Myers, A.: End-to-end availability policies and noninterference. In: Computer Security Foundations Workshop (2005)

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2006 Springer-Verlag Berlin Heidelberg

About this paper

Cite this paper

Molnar, D., Piotrowski, M., Schultz, D., Wagner, D. (2006). The Program Counter Security Model: Automatic Detection and Removal of Control-Flow Side Channel Attacks. In: Won, D.H., Kim, S. (eds) Information Security and Cryptology - ICISC 2005. ICISC 2005. Lecture Notes in Computer Science, vol 3935. Springer, Berlin, Heidelberg. https://doi.org/10.1007/11734727_14

Download citation

  • DOI: https://doi.org/10.1007/11734727_14

  • Publisher Name: Springer, Berlin, Heidelberg

  • Print ISBN: 978-3-540-33354-8

  • Online ISBN: 978-3-540-33355-5

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics