🤬
  • Add plugin representation protos used for the RPC service and data between language servers.

    PiperOrigin-RevId: 454913844
    Change-Id: I498f98cf5bd6ff5a6dafa8a088f5d465be99707b
  • Loading...
  • John Y. Kim committed with Copybara-Service 2 years ago
    6d628ca4
    1 parent 7cf2e835
Revision indexing in progress... (symbol navigation in revisions will be accurate after indexed)
  • ■ ■ ■ ■ ■ ■
    proto/plugin_representation.proto
     1 +/*
     2 + * Copyright 2020 Google LLC
     3 + *
     4 + * Licensed under the Apache License, Version 2.0 (the "License");
     5 + * you may not use this file except in compliance with the License.
     6 + * You may obtain a copy of the License at
     7 + *
     8 + * http://www.apache.org/licenses/LICENSE-2.0
     9 + *
     10 + * Unless required by applicable law or agreed to in writing, software
     11 + * distributed under the License is distributed on an "AS IS" BASIS,
     12 + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     13 + * See the License for the specific language governing permissions and
     14 + * limitations under the License.
     15 + */
     16 + 
     17 +// Data representation of a tsunami plugin definition passed between language servers.
     18 +syntax = "proto3";
     19 + 
     20 +package tsunami.proto;
     21 + 
     22 +option java_multiple_files = true;
     23 +option java_outer_classname = "PluginRepresentationProtos";
     24 +option java_package = "com.google.tsunami.proto";
     25 +option go_package = "github.com/google/tsunami-security-scanner/proto";
     26 + 
     27 +// Represents a PluginDefinition placeholder.
     28 +message PluginDefinition {
     29 + // PluginInfo of this definition.
     30 + PluginInfo info = 1;
     31 + 
     32 + // The name of the target service.
     33 + TargetServiceName target_service_name = 2;
     34 + 
     35 + // The name of the target software.
     36 + TargetSoftware target_software = 3;
     37 + 
     38 + // If the definition is for a web service or not.
     39 + bool for_web_service = 4;
     40 +}
     41 + 
     42 +// Represents a PluginInfo annotation placeholder used by the PluginDefinition proto above.
     43 +message PluginInfo {
     44 + enum PluginType {
     45 + // Plugin is an unspecified type.
     46 + PLUGIN_TYPE_UNSPECIFIED = 0;
     47 + // Plugin is a port scanner.
     48 + PORT_SCAN = 1;
     49 + // Plugin is a service fingerprinter.
     50 + SERVICE_FINGERPRINT = 2;
     51 + // Plugin is a vulnerability detector.
     52 + VULN_DETECTION = 3;
     53 + }
     54 + 
     55 + // Type of plugin.
     56 + PluginType type = 1;
     57 + 
     58 + // Name of the plugin.
     59 + string name = 2;
     60 + 
     61 + // Version of the plugin
     62 + string version = 3;
     63 + 
     64 + // Description of the plugin.
     65 + string description = 4;
     66 + 
     67 + // Author of the plugin.
     68 + string author = 5;
     69 +}
     70 + 
     71 +// Represents a ForServiceName annotation placeholder used by the PluginDefinition proto above.
     72 +message TargetServiceName {
     73 + // The value of the name of the target.
     74 + repeated string value = 1;
     75 +}
     76 + 
     77 +// Represents a ForSoftware annotation placeholder used by the PluginDefinition proto above.
     78 +message TargetSoftware {
     79 + // The name of the target software, case insensitive.
     80 + string name = 1;
     81 + 
     82 + // Array of versions and version ranges of the target software.
     83 + repeated string value = 2;
     84 +}
     85 + 
Please wait...
Page is in error, reload to recover