تبلیغات

آموزش امنیت در آپلود فایل با PHP

دسته بندی ها: آموزش های لیندا (Lynda) ، آموزش طراحی وب ، آموزش پی اچ پی (PHP)

آموزش-امنیت-در-آپلود-فایل-با-php

یکی از رایج ترین حفره های امنیتی هک از طریق باگ File Upload می باشد. بعضی از برنامه نویسان به خیال اینکه با چند ترفند ساده می توانند جلوی این حفره خطرناک را بگیرند اقدام به طراحی بخش آپلود فایل به روش های ساده می کنند که نتیجه آن هک شدن سایتشان خواهد بود!

این دوره آموزشی از شرکت Lynda نحوه آپلود فایل در PHP با امنیت بالا را به صورت کامل آموزش می دهد.

سرفصل های دوره آموزشی:

  • محاسبه حجم فایل موقع آپلود
  • تعیین حداکثر حجم فایل قابل آپلود
  • انتقال فایل به دایرکتوری مقصد
  • نمایش خطاهای مناسب
  • محدود کردن پسوندهای مجاز برای آپلود
  • استفاده از کلاس ها
  • گزارش خطاها

لیست سرفصل های دوره آموزشی:

Uploading Files Securely with PHP

The basic process of uploading files with PHP is very simple, but there are security implications that many people are unaware of. This course shows how to create a secure custom PHP class that can handle both single-file and multi-file uploads. Author David Powers shows you how to create a file upload class that checks the size, type, and names of files, renaming them when it encounters a duplicate file name. He'll show you how to make the class report on the outcome of the upload process and the nature of any errors that occur, and how to prevent the user from uploading files that exceed the server limits.

At the end of this course, you'll have a robust, flexible class that can be incorporated into many projects (including web forms) with just a few lines of code. Topics include:

How PHP handles file uploads Setting the maximum file size Moving the file to its destination Creating and using a namespaced class Displaying error messages Restricting unacceptable MIME types and file extensions Using the class Reporting errors Altering the user

Subjects: Developer Programming Languages Web Development Software: PHP Author: David Powers

Introduction 4m 49s

Welcome 57s

What you should know before watching this course 2m 0s

Using the exercise files 1m 52s

1. File-Upload Basics 33m 2s

How PHP handles file uploads 6m 16s

Examining the $_FILES array 5m 8s

Setting the maximum file size 5m 36s

Preparing the upload folder 3m 18s

Moving the file to its destination 6m 51s

Limitations on file uploads 5m 53s

2. Creating a File-Upload Class 47m 3s

Planning the class's features 3m 15s

Creating and using a namespaced class 5m 25s

Creating the class constructor 7m 26s

Getting a reference to the uploaded file 5m 9s

Checking the error level 5m 7s

Displaying errors and other messages 4m 51s

Setting and checking the maximum file size 7m 19s

Strengthening the setMaxSize() method 8m 31s

3. Making the Class More Secure 35m 30s

Restricting acceptable MIME types 5m 27s

Removing spaces from file names 5m 21s

Restricting acceptable file-name extensions 6m 10s

Neutralizing potentially dangerous uploads 5m 54s

Renaming files with duplicate names 7m 58s

Moving the file to its destination 4m 40s

4. Handling Multiple File Uploads 10m 25s

Understanding how the $_FILES array handles multiple files 4m 42s

Adapting the class to handle both single and multiple uploads 5m 43s

5. Using the Class 38m 15s

Overview of the UploadFile class 5m 9s

Setting up to use the class 4m 11s

Using the class 8m 12s

Reporting errors with multiple uploads 4m 0s

Displaying the server limits 4m 51s

Alerting the user about exceeding the server limits 6m 14s

Changing the class's defaults 5m 38s

Conclusion 1m 38s

Goodbye 1m 38s

عنوان دوره: Lynda - Uploading Files Securely with PHP حجم فایل: 324MB

آیا این نوشته را دوست داشتید؟
Lynda Uploading Files Securely with PHP

پیشنهاد فرادرس