Securing the Sage Notebook

Yoav Aner

(2009)

Yoav Aner (2009) Securing the Sage Notebook.

Our Full Text Deposits

Full text access: Open

Full Text - 934.89 KB

Links to Copies of this Item Held Elsewhere


Abstract

This paper looks at some of the information security challenges of Web based Open Source applications through a case study of the Sage Notebook application. Considering the core underlying issues of open source and web based applications, predominately the fact that the source code of the application is exposed to any potential attacker, the paper investigates methodologies to examine and improve upon the security of such applications. The Sage Notebook application provides some unique information security challenges, both in terms of analysis and mitigation. The paper uses a structured threat modelling process based on industry methodologies to identify threats and vulnerabilities to both the Sage open source development process and the application itself. It rates the discovered threats and suggests several mitigation options to consider. The paper analyses the ndings, focusing on several architectural and design mitigation options, and investigates some of the technologies and tools to address the discovered threats and vulnerabilities most eectively. It covers generic open source and web based security challenges as well as issues aecting cloud computing, software as a service, virtualisation, process isolation and containments and others.

Information about this Version

This is a Published version
This version's date is: 01/09/2009
This item is peer reviewed

Link to this Version

https://repository.royalholloway.ac.uk/items/4120e089-8b7a-357b-a507-107ea922402e/1/

Item TypeMonograph (Technical Report)
TitleSecuring the Sage Notebook
AuthorsAner, Yoav
DepartmentsFaculty of Science\Mathematics

Deposited by () on 23-Jun-2010 in Royal Holloway Research Online.Last modified on 15-Dec-2010

Notes

References

[1] M.D. Abrams, KW Eggers, L. LaPadula, and I. Olson. A generalized
framework for access control: An informal description. In Proceedings of
the 13th National Computer Security Conference, pages 135{143, 1990.

[2] Y. Aner. Sage Development Process Threat Model. Available at http://
groups.google.com/group/sage-devel/msg/1f851e27f5500712. Last
accessed, 18 August 2009.

[3] M. Armbrust, A. Fox, R. Grith, A.D. Joseph, R.H. Katz, A. Konwinski,
G. Lee, D.A. Patterson, A. Rabkin, I. Stoica, et al. Above
the clouds: A Berkeley view of cloud computing. EECS Department,
University of California, Berkeley, Tech. Rep. UCB/EECS-2009-28,
2009. Available at http://www.eecs.berkeley.edu/Pubs/TechRpts/
2009/EECS-2009-28.pdf. Last accessed, 28 August 2009.

[4] K. Bennett, P. Layzell, D. Budgen, P. Brereton, L. Macaulay, and
M. Munro. Service-based software: the future for
exible software. In
Software Engineering Conference, 2000. APSEC 2000. Proceedings. Sev-
enth Asia-Paci c, pages 214{221, 2000.

[5] M. Bishop and M. Dilger. Checking for race conditions in le accesses.
Computing systems, 2(2):131{152, 1996.

[6] B. Boehm and V.R. Basili. Software defect reduction top 10 list. IEEE
Computer, 34(1):135{137, 2001.

[7] S R Bourne. Unix time-sharing system: The unix shell. Bell System
Technical Journal, (57):1971{1990, 1978.

[8] R. Buyya, C.S. Yeo, S. Venugopal, J. Broberg, and I. Brandic. Cloud
computing and emerging IT platforms: Vision, hype, and reality for delivering
computing as the 5th utility. Future Generation Computer Systems,
25(6):599{616, 2009.

[9] C. Castelluccia, E. Mykletun, and G. Tsudik. Improving secure server
performance by re-balancing SSL/TLS handshakes. In Proceedings of the
2006 ACM Symposium on Information, computer and communications
security, pages 26{34. ACM New York, NY, USA, 2006.

[10] CERT Coordination Center, Software Engineering Institute,Carnegie Mellon
University. malicious HTML tags embedded in client web requests.

Technical report, CA-2000-02, 2000. Available at http://www.cert.org/
advisories/CA-2000-02.html. Last accessed, 28 August 2009.

[11] O. Certik. notebook rewrite. Available at http://groups.google.
com/group/sage-devel/browse_thread/thread/65ca1e0489a0a980/
c3abd60f1e13a3a3. Last accessed, 24 August 2009.

[12] P.M. Chen and B.D. Noble. When virtual is better than real. In Proceed-
ings of the 2001 Workshop on Hot Topics in Operating Systems (HotOS),
pages 133{138, 2001.

[13] B. Chess and G. McGraw. Static analysis for security. IEEE Security &
Privacy, pages 76{79, 2004.

[14] S. Christey and R.A. Martin. Vulnerability type distributions in CVE.
Common Weakness Enumeration, version, 1.1, 2007. Available at http:
//cwe.mitre.org/documents/vuln-trends.html. Last accessed, 30 August
2009.

[15] A. Chuvakin. Using Chroot Securely. Available at http://www.
linuxsecurity.com/content/view/117632/49/, 2007. Last accessed, 21
August 2009.

[16] Coverity. Coverity Prevent - Static Analysis. Available at http://
www.coverity.com/products/coverity-prevent.html. Last accessed,
27 July 2009.

[17] W. Die. Risky business: Keeping security a secret. Available at http:
//news.zdnet.com/2100-9595_22-127072.html, 2003. Last accessed,
14 July 2009.

[18] D. Evans and D. Larochelle. Improving security using extensible
lightweight static analysis. IEEE software, pages 42{51, 2002.

[19] D.C. Feldmeier and P.R. Karn. UNIX Password Security-Ten Years Later.
In Proceedings of the 9th Annual International Cryptology Conference on
Advances in Cryptology, pages 44{63. Springer-Verlag London, UK, 1989.

[20] V. Felmetsger and G. Vigna. Exploiting OS-level mechanisms to implement
mobile code security. In 10th IEEE International Conference on
Engineering of Complex Computer Systems, 2005. ICECCS 2005. Pro-
ceedings, pages 234{243, 2005.

[21] J. Fisher-Ogden. Hardware support for ecient virtualization. Available
at http://cseweb.ucsd.edu/~jfisherogden/hardwareVirt.pdf, 2006.
Last accessed, 25 August 2009.

[22] B. Foote and J. Yoder. Big ball of mud. In Pattern Languages of Program
Design, pages 653{692. Addison-Wesley, 1999.

[23] Django Software Foundation. User authentication in Django. Available
at http://docs.djangoproject.com/en/dev/topics/auth/. Last accessed,
25 July 2009.

[24] M. Fox, J. Giordano, L. Stotler, and A. Thomas. Selinux
and grsecurity: A case study comparing linux security kernel enhancements.
Available at http://www.cs.virginia.edu/~jcg8f/
GrsecuritySELinuxCaseStudy.pdf, 2003. Last accessed, 27 August
2009.

[25] Free Software Foundation. The free software de nition. Available at
http://www.fsf.org/licensing/essays/free-sw.html. Last accessed,
14 July 2009.

[26] Free Software Foundation. GNU General Public License. Available at
http://www.gnu.org/licenses/gpl.html. Last accessed, 28 July 2009.

[27] Free Software Foundation. The GNU Privacy Guard. Available at http:
//www.gnupg.org/. Last accessed, 28 July 2009.

[28] Free Software Foundation. Selling Free Software. Available at http:
//www.gnu.org/philosophy/selling.html. Last accessed, 28 July 2009.

[29] The GAP Group. GAP - Groups, Algorithms, Programming - a System for
Computational Discrete Algebra. Available at http://www.gap-system.
org/. Last accessed, 28 July 2009.

[30] J. Gardner. Authkit - WSGI Authentication and Authorization Tools.
Available at http://authkit.org/. Last accessed, 25 July 2009.

[31] J.J. Garrett et al. Ajax: A new approach to web applications. Adaptive
path, February 18, 2005. Available at http://www.adaptivepath.com/
publications/essays/archives/000385.php. Last accessed, 27 August
2009.

[32] C. Gebhardt and A. Tomlinson. Security consideration for virtualization.
Technical Report RHUL{MA{2008{16, Department of Mathematics,
Royal Holloway, University of London, 2008. Available at http://www.
ma.rhul.ac.uk/static/techrep/2008/RHUL-MA-2008-16.pdf. Last accessed,
28 August 2009.

[33] A. Ghitza. checklist for reviewing an spkg? Available at
http://groups.google.com/group/sage-devel/browse_thread/
thread/030ff5c32e632936#. Last accessed, 18 August 2009.

[34] D. Gollmann. Computer security. John Wiley & Sons, second edition,
2005.

[35] G.-M. Greuel, G. P ster, and H. Schonemann. Singular A computer
algebra system for polynomial computations. Available at http://www.
singular.uni-kl.de. Last accessed, 28 July 2009.

[36] R. Harrison. Lightweight Directory Access Protocol (LDAP): Authentication
Methods and Security Mechanisms. RFC 4513, Internet Engineering
Task Force, June 2006. Available at http://tools.ietf.org/html/
rfc4513. Last accessed, 28 August 2009.

[37] J.H. Hoepman and B. Jacobs. Increased security through open source.
COMMUNICATIONS{ACM, 50:79{84, 2007.

[38] M. Howard and D.E. Leblanc. Writing secure code. Microsoft Press,
second edition, 2002.

[39] M. Howard and S. Lipner. The Security Development Lifecycle. Microsoft
Press, 2006.

[40] T. Howlett. Open Source Security Tools: Pratical Guide to Security Ap-
plications, A. Prentice Hall PTR Upper Saddle River, NJ, USA, 2004.

[41] Y.W. Huang, F. Yu, C. Hang, C.H. Tsai, D.T. Lee, and S.Y. Kuo. Securing
web application code by static analysis and runtime protection.
In Proceedings of the 13th international conference on World Wide Web,
pages 40{52. ACM New York, NY, USA, 2004.

[42] IBM Internet Security Systems. X-Force R
2008 Midyear Trend Statistics.
Available at http://www-935.ibm.com/services/us/iss/xforce/
midyearreport/xforce-midyear-report-2008.pdf. Last accessed, 17
August 2009.

[43] Open Source Initiative. Available at http://www.opensource.org. Last
accessed, 14 July 2009.

[44] ISO/IEC. ISO/IEC 27005:2008 Information technology - Security techniques
- Information security risk management. First edition, International
Organization for Standardization, Geneva, Switzerland., 2008.

[45] S. Jain, F. Sha que, V. Djeric, and A. Goel. Application-level isolation and
recovery with solitude. In Proceedings of the 3rd ACM SIGOPS/EuroSys
European Conference on Computer Systems 2008, pages 95{107. ACM
New York, NY, USA, 2008.

[46] M. Jakobsson. Modeling and Preventing Phishing Attacks. In Financial
cryptography and data security: 9th international conference, FC 2005,
Roseau, The Commonwealth of Dominica, February 28-March 3, 2005:
revised papers, page 89. Springer Verlag, 2005.

[47] M. Jawurek. RSBAC{a framework for enhanced Linux system security.
In Dependable Distributed Systems, Laboratory of dependable distributed
systems, RWTH Aachen University, 2006. Available at http://rsbac.
org/doc/media/rsbac-marek2006.pdf. Last accessed, 28 August 2009.

[48] A. Joshi, S.T. King, G.W. Dunlap, and P.M. Chen. Detecting past and
present intrusions through vulnerability-speci c predicates. In Proceedings
of the twentieth ACM symposium on Operating systems principles, pages
91{104. ACM New York, NY, USA, 2005.

[49] E. Kenneally. Stepping on the digital scale{Duty and Liability for Negligent
Internet Security. ;login: The Magazine of USENIX & SAGE,
26(8):62{77, 2001.

[50] Auguste Kerckho s. "la cryptographie militaire". Journal des sciences
militaires, vol. IX, 1883. available at http://www.petitcolas.net/
fabien/kerckhoffs/, Last accessed, 14 July 2009.

[51] N. Kiyanclar. A survey of virtualization techniques focusing on secure ondemand
cluster computing. Arxiv preprint cs/0511010, 2005. Available
at http://arxiv.org/pdf/cs/0511010. Last Accessed, 30 August 2009.

[52] Klocwork. Klockwork Insight. Available at http://www.klocwork.com/
products/insight.asp. Last accessed, 27 July 2009.

[53] J. Kohl and C. Neuman. The Kerberos network authentication service
(v5). RFC 1510, Internet Engineering Task Force, 1993. Available at
http://tools.ietf.org/html/rfc1510. Last accessed, 28 August 2009.

[54] Vassiliki Koutsonikola and Athena Vakali. LDAP: Framework, Practices,
and Trends. IEEE Internet Computing, 8(5):66{72, 2004.

[55] K.A. Kozar. Representing systems with data
ow diagrams. Available at
http://spot.colorado.edu/~kozar/DFD.html, 1997. Last accessed, 27
August 2009.

[56] P.G. Larsen, N. Plat, and H. Toetenel. A formal semantics of data
ow
diagrams. Formal aspects of Computing, 6(6):586{606, 1994.

[57] N. Li, Z. Mao, and H. Chen. Usable mandatory integrity protection for
operating systems. In IEEE Symposium on Security and Privacy, 2007.
SP'07, pages 164{178, 2007.

[58] Mailman, the GNU Mailing List Manager. Available at http://www.gnu.
org/software/mailman/index.html. Last accessed, 18 July 2009.

[59] A. Martelli and D. Ascher. Python cookbook. O'Reilly Media, Inc., 2005.

[60] C. McDonough. repoze.who - wsgi authentication middleware. Available
at http://docs.repoze.org/who/. Last accessed, 25 July 2009.

[61] G. McGraw and Viega J. Software security principles: Part 3. Available
at http://www.ibm.com/developerworks/library/s-priv.html, 2000.
Last accessed, 21 August 2009.

[62] Gary McGraw. Software security. IEEE Security & Privacy, March/April
2004.

[63] Microsoft. Windows Server 2008 Active Directory. Available
at http://www.microsoft.com/windowsserver2008/en/us/
active-directory.aspx. Last accessed, 5 August 2009.

[64] G. Narea. repoze.what - authorization for wsgi applications. Available
at http://what.repoze.org/docs/1.x/. Last accessed, 25 July 2009.

[65] National Security Agency. Security-Enhanced Linux. Available at http:
//www.nsa.gov/research/selinux/index.shtml. Last accessed, 21 August
2009.

[66] R.M. Needham and M.D. Schroeder. Using encryption for authentication
in large networks of computers. COMMUNICATIONS{ACM, 21(12):993{
999, 1978.

[67] Net lter.org. The net lter.org iptables project. Available at http:
//www.netfilter.org/projects/iptables/index.html. Last accessed,
28 July 2009.

[68] Novell. Project AppArmor. Available at http://forge.novell.com/
modules/xfmod/project/?apparmor. Last accessed, 21 August 2009.

[69] OpenBSD. OpenSSH. Available at http://www.openssh.com/. Last
accessed, 28 July 2009.

[70] OpenLDAP Foundation. OpenLDAP - community developed LDAP Software.
Available at http://www.openldap.org/. Last accessed, 5 August
2009.

[71] T. Ormandy. An empirical study into the security exposure to host of
hostile virtualized environments. In CanSecWest 2007: Applied Security
Conference, 2007.

[72] A. Ott. RSBAC { Rule Set Based Access Control. Available at http:
//www.rsbac.org/. Last accessed, 22 August 2009.

[73] M.P. Papazoglou. Service-oriented computing: Concepts, characteristics
and directions. In Proceedings of the Fourth International Conference
on Web Information Systems Engineering, pages 3{12. NW Washington:
IEEE Computer Society, 2003.

[74] LD Paulson. Building rich web applications with Ajax. Computer,
38(10):14{17, 2005.

[75] V. Prevelakis and D. Spinellis. Sandboxing applications. In Proceedings of
the USENIX Technical Annual Conference, Freenix Track, pages 119{126,
2001.

[76] Python Software Foundation. pickle - Python Object Serialization. Available
at http://docs.python.org/library/pickle.html. Last accessed,
28 July 2009.

[77] N.A. Quynh, R. Ando, and Y. Takefuji. Centralized security policy support
for virtual machine. In LISA '06: Proceedings of the 20th conference
on Large Installation System Administration, pages 79{87, Berkeley, CA,
USA, 2006. USENIX Association.

[78] E. Raymond. The cathedral and the bazaar. Knowledge, Technology, and
Policy, 12(3):23{49, 1999.

[79] J.S. Reuben. A Survey on Virtual Machine Security. Helsinki University of
Technology, 2007. Available at http://www.tml.tkk.fi/Publications/
C/25/papers/Reuben_final.pdf. Last accessed, 30 August 2009.

[80] R. Sailer, E. Valdez, T. Jaeger, R. Perez, L. Van Doorn, J.L. Grif-
n, and S. Berger. sHype: Secure hypervisor approach to trusted
virtualized systems. IBM Research Report RC23511, 2005. Available
at http://domino.watson.ibm.com/library/cyberdig.nsf/
papers/265c8e3a6f95ca8d85256fa1005cbf0f/$file/rc23511.pdf.
Last accessed, 30 August 2009.


[81] J.H. Saltzer and M.D. Schroeder. The protection of information in computer
systems. Proceedings of the IEEE, 63(9):1278{1308, 1975.

[82] J. Scambray, M. Shema, and C. Sima. Hacking Exposed Web Applications.
McGraw-Hill Osborne Media, second edition, 2006.

[83] Bruce Schneier. Open source and security. Crypto-Gram. Counterpane
Internet Security, Inc., September 15, 1999. Available at http://www.
counterpane.com/crypto-gram-9909.html. Last accessed, 25 July 2009.

[84] D. Scott and R. Sharp. Specifying and enforcing application-level web
security policies. IEEE Transactions on Knowledge and data Engineering,
pages 771{783, 2003.

[85] Michael Scovetta. YASCA - Yet Another Source Code Analyzer. Available
at http://sourceforge.net/projects/yasca/. Last accessed, 27 July
2009.

[86] Secure Software Inc. RATS - Rough Auditing Tool for Security. Available
at http://www.fortify.com/security-resources/rats.jsp. Last
accessed, 27 July 2009.

[87] S. Shankland. Novell lays o AppArmor programmers. Available
at http://news.cnet.com/8301-13580_3-9796140-39.html?part=
rss&subj=news&tag=2547-1_3-0-5, 2007. Last accessed, 21 August
2009.

[88] A. Shostack. Experiences Threat Modeling at Microsoft. In Modeling
Security Workshop. Dept. of Computing, Lancaster University, UK, 2008.
Available at: http://blogs.msdn.com/sdl/attachment/8991806.ashx. Last
accessed, 27 August 2009.

[89] S. Smalley and T. Fraser. A Security Policy Con guration for the Security-
Enhanced Linux. 2001. Available at http://www.artware.qc.ca/~fil/
banned/selinux/policy-200012181053.pdf. Last accessed, 28 August
2009.

[90] S. Soltesz, H. Potzl, M.E. Fiuczynski, A. Bavier, and L. Peterson.
Container-based operating system virtualization: A scalable, highperformance
alternative to hypervisors. In Proceedings of the 2nd ACM
SIGOPS/EuroSys European Conference on Computer Systems 2007,
pages 275{287. ACM New York, NY, USA, 2007.

[91] B. Spengler. grsecurity. Available at http://www.grsecurity.net/
index.php. Last accessed, 22 August 2009.

[92] W. A. Stein et al. Sage Components. The Sage Development Team.
Available at http://www.sagemath.org/links-components.html. Last
accessed, 28 July 2009.

[93] W. A. Stein et al. Sage Notebook Public Server. The Sage Development
Team. Available at http://www.sagenb.org/. Last accessed, 28 July
2009.

[94] W. A. Stein et al. Sage Mathematics Software (Version 4.1.1). The
Sage Development Team, 2009. http://www.sagemath.org. Last accessed,
25 August 2009.

[95] Z. Su and G. Wassermann. The essence of command injection attacks in
web applications. In Annual Symposium on Principles of Programming
Languages, pages 372{382. ACM New York, NY, USA, 2006.

[96] F. Swiderski and W. Snyder. Threat Modeling. Microsoft Press, 2004.

[97] A.S. Tanenbaum. Modern Operating Systems. Prentice Hall Press, Upper
Saddle River, NJ, USA, third edition, 2007.

[98] G. Tassey. The economic impacts of inadequate infrastructure for software
testing. National Institute of Standards and Technology RTI Project, 2002.
Available at http://citeseerx.ist.psu.edu/viewdoc/download?doi=
10.1.1.122.3316&rep=rep1&type=pdf. Last accessed, 30 August 2009.

[99] The codenode group. codenode. Available at http://codenode.org/.
Last accessed, 24 August 2009.

[100] G. Tornaria. Question about notebook server setup in a VM.
Available at http://groups.google.com/group/sage-devel/browse_
thread/thread/3927795c8f1c8a8f/2f21594bd6486d6. Last accessed,
29 August 2009.

[101] P. Torr. Demystifying the threat-modeling process. IEEE Security &
Privacy, pages 66{70, 2005.

[102] TrueCrypt Foundation. Truecrypt - Free open-source disk encryption
software for Windows Vista/XP, Mac OS X, and Linux. Available at
http://www.truecrypt.org/. Last accessed, 28 July 2009.

[103] K. Tsipenyuk, B. Chess, and G. McGraw. Seven pernicious kingdoms: A
taxonomy of software security errors. IEEE Security & Privacy, 3(6):81{
84, 2005.

[104] G. van Rossum and T. Peters. PEP-307 Extensions to the pickle protocol.
Available at http://www.python.org/dev/peps/pep-0307/. Last
accessed, 28 July 2009.

[105] J. Viega. The myth of open source security. Available at http:
//www.developer.com/tech/article.php/10923_626641_1, 2000. Last
accessed, 18 July 2009.

[106] J. Viega. The Myths of Security: What the Computer Security Industry
Doesn't Want You to Know. O'Reilly Media, Inc, 2009.

[107] M.A. Vouk. Cloud computing{Issues, research and implementations. In
Information Technology Interfaces, 2008. ITI 2008. 30th International
Conference on, pages 31{40, 2008.

[108] P. Watkins. Cross Site Request Forgeries (CSRF). BugTraq posting, 2001.
Available at http://www.tux.org/~peterw/csrf.txt. Last accessed, 27
August 2009.

[109] Y. Wilajati Purna. LIDS Trusted Domain Enforcement (TDE):
An Introduction. Available at http://www.lids.org/document/
LIDS-TDE-feature.txt, 2004. Last accessed, 21 August 2009.

[110] B. Witten, C. Landwehr, and M. Caloyannides. Does open source improve
system security? IEEE SOFTWARE, pages 57{61, 2001.

[111] H. XIE. LIDS Hacking HOWTO. Available at http://www.lids.org/
lids-howto/lids-hacking-howto.html, 2000. Last accessed, 21 August
2009.

[112] H. XIE, P. Biondi, Y. Wilajati Purna, S. Klein, and K. Omo. LIDS {
Linux Intrusion Detection System. Available at http://www.lids.org/.
Last accessed, 21 August 2009.

[113] T. Ylonen. The Secure Shell (SSH) Authentication Protocol. RFC 4252,
Internet Engineering Task Force, January 2006. Available at http://
tools.ietf.org/html/rfc4252. Last accessed, 28 August 2009.


Details