Class: Google::Cloud::SecurityCenter::V2::File

Inherits:
Object
  • Object
show all
Extended by:
Protobuf::MessageExts::ClassMethods
Includes:
Protobuf::MessageExts
Defined in:
proto_docs/google/cloud/securitycenter/v2/file.rb

Overview

File information about the related binary/library used by an executable, or the script used by a script interpreter

Defined Under Namespace

Classes: DiskPath, FileOperation

Instance Attribute Summary collapse

Instance Attribute Details

#contents::String

Returns Prefix of the file contents as a JSON-encoded string.

Returns:

  • (::String)

    Prefix of the file contents as a JSON-encoded string.



54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# File 'proto_docs/google/cloud/securitycenter/v2/file.rb', line 54

class File
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Path of the file in terms of underlying disk/partition identifiers.
  # @!attribute [rw] partition_uuid
  #   @return [::String]
  #     UUID of the partition (format
  #     https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid)
  # @!attribute [rw] relative_path
  #   @return [::String]
  #     Relative path of the file in the partition as a JSON encoded string.
  #     Example: /home/user1/executable_file.sh
  class DiskPath
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Operation(s) performed on a file.
  # @!attribute [rw] type
  #   @return [::Google::Cloud::SecurityCenter::V2::File::FileOperation::OperationType]
  #     The type of the operation
  class FileOperation
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # The type of the operation
    module OperationType
      # The operation is unspecified.
      OPERATION_TYPE_UNSPECIFIED = 0

      # Represents an open operation.
      OPEN = 1

      # Represents a read operation.
      READ = 2

      # Represents a rename operation.
      RENAME = 3

      # Represents a write operation.
      WRITE = 4

      # Represents an execute operation.
      EXECUTE = 5
    end
  end
end

#disk_path::Google::Cloud::SecurityCenter::V2::File::DiskPath

Returns Path of the file in terms of underlying disk/partition identifiers.

Returns:



54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# File 'proto_docs/google/cloud/securitycenter/v2/file.rb', line 54

class File
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Path of the file in terms of underlying disk/partition identifiers.
  # @!attribute [rw] partition_uuid
  #   @return [::String]
  #     UUID of the partition (format
  #     https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid)
  # @!attribute [rw] relative_path
  #   @return [::String]
  #     Relative path of the file in the partition as a JSON encoded string.
  #     Example: /home/user1/executable_file.sh
  class DiskPath
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Operation(s) performed on a file.
  # @!attribute [rw] type
  #   @return [::Google::Cloud::SecurityCenter::V2::File::FileOperation::OperationType]
  #     The type of the operation
  class FileOperation
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # The type of the operation
    module OperationType
      # The operation is unspecified.
      OPERATION_TYPE_UNSPECIFIED = 0

      # Represents an open operation.
      OPEN = 1

      # Represents a read operation.
      READ = 2

      # Represents a rename operation.
      RENAME = 3

      # Represents a write operation.
      WRITE = 4

      # Represents an execute operation.
      EXECUTE = 5
    end
  end
end

#hashed_size::Integer

Returns The length in bytes of the file prefix that was hashed. If hashed_size == size, any hashes reported represent the entire file.

Returns:

  • (::Integer)

    The length in bytes of the file prefix that was hashed. If hashed_size == size, any hashes reported represent the entire file.



54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# File 'proto_docs/google/cloud/securitycenter/v2/file.rb', line 54

class File
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Path of the file in terms of underlying disk/partition identifiers.
  # @!attribute [rw] partition_uuid
  #   @return [::String]
  #     UUID of the partition (format
  #     https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid)
  # @!attribute [rw] relative_path
  #   @return [::String]
  #     Relative path of the file in the partition as a JSON encoded string.
  #     Example: /home/user1/executable_file.sh
  class DiskPath
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Operation(s) performed on a file.
  # @!attribute [rw] type
  #   @return [::Google::Cloud::SecurityCenter::V2::File::FileOperation::OperationType]
  #     The type of the operation
  class FileOperation
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # The type of the operation
    module OperationType
      # The operation is unspecified.
      OPERATION_TYPE_UNSPECIFIED = 0

      # Represents an open operation.
      OPEN = 1

      # Represents a read operation.
      READ = 2

      # Represents a rename operation.
      RENAME = 3

      # Represents a write operation.
      WRITE = 4

      # Represents an execute operation.
      EXECUTE = 5
    end
  end
end

#operations::Array<::Google::Cloud::SecurityCenter::V2::File::FileOperation>

Returns Operation(s) performed on a file.

Returns:



54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# File 'proto_docs/google/cloud/securitycenter/v2/file.rb', line 54

class File
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Path of the file in terms of underlying disk/partition identifiers.
  # @!attribute [rw] partition_uuid
  #   @return [::String]
  #     UUID of the partition (format
  #     https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid)
  # @!attribute [rw] relative_path
  #   @return [::String]
  #     Relative path of the file in the partition as a JSON encoded string.
  #     Example: /home/user1/executable_file.sh
  class DiskPath
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Operation(s) performed on a file.
  # @!attribute [rw] type
  #   @return [::Google::Cloud::SecurityCenter::V2::File::FileOperation::OperationType]
  #     The type of the operation
  class FileOperation
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # The type of the operation
    module OperationType
      # The operation is unspecified.
      OPERATION_TYPE_UNSPECIFIED = 0

      # Represents an open operation.
      OPEN = 1

      # Represents a read operation.
      READ = 2

      # Represents a rename operation.
      RENAME = 3

      # Represents a write operation.
      WRITE = 4

      # Represents an execute operation.
      EXECUTE = 5
    end
  end
end

#partially_hashed::Boolean

Returns True when the hash covers only a prefix of the file.

Returns:

  • (::Boolean)

    True when the hash covers only a prefix of the file.



54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# File 'proto_docs/google/cloud/securitycenter/v2/file.rb', line 54

class File
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Path of the file in terms of underlying disk/partition identifiers.
  # @!attribute [rw] partition_uuid
  #   @return [::String]
  #     UUID of the partition (format
  #     https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid)
  # @!attribute [rw] relative_path
  #   @return [::String]
  #     Relative path of the file in the partition as a JSON encoded string.
  #     Example: /home/user1/executable_file.sh
  class DiskPath
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Operation(s) performed on a file.
  # @!attribute [rw] type
  #   @return [::Google::Cloud::SecurityCenter::V2::File::FileOperation::OperationType]
  #     The type of the operation
  class FileOperation
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # The type of the operation
    module OperationType
      # The operation is unspecified.
      OPERATION_TYPE_UNSPECIFIED = 0

      # Represents an open operation.
      OPEN = 1

      # Represents a read operation.
      READ = 2

      # Represents a rename operation.
      RENAME = 3

      # Represents a write operation.
      WRITE = 4

      # Represents an execute operation.
      EXECUTE = 5
    end
  end
end

#path::String

Returns Absolute path of the file as a JSON encoded string.

Returns:

  • (::String)

    Absolute path of the file as a JSON encoded string.



54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# File 'proto_docs/google/cloud/securitycenter/v2/file.rb', line 54

class File
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Path of the file in terms of underlying disk/partition identifiers.
  # @!attribute [rw] partition_uuid
  #   @return [::String]
  #     UUID of the partition (format
  #     https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid)
  # @!attribute [rw] relative_path
  #   @return [::String]
  #     Relative path of the file in the partition as a JSON encoded string.
  #     Example: /home/user1/executable_file.sh
  class DiskPath
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Operation(s) performed on a file.
  # @!attribute [rw] type
  #   @return [::Google::Cloud::SecurityCenter::V2::File::FileOperation::OperationType]
  #     The type of the operation
  class FileOperation
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # The type of the operation
    module OperationType
      # The operation is unspecified.
      OPERATION_TYPE_UNSPECIFIED = 0

      # Represents an open operation.
      OPEN = 1

      # Represents a read operation.
      READ = 2

      # Represents a rename operation.
      RENAME = 3

      # Represents a write operation.
      WRITE = 4

      # Represents an execute operation.
      EXECUTE = 5
    end
  end
end

#sha256::String

Returns SHA256 hash of the first hashed_size bytes of the file encoded as a hex string. If hashed_size == size, sha256 represents the SHA256 hash of the entire file.

Returns:

  • (::String)

    SHA256 hash of the first hashed_size bytes of the file encoded as a hex string. If hashed_size == size, sha256 represents the SHA256 hash of the entire file.



54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# File 'proto_docs/google/cloud/securitycenter/v2/file.rb', line 54

class File
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Path of the file in terms of underlying disk/partition identifiers.
  # @!attribute [rw] partition_uuid
  #   @return [::String]
  #     UUID of the partition (format
  #     https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid)
  # @!attribute [rw] relative_path
  #   @return [::String]
  #     Relative path of the file in the partition as a JSON encoded string.
  #     Example: /home/user1/executable_file.sh
  class DiskPath
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Operation(s) performed on a file.
  # @!attribute [rw] type
  #   @return [::Google::Cloud::SecurityCenter::V2::File::FileOperation::OperationType]
  #     The type of the operation
  class FileOperation
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # The type of the operation
    module OperationType
      # The operation is unspecified.
      OPERATION_TYPE_UNSPECIFIED = 0

      # Represents an open operation.
      OPEN = 1

      # Represents a read operation.
      READ = 2

      # Represents a rename operation.
      RENAME = 3

      # Represents a write operation.
      WRITE = 4

      # Represents an execute operation.
      EXECUTE = 5
    end
  end
end

#size::Integer

Returns Size of the file in bytes.

Returns:

  • (::Integer)

    Size of the file in bytes.



54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
# File 'proto_docs/google/cloud/securitycenter/v2/file.rb', line 54

class File
  include ::Google::Protobuf::MessageExts
  extend ::Google::Protobuf::MessageExts::ClassMethods

  # Path of the file in terms of underlying disk/partition identifiers.
  # @!attribute [rw] partition_uuid
  #   @return [::String]
  #     UUID of the partition (format
  #     https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid)
  # @!attribute [rw] relative_path
  #   @return [::String]
  #     Relative path of the file in the partition as a JSON encoded string.
  #     Example: /home/user1/executable_file.sh
  class DiskPath
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods
  end

  # Operation(s) performed on a file.
  # @!attribute [rw] type
  #   @return [::Google::Cloud::SecurityCenter::V2::File::FileOperation::OperationType]
  #     The type of the operation
  class FileOperation
    include ::Google::Protobuf::MessageExts
    extend ::Google::Protobuf::MessageExts::ClassMethods

    # The type of the operation
    module OperationType
      # The operation is unspecified.
      OPERATION_TYPE_UNSPECIFIED = 0

      # Represents an open operation.
      OPEN = 1

      # Represents a read operation.
      READ = 2

      # Represents a rename operation.
      RENAME = 3

      # Represents a write operation.
      WRITE = 4

      # Represents an execute operation.
      EXECUTE = 5
    end
  end
end