NCSC warns organisations to ditch Python 2 before it hits end of life
The National Cyber Security Centre (NCSC) has advised organisations still using Python 2 code to port it to Python 3 as soon as possible before it goes end of life at the turn of the new year.
The cyber security arm of GCHQ said that because Python's core developers will stop working on updates, vulnerabilities in the code will go unpatched and leave organisations vulnerable to cyber attacks.
Moreover, if an organisation is maintaining a library written in Python 2 that other people depend on, then those dependencies are being delayed in their own upgrades which, in turn, adversely affects their cyber security resilience.
"If you continue to use unsupported modules, you are risking the security of your organisation and data, as vulnerabilities will sooner or later appear which nobody is fixing," said the NCSC in a blog post.
Outlining the scale of the problem, the NCSC showed data from June 2019 of the ten most popular Python packages downloaded by millions every month. It showed the majority of the packages were still written predominantly in Python 2 and the ones like Flask which were written mainly in Python 3, still had around a third of their content in the soon-to-be EOL version.
"Even if only a portion of these downloads are being used in live projects, the Python 2 EOL could potentially affect the security of millions of systems," said the security body.
It's important for organisations to fully migrate over to Python 3 as the way to the two languages are structured could create code incompatibilities in their libraries.
For example, text strings are stored differently in the two languages as Python 2 stores in ASCII which uses 8-bit encoding whereas Python 3's Unicode uses variable bit encoding so it will support most written languages while ASCII won't.
"The impending end-of-life of Python 2 illustrates both the importance of managing a complex software supply chain of third-party components and platforms, as well as the critical need for updates," said Jonathan Knudsen, senior security strategist at Synopsys. "Customers will avoid or ignore updates that are not drop-dead simple, or automatic, which can result in stale deployments that are plagued by bugs that have already been fixed."
Python 3 is essentially a more intelligent language that comes bundled with lots of new features that makes coding easier and less convoluted. It irons out some annoying features of Python 2 such as integer division which would previously round down to the nearest whole number.
The NCSC recognises that porting all of an organisation's code to a new language can be a daunting task, but there are tools out there to help make it easier.
'Can I Use Python 3' is a program which will scan projects for dependencies that will prevent porting to Python 3, while '2to3' is a tool which will attempt to port Python 2 source code into 3.
The official Python website will also have documentation that organisations will find helpful and links to free resources to help further with the process.
source itpro
Industry: Cyber Security
Latest Jobs
-
- Cyber Security Senior Consultant | London | FS
- London
- Apply today
-
London | FS | Cyber Security Senior Consultant We are looking for experienced cyber security consultant with experience helping clients within the financial services industry. The role will include, but not be limited to; Conduct cyber security assessments, develop strategies, and provide advice to clients. Oversee and deliver security improvements projects. Help clients understand and comply with financial sector regulations. Provide insights and thought leadership on emerging trends in cyber security. Current experience within a client facing, cyber consulting role within Financial Services is essential. All the usual badges are nice to have, although not essential- for example; ISO27001, CISSP, CISM etc etc Sponsorship is not available for this role. Applicants must be UK based and able to travel on occasion to client site and the office in London To find out more reach out to me on 07884666351 or chris.holt@dclsearch.com
-
- Senior Penetration Tester - UK - Ability to achieve security clearance.
- United Kingdom
- To attract the right person
-
Senior Penetration tester, who has the ability to achieve security clearance. (Visa sponsorships NOT available - sorry) UK based - remote first - occasional travel. Red teaming experience desirable. The successful person needs to have a history of engaging directly with customers (consultancy experience) technical delivery of penetration tests AND report writing. Limited travel - company operates a remote first approach. Must be living in the UK. Not one of the usual names in the pen testing industry. Looking for someone highly technical but looking to grow and develop their skills. Apply here or Reach out to me on chris.holt@dclsearch.com or 07884666351 All details kept discreet
-
- Cloud Architect- German Speaker
- Hungary
- Upto €48000 per year + bonus + benefits
-
As a Senior Pre-Sales Solutions Architect, you will play a pivotal role in driving our sales success by translating complex technical solutions into compelling proposals that resonate with our clients. You will collaborate closely with our sales teams to understand customer needs, design tailored solutions, and negotiate successful deals. Responsibilities: Solution Design: Develop comprehensive technical solutions that align with customer business objectives and industry best practices. Proposal Development: Create compelling proposals, including requirements gathering questionnaires, presentation materials, and Statements of Work (SOWs). Customer Engagement: Build strong relationships with clients, understanding their technical, business, and commercial requirements. Collaboration: Work closely with sales teams, delivery teams, and third-party partners to ensure successful project execution. Pricing Strategy: Define and deliver pricing strategies that align with customer needs and company objectives. Requirements: Experience in technical pre-sales or sales support roles. Proven track record in designing and delivering successful customer solutions. Strong technical foundation in areas such as VMware, Azure, AWS, cloud computing, and data center technologies. Excellent understanding of sales principles, account management, and negotiation techniques. Ability to explain complex technical concepts clearly and concisely. Experience working in international teams and supporting clients across multiple regions. Fluency in German and English is essential. Benefits: Competitive salary and benefits package Opportunity to work on challenging and rewarding projects Collaborative and supportive work environment Potential for career growth and advancement Please note that this role is focused on supporting German clients, but will also involve global client support as needed.