2023_05_11_134455_create_vulnerabilities_table.php
1 <?php 2 3 use Illuminate\Database\Migrations\Migration; 4 use Illuminate\Database\Schema\Blueprint; 5 use Illuminate\Support\Facades\Schema; 6 7 return new class extends Migration 8 { 9 /** 10 * Run the migrations. 11 * 12 * @return void 13 */ 14 public function up() 15 { 16 Schema::create('vulnerabilities', function (Blueprint $table) { 17 $table->id(); 18 19 $table->string('vid'); 20 $table->string('severity'); 21 $table->text('description'); 22 $table->string('state'); 23 $table->string('artifact_name'); 24 $table->string('artifact_version'); 25 $table->string('artifact_type'); 26 27 $table->string('source'); 28 29 $table->timestamps(); 30 $table->softDeletes(); 31 }); 32 } 33 34 /** 35 * Reverse the migrations. 36 * 37 * @return void 38 */ 39 public function down() 40 { 41 Schema::dropIfExists('vulnerabilities'); 42 } 43 };