ARTS - Week Three
Algorithm
Problem
Move Zeroes
Given an array nums
, write a function to move all 0
's to the end of it while maintaining the relative order of the non-zero elements.
Solution
Review
Artical
Hardening Your HTTP Security Headers
Link
https://www.keycdn.com/blog/http-security-headers
Review
Seven different HTTP security headers:
1. Content Security Policy
This example below allows scripts from both the current domain (defined by 'self') as well as google-analytics.com
2. X-XSS-Protection
The X-XSS-Protection
header is designed to enable the cross-site scripting (XSS) filter built into modern web browsers.
3. HTTP Strict Transport Security (HSTS)
The Strict-Transport-Security
header is a security enhancement that restricts web browsers to access web servers solely over HTTPS.
4. X-Frame-Options
The X-Frame-Options
header provides clickjacking protection by not allowing iframes to load on your website.
5. Expect-CT
The Expect-CT
header prevents misissued certificates from being used by allowing websites to report and optionally enforce Certificate Transparency requirements.
6. X-Content-Type-Options
The X-Content-Type-Options
header prevents Internet Explorer and Google Chrome from sniffing a response away from the declared Content-Type
.
7. Feature-Policy
The Feature-Policy
header grants the ability to allow or deny browser features, whether in its own frame or content within an inline frame element (<iframe>
).
How to check your HTTP security headers
1. KeyCDN's HTTP Header Checker tool
2. Chrome DevTools response headers
3. Scan your website with Security Headers https://securityheaders.com/
Taobao is in grade R; Baidu is in grade F; Google is in grade D;The website itself is A.
Tips
What do you do when you nend to exchange the value of two variables?
Share
Artical
Open Source Benefits to Innovation and Organizational Agility
Link
https://www.infoq.com/news/2019/03/open-source-benefits/
Summary
Open Source Generations
Generation one, make software free to allow anybody to contribute to their improvement.
Generation two,think about how to commercialize open source and launched the first few commercial open source companies.
Generation three, they created software that enabled them to create new streaming technologies, allowing communities and companies to innovate around these.
Generation four, These organizations are not only consuming open source in huge quantities, but they are also contributing to open source development, while open sourcing their own projects.
Five leading open source benefits
Financial benefits and secondary innovation.
Teams’ ability to safely experiment and fail fast.
Offer a better way of building software.
Attract and retain the best software developer talent.
Developers become proficient faster, reducing the number of defects in their code base.
评论