diff --git a/video.field.inc b/video.field.inc
index 20766c2..2fef310 100644
--- a/video.field.inc
+++ b/video.field.inc
@@ -392,6 +392,10 @@ function video_field_validate($entity_type, $entity, $field, $instance, $langcod
 
   $current_files = file_load_multiple($current_fids);
   $validators = file_field_widget_upload_validators($field, $instance);
+  // Don't validate size for CORS.
+  if (module_exists('amazons3_cors')) {
+    unset($validators['file_validate_size']);
+  }
   if (empty($validators)) {
     // No validation rules
     return;
@@ -618,8 +622,20 @@ function video_field_widget_info() {
  * Implements hook_field_widget_settings_form().
  */
 function video_field_widget_settings_form($field, $instance) {
+  // CORS Upload support.
+  $form = array();
+  if (module_exists('amazons3_cors')) {
+    $form['s3_acl'] = array(
+      '#type' => 'select',
+      '#title' => t('ACL'),
+      '#description' => t('In addition to whatever options you select here the object owner will always be granted full control of all objects. See the <a href="http://docs.aws.amazon.com/AmazonS3/latest/dev/ACLOverview.html">API documentation</a> for more information.'),
+      '#options' => _amazons3_cors_acl_options(),
+      '#default_value' => isset($settings['s3_acl']) ? $settings['s3_acl'] : '',
+    );
+  }
+  $return = array_merge(file_field_widget_settings_form($field, $instance), $form);
   // Use the file widget settings form.
-  return file_field_widget_settings_form($field, $instance);
+  return $return;
 }
 
 /**
@@ -644,6 +660,38 @@ function video_field_widget_form(&$form, &$form_state, $field, $instance, $langc
 
     // Add all extra functionality provided by the video widget.
     $elements[$delta]['#process'][] = 'video_field_widget_process';
+    if (module_exists('amazons3_cors')) {
+      $elements[$delta]['#input'] = TRUE;
+      $elements[$delta]['#process'][] = 'amazons3_cors_upload_process';
+      $elements[$delta]['#element_validate'] = array('amazons3_cors_upload_validate');
+      $elements[$delta]['#upload_location'] = '';
+      $elements[$delta]['#size'] = 22;
+      $elements[$delta]['#s3_acl'] = 'private';
+      $elements[$delta]['#extended'] = TRUE;
+      $elements[$delta]['#attached'] = array(
+        'js' => array(
+          drupal_get_path('module', 'amazons3_cors') . '/amazons3_cors.js',
+          // We also add the file.module's JS which does things like client side
+          // validation for us!
+          drupal_get_path('module', 'file') . '/file.js',
+        ),
+        'library' => array(array('system', 'ui.progressbar')),
+      );
+      $elements[$delta]['#upload_location'] = file_field_widget_uri($field, $instance);
+      $elements[$delta]['#s3_acl'] = $instance['widget']['settings']['s3_acl'];
+      // Load default value.
+      if (isset($form_state['values'][$field['field_name']][$langcode])) {
+        $items = $form_state['values'][$field['field_name']][$langcode];
+      }
+      // Set the default value.
+      $elements[$delta]['#default_value'] = !empty($items) ? $items[$delta] : array(
+        'fid' => 0,
+        'display' => !empty($field['settings']['display_default']),
+        'description' => '',
+      );
+      // Unset the file_size validator.
+      unset($elements[$delta]['#upload_validators']['file_validate_size']);
+    }
 
     // Add thumbnail stub to prevent errors in file_ajax_upload().
     $elements[$delta]['thumbnail'] = array(
@@ -674,8 +722,15 @@ function video_field_widget_form(&$form, &$form_state, $field, $instance, $langc
  * video_field_widget_process().
  */
 function video_field_widget_value($element, $input = FALSE, $form_state) {
-  // file_field_widget_value() also takes care of adding $input to $value.
-  $value = file_field_widget_value($element, $input, $form_state);
+  // Enable CORS Upload.
+  if (module_exists('amazons3_cors')) {
+    $value = amazons3_cors_field_widget_value($element, $input, $form_state);
+    $value['display'] = FALSE;
+  }
+  else {
+    // file_field_widget_value() also takes care of adding $input to $value.
+    $value = file_field_widget_value($element, $input, $form_state);
+  }
 
   // Extra default values.
   $value += array(
@@ -749,7 +804,6 @@ function video_field_widget_value($element, $input = FALSE, $form_state) {
       $value['dimensions'] = key($alldimensions);
     }
   }
-
   return $value;
 }
 
@@ -760,7 +814,6 @@ function video_field_widget_process($element, &$form_state, $form) {
   $file = $element['#value'];
   $file['fid'] = $fid = intval($element['fid']['#value']);
   $field = field_widget_field($element, $form_state);
-
   $element['#theme'] = 'video_widget';
 
   // Title is not necessary for each individual field.
@@ -1082,23 +1135,23 @@ function video_field_formatter_settings_form($field, $instance, $view_mode, $for
         '#options' => $image_styles,
       );
       break;
-      
+
 	case 'video_formatter_url':
       // Get the transcoder presets
       $presets = variable_get('video_preset');
-      $preset_extensions = array('original' => t('Original video format'));      
+      $preset_extensions = array('original' => t('Original video format'));
       foreach ($presets as $preset){
         $preset_settings = video_get_preset($preset);
         $preset_extensions[$preset_settings['settings']['video_extension']] = $preset_settings['settings']['video_extension'];
       }
-      
+
       $element['video_extension'] = array(
         '#title' => t('Video format'),
         '#type' => 'select',
         '#default_value' => $settings['video_extension'],
         '#options' => $preset_extensions,
       );
-      
+
       $element['link_title'] = array(
         '#title' => t('Link title'),
         '#type' => 'textfield',
@@ -1227,9 +1280,9 @@ function video_field_formatter_view($entity_type, $entity, $field, $instance, $l
           $element[$delta] = array(
             '#markup' => l($title, file_create_url($item['uri'])),
             );
-            break;            
+            break;
         }
-      
+
         // Nobody believes in standards
         // @TODO revisit this, there must be a better way to replace the mimetypes
         $extensions_fix = array('flv' => 'x-flv');
@@ -1240,7 +1293,7 @@ function video_field_formatter_view($entity_type, $entity, $field, $instance, $l
         }
 
         $title = empty($settings['link_title']) ? NULL : $settings['link_title'];
-        
+
         // Find the file based on the selected video type
         foreach ($item['playablefiles'] as $file){
           if (strstr($file->filemime, 'video/' . $extension)) {
@@ -1314,7 +1367,7 @@ function _video_field_file_autoconversion($entity_type, $entity, $field, $instan
       }
       // Load a fresh copy of the job
       $video = video_jobs::load($fid);
- 
+
 	 // for case that video was not created through the form, we should check if it has a allowed extension and if needed, generate thumbnails.
 	 $fextension = video_utility::getExtension($video->filename);
 	 if ( strpos($info_instance['settings']['file_extensions'], $fextension) === false) {
@@ -1324,7 +1377,7 @@ function _video_field_file_autoconversion($entity_type, $entity, $field, $instan
 	// if thumbnail(s) already exists or autocreation for thumbnails is disabled, do nothing.
 	if (empty($item['thumbnail']) && $field['settings']['autothumbnail'] == 'auto' ) {
 	$thumbs = $transcoder->extractFrames($item, $field);
-	// if thumbnails creation fails, we can assume, that something in the file is wrong and encoding will also fail     
+	// if thumbnails creation fails, we can assume, that something in the file is wrong and encoding will also fail
 	if ($thumbs === FALSE) {
 		drupal_set_message(t('Thumbnails creation for '.$video->filename.' failed. Encoding job for '.$transcoder->getTranscoder()->getName(). ' cannot be created. Please check your recent log entries for further debugging.'),'error');
         return;
