Matthias Andreas Benkard | 832a54e | 2019-01-29 09:27:38 +0100 | [diff] [blame] | 1 | /* |
| 2 | Copyright The Kubernetes Authors. |
| 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 | // Code generated by protoc-gen-gogo. |
| 18 | // source: k8s.io/kubernetes/vendor/k8s.io/api/authorization/v1/generated.proto |
| 19 | // DO NOT EDIT! |
| 20 | |
| 21 | /* |
| 22 | Package v1 is a generated protocol buffer package. |
| 23 | |
| 24 | It is generated from these files: |
| 25 | k8s.io/kubernetes/vendor/k8s.io/api/authorization/v1/generated.proto |
| 26 | |
| 27 | It has these top-level messages: |
| 28 | ExtraValue |
| 29 | LocalSubjectAccessReview |
| 30 | NonResourceAttributes |
| 31 | NonResourceRule |
| 32 | ResourceAttributes |
| 33 | ResourceRule |
| 34 | SelfSubjectAccessReview |
| 35 | SelfSubjectAccessReviewSpec |
| 36 | SelfSubjectRulesReview |
| 37 | SelfSubjectRulesReviewSpec |
| 38 | SubjectAccessReview |
| 39 | SubjectAccessReviewSpec |
| 40 | SubjectAccessReviewStatus |
| 41 | SubjectRulesReviewStatus |
| 42 | */ |
| 43 | package v1 |
| 44 | |
| 45 | import proto "github.com/gogo/protobuf/proto" |
| 46 | import fmt "fmt" |
| 47 | import math "math" |
| 48 | |
| 49 | import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" |
| 50 | |
| 51 | import strings "strings" |
| 52 | import reflect "reflect" |
| 53 | |
| 54 | import io "io" |
| 55 | |
| 56 | // Reference imports to suppress errors if they are not otherwise used. |
| 57 | var _ = proto.Marshal |
| 58 | var _ = fmt.Errorf |
| 59 | var _ = math.Inf |
| 60 | |
| 61 | // This is a compile-time assertion to ensure that this generated file |
| 62 | // is compatible with the proto package it is being compiled against. |
| 63 | // A compilation error at this line likely means your copy of the |
| 64 | // proto package needs to be updated. |
| 65 | const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package |
| 66 | |
| 67 | func (m *ExtraValue) Reset() { *m = ExtraValue{} } |
| 68 | func (*ExtraValue) ProtoMessage() {} |
| 69 | func (*ExtraValue) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } |
| 70 | |
| 71 | func (m *LocalSubjectAccessReview) Reset() { *m = LocalSubjectAccessReview{} } |
| 72 | func (*LocalSubjectAccessReview) ProtoMessage() {} |
| 73 | func (*LocalSubjectAccessReview) Descriptor() ([]byte, []int) { |
| 74 | return fileDescriptorGenerated, []int{1} |
| 75 | } |
| 76 | |
| 77 | func (m *NonResourceAttributes) Reset() { *m = NonResourceAttributes{} } |
| 78 | func (*NonResourceAttributes) ProtoMessage() {} |
| 79 | func (*NonResourceAttributes) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } |
| 80 | |
| 81 | func (m *NonResourceRule) Reset() { *m = NonResourceRule{} } |
| 82 | func (*NonResourceRule) ProtoMessage() {} |
| 83 | func (*NonResourceRule) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } |
| 84 | |
| 85 | func (m *ResourceAttributes) Reset() { *m = ResourceAttributes{} } |
| 86 | func (*ResourceAttributes) ProtoMessage() {} |
| 87 | func (*ResourceAttributes) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } |
| 88 | |
| 89 | func (m *ResourceRule) Reset() { *m = ResourceRule{} } |
| 90 | func (*ResourceRule) ProtoMessage() {} |
| 91 | func (*ResourceRule) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } |
| 92 | |
| 93 | func (m *SelfSubjectAccessReview) Reset() { *m = SelfSubjectAccessReview{} } |
| 94 | func (*SelfSubjectAccessReview) ProtoMessage() {} |
| 95 | func (*SelfSubjectAccessReview) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } |
| 96 | |
| 97 | func (m *SelfSubjectAccessReviewSpec) Reset() { *m = SelfSubjectAccessReviewSpec{} } |
| 98 | func (*SelfSubjectAccessReviewSpec) ProtoMessage() {} |
| 99 | func (*SelfSubjectAccessReviewSpec) Descriptor() ([]byte, []int) { |
| 100 | return fileDescriptorGenerated, []int{7} |
| 101 | } |
| 102 | |
| 103 | func (m *SelfSubjectRulesReview) Reset() { *m = SelfSubjectRulesReview{} } |
| 104 | func (*SelfSubjectRulesReview) ProtoMessage() {} |
| 105 | func (*SelfSubjectRulesReview) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } |
| 106 | |
| 107 | func (m *SelfSubjectRulesReviewSpec) Reset() { *m = SelfSubjectRulesReviewSpec{} } |
| 108 | func (*SelfSubjectRulesReviewSpec) ProtoMessage() {} |
| 109 | func (*SelfSubjectRulesReviewSpec) Descriptor() ([]byte, []int) { |
| 110 | return fileDescriptorGenerated, []int{9} |
| 111 | } |
| 112 | |
| 113 | func (m *SubjectAccessReview) Reset() { *m = SubjectAccessReview{} } |
| 114 | func (*SubjectAccessReview) ProtoMessage() {} |
| 115 | func (*SubjectAccessReview) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{10} } |
| 116 | |
| 117 | func (m *SubjectAccessReviewSpec) Reset() { *m = SubjectAccessReviewSpec{} } |
| 118 | func (*SubjectAccessReviewSpec) ProtoMessage() {} |
| 119 | func (*SubjectAccessReviewSpec) Descriptor() ([]byte, []int) { |
| 120 | return fileDescriptorGenerated, []int{11} |
| 121 | } |
| 122 | |
| 123 | func (m *SubjectAccessReviewStatus) Reset() { *m = SubjectAccessReviewStatus{} } |
| 124 | func (*SubjectAccessReviewStatus) ProtoMessage() {} |
| 125 | func (*SubjectAccessReviewStatus) Descriptor() ([]byte, []int) { |
| 126 | return fileDescriptorGenerated, []int{12} |
| 127 | } |
| 128 | |
| 129 | func (m *SubjectRulesReviewStatus) Reset() { *m = SubjectRulesReviewStatus{} } |
| 130 | func (*SubjectRulesReviewStatus) ProtoMessage() {} |
| 131 | func (*SubjectRulesReviewStatus) Descriptor() ([]byte, []int) { |
| 132 | return fileDescriptorGenerated, []int{13} |
| 133 | } |
| 134 | |
| 135 | func init() { |
| 136 | proto.RegisterType((*ExtraValue)(nil), "k8s.io.api.authorization.v1.ExtraValue") |
| 137 | proto.RegisterType((*LocalSubjectAccessReview)(nil), "k8s.io.api.authorization.v1.LocalSubjectAccessReview") |
| 138 | proto.RegisterType((*NonResourceAttributes)(nil), "k8s.io.api.authorization.v1.NonResourceAttributes") |
| 139 | proto.RegisterType((*NonResourceRule)(nil), "k8s.io.api.authorization.v1.NonResourceRule") |
| 140 | proto.RegisterType((*ResourceAttributes)(nil), "k8s.io.api.authorization.v1.ResourceAttributes") |
| 141 | proto.RegisterType((*ResourceRule)(nil), "k8s.io.api.authorization.v1.ResourceRule") |
| 142 | proto.RegisterType((*SelfSubjectAccessReview)(nil), "k8s.io.api.authorization.v1.SelfSubjectAccessReview") |
| 143 | proto.RegisterType((*SelfSubjectAccessReviewSpec)(nil), "k8s.io.api.authorization.v1.SelfSubjectAccessReviewSpec") |
| 144 | proto.RegisterType((*SelfSubjectRulesReview)(nil), "k8s.io.api.authorization.v1.SelfSubjectRulesReview") |
| 145 | proto.RegisterType((*SelfSubjectRulesReviewSpec)(nil), "k8s.io.api.authorization.v1.SelfSubjectRulesReviewSpec") |
| 146 | proto.RegisterType((*SubjectAccessReview)(nil), "k8s.io.api.authorization.v1.SubjectAccessReview") |
| 147 | proto.RegisterType((*SubjectAccessReviewSpec)(nil), "k8s.io.api.authorization.v1.SubjectAccessReviewSpec") |
| 148 | proto.RegisterType((*SubjectAccessReviewStatus)(nil), "k8s.io.api.authorization.v1.SubjectAccessReviewStatus") |
| 149 | proto.RegisterType((*SubjectRulesReviewStatus)(nil), "k8s.io.api.authorization.v1.SubjectRulesReviewStatus") |
| 150 | } |
| 151 | func (m ExtraValue) Marshal() (dAtA []byte, err error) { |
| 152 | size := m.Size() |
| 153 | dAtA = make([]byte, size) |
| 154 | n, err := m.MarshalTo(dAtA) |
| 155 | if err != nil { |
| 156 | return nil, err |
| 157 | } |
| 158 | return dAtA[:n], nil |
| 159 | } |
| 160 | |
| 161 | func (m ExtraValue) MarshalTo(dAtA []byte) (int, error) { |
| 162 | var i int |
| 163 | _ = i |
| 164 | var l int |
| 165 | _ = l |
| 166 | if len(m) > 0 { |
| 167 | for _, s := range m { |
| 168 | dAtA[i] = 0xa |
| 169 | i++ |
| 170 | l = len(s) |
| 171 | for l >= 1<<7 { |
| 172 | dAtA[i] = uint8(uint64(l)&0x7f | 0x80) |
| 173 | l >>= 7 |
| 174 | i++ |
| 175 | } |
| 176 | dAtA[i] = uint8(l) |
| 177 | i++ |
| 178 | i += copy(dAtA[i:], s) |
| 179 | } |
| 180 | } |
| 181 | return i, nil |
| 182 | } |
| 183 | |
| 184 | func (m *LocalSubjectAccessReview) Marshal() (dAtA []byte, err error) { |
| 185 | size := m.Size() |
| 186 | dAtA = make([]byte, size) |
| 187 | n, err := m.MarshalTo(dAtA) |
| 188 | if err != nil { |
| 189 | return nil, err |
| 190 | } |
| 191 | return dAtA[:n], nil |
| 192 | } |
| 193 | |
| 194 | func (m *LocalSubjectAccessReview) MarshalTo(dAtA []byte) (int, error) { |
| 195 | var i int |
| 196 | _ = i |
| 197 | var l int |
| 198 | _ = l |
| 199 | dAtA[i] = 0xa |
| 200 | i++ |
| 201 | i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) |
| 202 | n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) |
| 203 | if err != nil { |
| 204 | return 0, err |
| 205 | } |
| 206 | i += n1 |
| 207 | dAtA[i] = 0x12 |
| 208 | i++ |
| 209 | i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) |
| 210 | n2, err := m.Spec.MarshalTo(dAtA[i:]) |
| 211 | if err != nil { |
| 212 | return 0, err |
| 213 | } |
| 214 | i += n2 |
| 215 | dAtA[i] = 0x1a |
| 216 | i++ |
| 217 | i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) |
| 218 | n3, err := m.Status.MarshalTo(dAtA[i:]) |
| 219 | if err != nil { |
| 220 | return 0, err |
| 221 | } |
| 222 | i += n3 |
| 223 | return i, nil |
| 224 | } |
| 225 | |
| 226 | func (m *NonResourceAttributes) Marshal() (dAtA []byte, err error) { |
| 227 | size := m.Size() |
| 228 | dAtA = make([]byte, size) |
| 229 | n, err := m.MarshalTo(dAtA) |
| 230 | if err != nil { |
| 231 | return nil, err |
| 232 | } |
| 233 | return dAtA[:n], nil |
| 234 | } |
| 235 | |
| 236 | func (m *NonResourceAttributes) MarshalTo(dAtA []byte) (int, error) { |
| 237 | var i int |
| 238 | _ = i |
| 239 | var l int |
| 240 | _ = l |
| 241 | dAtA[i] = 0xa |
| 242 | i++ |
| 243 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) |
| 244 | i += copy(dAtA[i:], m.Path) |
| 245 | dAtA[i] = 0x12 |
| 246 | i++ |
| 247 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.Verb))) |
| 248 | i += copy(dAtA[i:], m.Verb) |
| 249 | return i, nil |
| 250 | } |
| 251 | |
| 252 | func (m *NonResourceRule) Marshal() (dAtA []byte, err error) { |
| 253 | size := m.Size() |
| 254 | dAtA = make([]byte, size) |
| 255 | n, err := m.MarshalTo(dAtA) |
| 256 | if err != nil { |
| 257 | return nil, err |
| 258 | } |
| 259 | return dAtA[:n], nil |
| 260 | } |
| 261 | |
| 262 | func (m *NonResourceRule) MarshalTo(dAtA []byte) (int, error) { |
| 263 | var i int |
| 264 | _ = i |
| 265 | var l int |
| 266 | _ = l |
| 267 | if len(m.Verbs) > 0 { |
| 268 | for _, s := range m.Verbs { |
| 269 | dAtA[i] = 0xa |
| 270 | i++ |
| 271 | l = len(s) |
| 272 | for l >= 1<<7 { |
| 273 | dAtA[i] = uint8(uint64(l)&0x7f | 0x80) |
| 274 | l >>= 7 |
| 275 | i++ |
| 276 | } |
| 277 | dAtA[i] = uint8(l) |
| 278 | i++ |
| 279 | i += copy(dAtA[i:], s) |
| 280 | } |
| 281 | } |
| 282 | if len(m.NonResourceURLs) > 0 { |
| 283 | for _, s := range m.NonResourceURLs { |
| 284 | dAtA[i] = 0x12 |
| 285 | i++ |
| 286 | l = len(s) |
| 287 | for l >= 1<<7 { |
| 288 | dAtA[i] = uint8(uint64(l)&0x7f | 0x80) |
| 289 | l >>= 7 |
| 290 | i++ |
| 291 | } |
| 292 | dAtA[i] = uint8(l) |
| 293 | i++ |
| 294 | i += copy(dAtA[i:], s) |
| 295 | } |
| 296 | } |
| 297 | return i, nil |
| 298 | } |
| 299 | |
| 300 | func (m *ResourceAttributes) Marshal() (dAtA []byte, err error) { |
| 301 | size := m.Size() |
| 302 | dAtA = make([]byte, size) |
| 303 | n, err := m.MarshalTo(dAtA) |
| 304 | if err != nil { |
| 305 | return nil, err |
| 306 | } |
| 307 | return dAtA[:n], nil |
| 308 | } |
| 309 | |
| 310 | func (m *ResourceAttributes) MarshalTo(dAtA []byte) (int, error) { |
| 311 | var i int |
| 312 | _ = i |
| 313 | var l int |
| 314 | _ = l |
| 315 | dAtA[i] = 0xa |
| 316 | i++ |
| 317 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.Namespace))) |
| 318 | i += copy(dAtA[i:], m.Namespace) |
| 319 | dAtA[i] = 0x12 |
| 320 | i++ |
| 321 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.Verb))) |
| 322 | i += copy(dAtA[i:], m.Verb) |
| 323 | dAtA[i] = 0x1a |
| 324 | i++ |
| 325 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.Group))) |
| 326 | i += copy(dAtA[i:], m.Group) |
| 327 | dAtA[i] = 0x22 |
| 328 | i++ |
| 329 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.Version))) |
| 330 | i += copy(dAtA[i:], m.Version) |
| 331 | dAtA[i] = 0x2a |
| 332 | i++ |
| 333 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.Resource))) |
| 334 | i += copy(dAtA[i:], m.Resource) |
| 335 | dAtA[i] = 0x32 |
| 336 | i++ |
| 337 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.Subresource))) |
| 338 | i += copy(dAtA[i:], m.Subresource) |
| 339 | dAtA[i] = 0x3a |
| 340 | i++ |
| 341 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) |
| 342 | i += copy(dAtA[i:], m.Name) |
| 343 | return i, nil |
| 344 | } |
| 345 | |
| 346 | func (m *ResourceRule) Marshal() (dAtA []byte, err error) { |
| 347 | size := m.Size() |
| 348 | dAtA = make([]byte, size) |
| 349 | n, err := m.MarshalTo(dAtA) |
| 350 | if err != nil { |
| 351 | return nil, err |
| 352 | } |
| 353 | return dAtA[:n], nil |
| 354 | } |
| 355 | |
| 356 | func (m *ResourceRule) MarshalTo(dAtA []byte) (int, error) { |
| 357 | var i int |
| 358 | _ = i |
| 359 | var l int |
| 360 | _ = l |
| 361 | if len(m.Verbs) > 0 { |
| 362 | for _, s := range m.Verbs { |
| 363 | dAtA[i] = 0xa |
| 364 | i++ |
| 365 | l = len(s) |
| 366 | for l >= 1<<7 { |
| 367 | dAtA[i] = uint8(uint64(l)&0x7f | 0x80) |
| 368 | l >>= 7 |
| 369 | i++ |
| 370 | } |
| 371 | dAtA[i] = uint8(l) |
| 372 | i++ |
| 373 | i += copy(dAtA[i:], s) |
| 374 | } |
| 375 | } |
| 376 | if len(m.APIGroups) > 0 { |
| 377 | for _, s := range m.APIGroups { |
| 378 | dAtA[i] = 0x12 |
| 379 | i++ |
| 380 | l = len(s) |
| 381 | for l >= 1<<7 { |
| 382 | dAtA[i] = uint8(uint64(l)&0x7f | 0x80) |
| 383 | l >>= 7 |
| 384 | i++ |
| 385 | } |
| 386 | dAtA[i] = uint8(l) |
| 387 | i++ |
| 388 | i += copy(dAtA[i:], s) |
| 389 | } |
| 390 | } |
| 391 | if len(m.Resources) > 0 { |
| 392 | for _, s := range m.Resources { |
| 393 | dAtA[i] = 0x1a |
| 394 | i++ |
| 395 | l = len(s) |
| 396 | for l >= 1<<7 { |
| 397 | dAtA[i] = uint8(uint64(l)&0x7f | 0x80) |
| 398 | l >>= 7 |
| 399 | i++ |
| 400 | } |
| 401 | dAtA[i] = uint8(l) |
| 402 | i++ |
| 403 | i += copy(dAtA[i:], s) |
| 404 | } |
| 405 | } |
| 406 | if len(m.ResourceNames) > 0 { |
| 407 | for _, s := range m.ResourceNames { |
| 408 | dAtA[i] = 0x22 |
| 409 | i++ |
| 410 | l = len(s) |
| 411 | for l >= 1<<7 { |
| 412 | dAtA[i] = uint8(uint64(l)&0x7f | 0x80) |
| 413 | l >>= 7 |
| 414 | i++ |
| 415 | } |
| 416 | dAtA[i] = uint8(l) |
| 417 | i++ |
| 418 | i += copy(dAtA[i:], s) |
| 419 | } |
| 420 | } |
| 421 | return i, nil |
| 422 | } |
| 423 | |
| 424 | func (m *SelfSubjectAccessReview) Marshal() (dAtA []byte, err error) { |
| 425 | size := m.Size() |
| 426 | dAtA = make([]byte, size) |
| 427 | n, err := m.MarshalTo(dAtA) |
| 428 | if err != nil { |
| 429 | return nil, err |
| 430 | } |
| 431 | return dAtA[:n], nil |
| 432 | } |
| 433 | |
| 434 | func (m *SelfSubjectAccessReview) MarshalTo(dAtA []byte) (int, error) { |
| 435 | var i int |
| 436 | _ = i |
| 437 | var l int |
| 438 | _ = l |
| 439 | dAtA[i] = 0xa |
| 440 | i++ |
| 441 | i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) |
| 442 | n4, err := m.ObjectMeta.MarshalTo(dAtA[i:]) |
| 443 | if err != nil { |
| 444 | return 0, err |
| 445 | } |
| 446 | i += n4 |
| 447 | dAtA[i] = 0x12 |
| 448 | i++ |
| 449 | i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) |
| 450 | n5, err := m.Spec.MarshalTo(dAtA[i:]) |
| 451 | if err != nil { |
| 452 | return 0, err |
| 453 | } |
| 454 | i += n5 |
| 455 | dAtA[i] = 0x1a |
| 456 | i++ |
| 457 | i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) |
| 458 | n6, err := m.Status.MarshalTo(dAtA[i:]) |
| 459 | if err != nil { |
| 460 | return 0, err |
| 461 | } |
| 462 | i += n6 |
| 463 | return i, nil |
| 464 | } |
| 465 | |
| 466 | func (m *SelfSubjectAccessReviewSpec) Marshal() (dAtA []byte, err error) { |
| 467 | size := m.Size() |
| 468 | dAtA = make([]byte, size) |
| 469 | n, err := m.MarshalTo(dAtA) |
| 470 | if err != nil { |
| 471 | return nil, err |
| 472 | } |
| 473 | return dAtA[:n], nil |
| 474 | } |
| 475 | |
| 476 | func (m *SelfSubjectAccessReviewSpec) MarshalTo(dAtA []byte) (int, error) { |
| 477 | var i int |
| 478 | _ = i |
| 479 | var l int |
| 480 | _ = l |
| 481 | if m.ResourceAttributes != nil { |
| 482 | dAtA[i] = 0xa |
| 483 | i++ |
| 484 | i = encodeVarintGenerated(dAtA, i, uint64(m.ResourceAttributes.Size())) |
| 485 | n7, err := m.ResourceAttributes.MarshalTo(dAtA[i:]) |
| 486 | if err != nil { |
| 487 | return 0, err |
| 488 | } |
| 489 | i += n7 |
| 490 | } |
| 491 | if m.NonResourceAttributes != nil { |
| 492 | dAtA[i] = 0x12 |
| 493 | i++ |
| 494 | i = encodeVarintGenerated(dAtA, i, uint64(m.NonResourceAttributes.Size())) |
| 495 | n8, err := m.NonResourceAttributes.MarshalTo(dAtA[i:]) |
| 496 | if err != nil { |
| 497 | return 0, err |
| 498 | } |
| 499 | i += n8 |
| 500 | } |
| 501 | return i, nil |
| 502 | } |
| 503 | |
| 504 | func (m *SelfSubjectRulesReview) Marshal() (dAtA []byte, err error) { |
| 505 | size := m.Size() |
| 506 | dAtA = make([]byte, size) |
| 507 | n, err := m.MarshalTo(dAtA) |
| 508 | if err != nil { |
| 509 | return nil, err |
| 510 | } |
| 511 | return dAtA[:n], nil |
| 512 | } |
| 513 | |
| 514 | func (m *SelfSubjectRulesReview) MarshalTo(dAtA []byte) (int, error) { |
| 515 | var i int |
| 516 | _ = i |
| 517 | var l int |
| 518 | _ = l |
| 519 | dAtA[i] = 0xa |
| 520 | i++ |
| 521 | i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) |
| 522 | n9, err := m.ObjectMeta.MarshalTo(dAtA[i:]) |
| 523 | if err != nil { |
| 524 | return 0, err |
| 525 | } |
| 526 | i += n9 |
| 527 | dAtA[i] = 0x12 |
| 528 | i++ |
| 529 | i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) |
| 530 | n10, err := m.Spec.MarshalTo(dAtA[i:]) |
| 531 | if err != nil { |
| 532 | return 0, err |
| 533 | } |
| 534 | i += n10 |
| 535 | dAtA[i] = 0x1a |
| 536 | i++ |
| 537 | i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) |
| 538 | n11, err := m.Status.MarshalTo(dAtA[i:]) |
| 539 | if err != nil { |
| 540 | return 0, err |
| 541 | } |
| 542 | i += n11 |
| 543 | return i, nil |
| 544 | } |
| 545 | |
| 546 | func (m *SelfSubjectRulesReviewSpec) Marshal() (dAtA []byte, err error) { |
| 547 | size := m.Size() |
| 548 | dAtA = make([]byte, size) |
| 549 | n, err := m.MarshalTo(dAtA) |
| 550 | if err != nil { |
| 551 | return nil, err |
| 552 | } |
| 553 | return dAtA[:n], nil |
| 554 | } |
| 555 | |
| 556 | func (m *SelfSubjectRulesReviewSpec) MarshalTo(dAtA []byte) (int, error) { |
| 557 | var i int |
| 558 | _ = i |
| 559 | var l int |
| 560 | _ = l |
| 561 | dAtA[i] = 0xa |
| 562 | i++ |
| 563 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.Namespace))) |
| 564 | i += copy(dAtA[i:], m.Namespace) |
| 565 | return i, nil |
| 566 | } |
| 567 | |
| 568 | func (m *SubjectAccessReview) Marshal() (dAtA []byte, err error) { |
| 569 | size := m.Size() |
| 570 | dAtA = make([]byte, size) |
| 571 | n, err := m.MarshalTo(dAtA) |
| 572 | if err != nil { |
| 573 | return nil, err |
| 574 | } |
| 575 | return dAtA[:n], nil |
| 576 | } |
| 577 | |
| 578 | func (m *SubjectAccessReview) MarshalTo(dAtA []byte) (int, error) { |
| 579 | var i int |
| 580 | _ = i |
| 581 | var l int |
| 582 | _ = l |
| 583 | dAtA[i] = 0xa |
| 584 | i++ |
| 585 | i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) |
| 586 | n12, err := m.ObjectMeta.MarshalTo(dAtA[i:]) |
| 587 | if err != nil { |
| 588 | return 0, err |
| 589 | } |
| 590 | i += n12 |
| 591 | dAtA[i] = 0x12 |
| 592 | i++ |
| 593 | i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) |
| 594 | n13, err := m.Spec.MarshalTo(dAtA[i:]) |
| 595 | if err != nil { |
| 596 | return 0, err |
| 597 | } |
| 598 | i += n13 |
| 599 | dAtA[i] = 0x1a |
| 600 | i++ |
| 601 | i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) |
| 602 | n14, err := m.Status.MarshalTo(dAtA[i:]) |
| 603 | if err != nil { |
| 604 | return 0, err |
| 605 | } |
| 606 | i += n14 |
| 607 | return i, nil |
| 608 | } |
| 609 | |
| 610 | func (m *SubjectAccessReviewSpec) Marshal() (dAtA []byte, err error) { |
| 611 | size := m.Size() |
| 612 | dAtA = make([]byte, size) |
| 613 | n, err := m.MarshalTo(dAtA) |
| 614 | if err != nil { |
| 615 | return nil, err |
| 616 | } |
| 617 | return dAtA[:n], nil |
| 618 | } |
| 619 | |
| 620 | func (m *SubjectAccessReviewSpec) MarshalTo(dAtA []byte) (int, error) { |
| 621 | var i int |
| 622 | _ = i |
| 623 | var l int |
| 624 | _ = l |
| 625 | if m.ResourceAttributes != nil { |
| 626 | dAtA[i] = 0xa |
| 627 | i++ |
| 628 | i = encodeVarintGenerated(dAtA, i, uint64(m.ResourceAttributes.Size())) |
| 629 | n15, err := m.ResourceAttributes.MarshalTo(dAtA[i:]) |
| 630 | if err != nil { |
| 631 | return 0, err |
| 632 | } |
| 633 | i += n15 |
| 634 | } |
| 635 | if m.NonResourceAttributes != nil { |
| 636 | dAtA[i] = 0x12 |
| 637 | i++ |
| 638 | i = encodeVarintGenerated(dAtA, i, uint64(m.NonResourceAttributes.Size())) |
| 639 | n16, err := m.NonResourceAttributes.MarshalTo(dAtA[i:]) |
| 640 | if err != nil { |
| 641 | return 0, err |
| 642 | } |
| 643 | i += n16 |
| 644 | } |
| 645 | dAtA[i] = 0x1a |
| 646 | i++ |
| 647 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.User))) |
| 648 | i += copy(dAtA[i:], m.User) |
| 649 | if len(m.Groups) > 0 { |
| 650 | for _, s := range m.Groups { |
| 651 | dAtA[i] = 0x22 |
| 652 | i++ |
| 653 | l = len(s) |
| 654 | for l >= 1<<7 { |
| 655 | dAtA[i] = uint8(uint64(l)&0x7f | 0x80) |
| 656 | l >>= 7 |
| 657 | i++ |
| 658 | } |
| 659 | dAtA[i] = uint8(l) |
| 660 | i++ |
| 661 | i += copy(dAtA[i:], s) |
| 662 | } |
| 663 | } |
| 664 | if len(m.Extra) > 0 { |
| 665 | keysForExtra := make([]string, 0, len(m.Extra)) |
| 666 | for k := range m.Extra { |
| 667 | keysForExtra = append(keysForExtra, string(k)) |
| 668 | } |
| 669 | github_com_gogo_protobuf_sortkeys.Strings(keysForExtra) |
| 670 | for _, k := range keysForExtra { |
| 671 | dAtA[i] = 0x2a |
| 672 | i++ |
| 673 | v := m.Extra[string(k)] |
| 674 | msgSize := 0 |
| 675 | if (&v) != nil { |
| 676 | msgSize = (&v).Size() |
| 677 | msgSize += 1 + sovGenerated(uint64(msgSize)) |
| 678 | } |
| 679 | mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize |
| 680 | i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) |
| 681 | dAtA[i] = 0xa |
| 682 | i++ |
| 683 | i = encodeVarintGenerated(dAtA, i, uint64(len(k))) |
| 684 | i += copy(dAtA[i:], k) |
| 685 | dAtA[i] = 0x12 |
| 686 | i++ |
| 687 | i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) |
| 688 | n17, err := (&v).MarshalTo(dAtA[i:]) |
| 689 | if err != nil { |
| 690 | return 0, err |
| 691 | } |
| 692 | i += n17 |
| 693 | } |
| 694 | } |
| 695 | dAtA[i] = 0x32 |
| 696 | i++ |
| 697 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.UID))) |
| 698 | i += copy(dAtA[i:], m.UID) |
| 699 | return i, nil |
| 700 | } |
| 701 | |
| 702 | func (m *SubjectAccessReviewStatus) Marshal() (dAtA []byte, err error) { |
| 703 | size := m.Size() |
| 704 | dAtA = make([]byte, size) |
| 705 | n, err := m.MarshalTo(dAtA) |
| 706 | if err != nil { |
| 707 | return nil, err |
| 708 | } |
| 709 | return dAtA[:n], nil |
| 710 | } |
| 711 | |
| 712 | func (m *SubjectAccessReviewStatus) MarshalTo(dAtA []byte) (int, error) { |
| 713 | var i int |
| 714 | _ = i |
| 715 | var l int |
| 716 | _ = l |
| 717 | dAtA[i] = 0x8 |
| 718 | i++ |
| 719 | if m.Allowed { |
| 720 | dAtA[i] = 1 |
| 721 | } else { |
| 722 | dAtA[i] = 0 |
| 723 | } |
| 724 | i++ |
| 725 | dAtA[i] = 0x12 |
| 726 | i++ |
| 727 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) |
| 728 | i += copy(dAtA[i:], m.Reason) |
| 729 | dAtA[i] = 0x1a |
| 730 | i++ |
| 731 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.EvaluationError))) |
| 732 | i += copy(dAtA[i:], m.EvaluationError) |
| 733 | dAtA[i] = 0x20 |
| 734 | i++ |
| 735 | if m.Denied { |
| 736 | dAtA[i] = 1 |
| 737 | } else { |
| 738 | dAtA[i] = 0 |
| 739 | } |
| 740 | i++ |
| 741 | return i, nil |
| 742 | } |
| 743 | |
| 744 | func (m *SubjectRulesReviewStatus) Marshal() (dAtA []byte, err error) { |
| 745 | size := m.Size() |
| 746 | dAtA = make([]byte, size) |
| 747 | n, err := m.MarshalTo(dAtA) |
| 748 | if err != nil { |
| 749 | return nil, err |
| 750 | } |
| 751 | return dAtA[:n], nil |
| 752 | } |
| 753 | |
| 754 | func (m *SubjectRulesReviewStatus) MarshalTo(dAtA []byte) (int, error) { |
| 755 | var i int |
| 756 | _ = i |
| 757 | var l int |
| 758 | _ = l |
| 759 | if len(m.ResourceRules) > 0 { |
| 760 | for _, msg := range m.ResourceRules { |
| 761 | dAtA[i] = 0xa |
| 762 | i++ |
| 763 | i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) |
| 764 | n, err := msg.MarshalTo(dAtA[i:]) |
| 765 | if err != nil { |
| 766 | return 0, err |
| 767 | } |
| 768 | i += n |
| 769 | } |
| 770 | } |
| 771 | if len(m.NonResourceRules) > 0 { |
| 772 | for _, msg := range m.NonResourceRules { |
| 773 | dAtA[i] = 0x12 |
| 774 | i++ |
| 775 | i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) |
| 776 | n, err := msg.MarshalTo(dAtA[i:]) |
| 777 | if err != nil { |
| 778 | return 0, err |
| 779 | } |
| 780 | i += n |
| 781 | } |
| 782 | } |
| 783 | dAtA[i] = 0x18 |
| 784 | i++ |
| 785 | if m.Incomplete { |
| 786 | dAtA[i] = 1 |
| 787 | } else { |
| 788 | dAtA[i] = 0 |
| 789 | } |
| 790 | i++ |
| 791 | dAtA[i] = 0x22 |
| 792 | i++ |
| 793 | i = encodeVarintGenerated(dAtA, i, uint64(len(m.EvaluationError))) |
| 794 | i += copy(dAtA[i:], m.EvaluationError) |
| 795 | return i, nil |
| 796 | } |
| 797 | |
| 798 | func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { |
| 799 | dAtA[offset] = uint8(v) |
| 800 | dAtA[offset+1] = uint8(v >> 8) |
| 801 | dAtA[offset+2] = uint8(v >> 16) |
| 802 | dAtA[offset+3] = uint8(v >> 24) |
| 803 | dAtA[offset+4] = uint8(v >> 32) |
| 804 | dAtA[offset+5] = uint8(v >> 40) |
| 805 | dAtA[offset+6] = uint8(v >> 48) |
| 806 | dAtA[offset+7] = uint8(v >> 56) |
| 807 | return offset + 8 |
| 808 | } |
| 809 | func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { |
| 810 | dAtA[offset] = uint8(v) |
| 811 | dAtA[offset+1] = uint8(v >> 8) |
| 812 | dAtA[offset+2] = uint8(v >> 16) |
| 813 | dAtA[offset+3] = uint8(v >> 24) |
| 814 | return offset + 4 |
| 815 | } |
| 816 | func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { |
| 817 | for v >= 1<<7 { |
| 818 | dAtA[offset] = uint8(v&0x7f | 0x80) |
| 819 | v >>= 7 |
| 820 | offset++ |
| 821 | } |
| 822 | dAtA[offset] = uint8(v) |
| 823 | return offset + 1 |
| 824 | } |
| 825 | func (m ExtraValue) Size() (n int) { |
| 826 | var l int |
| 827 | _ = l |
| 828 | if len(m) > 0 { |
| 829 | for _, s := range m { |
| 830 | l = len(s) |
| 831 | n += 1 + l + sovGenerated(uint64(l)) |
| 832 | } |
| 833 | } |
| 834 | return n |
| 835 | } |
| 836 | |
| 837 | func (m *LocalSubjectAccessReview) Size() (n int) { |
| 838 | var l int |
| 839 | _ = l |
| 840 | l = m.ObjectMeta.Size() |
| 841 | n += 1 + l + sovGenerated(uint64(l)) |
| 842 | l = m.Spec.Size() |
| 843 | n += 1 + l + sovGenerated(uint64(l)) |
| 844 | l = m.Status.Size() |
| 845 | n += 1 + l + sovGenerated(uint64(l)) |
| 846 | return n |
| 847 | } |
| 848 | |
| 849 | func (m *NonResourceAttributes) Size() (n int) { |
| 850 | var l int |
| 851 | _ = l |
| 852 | l = len(m.Path) |
| 853 | n += 1 + l + sovGenerated(uint64(l)) |
| 854 | l = len(m.Verb) |
| 855 | n += 1 + l + sovGenerated(uint64(l)) |
| 856 | return n |
| 857 | } |
| 858 | |
| 859 | func (m *NonResourceRule) Size() (n int) { |
| 860 | var l int |
| 861 | _ = l |
| 862 | if len(m.Verbs) > 0 { |
| 863 | for _, s := range m.Verbs { |
| 864 | l = len(s) |
| 865 | n += 1 + l + sovGenerated(uint64(l)) |
| 866 | } |
| 867 | } |
| 868 | if len(m.NonResourceURLs) > 0 { |
| 869 | for _, s := range m.NonResourceURLs { |
| 870 | l = len(s) |
| 871 | n += 1 + l + sovGenerated(uint64(l)) |
| 872 | } |
| 873 | } |
| 874 | return n |
| 875 | } |
| 876 | |
| 877 | func (m *ResourceAttributes) Size() (n int) { |
| 878 | var l int |
| 879 | _ = l |
| 880 | l = len(m.Namespace) |
| 881 | n += 1 + l + sovGenerated(uint64(l)) |
| 882 | l = len(m.Verb) |
| 883 | n += 1 + l + sovGenerated(uint64(l)) |
| 884 | l = len(m.Group) |
| 885 | n += 1 + l + sovGenerated(uint64(l)) |
| 886 | l = len(m.Version) |
| 887 | n += 1 + l + sovGenerated(uint64(l)) |
| 888 | l = len(m.Resource) |
| 889 | n += 1 + l + sovGenerated(uint64(l)) |
| 890 | l = len(m.Subresource) |
| 891 | n += 1 + l + sovGenerated(uint64(l)) |
| 892 | l = len(m.Name) |
| 893 | n += 1 + l + sovGenerated(uint64(l)) |
| 894 | return n |
| 895 | } |
| 896 | |
| 897 | func (m *ResourceRule) Size() (n int) { |
| 898 | var l int |
| 899 | _ = l |
| 900 | if len(m.Verbs) > 0 { |
| 901 | for _, s := range m.Verbs { |
| 902 | l = len(s) |
| 903 | n += 1 + l + sovGenerated(uint64(l)) |
| 904 | } |
| 905 | } |
| 906 | if len(m.APIGroups) > 0 { |
| 907 | for _, s := range m.APIGroups { |
| 908 | l = len(s) |
| 909 | n += 1 + l + sovGenerated(uint64(l)) |
| 910 | } |
| 911 | } |
| 912 | if len(m.Resources) > 0 { |
| 913 | for _, s := range m.Resources { |
| 914 | l = len(s) |
| 915 | n += 1 + l + sovGenerated(uint64(l)) |
| 916 | } |
| 917 | } |
| 918 | if len(m.ResourceNames) > 0 { |
| 919 | for _, s := range m.ResourceNames { |
| 920 | l = len(s) |
| 921 | n += 1 + l + sovGenerated(uint64(l)) |
| 922 | } |
| 923 | } |
| 924 | return n |
| 925 | } |
| 926 | |
| 927 | func (m *SelfSubjectAccessReview) Size() (n int) { |
| 928 | var l int |
| 929 | _ = l |
| 930 | l = m.ObjectMeta.Size() |
| 931 | n += 1 + l + sovGenerated(uint64(l)) |
| 932 | l = m.Spec.Size() |
| 933 | n += 1 + l + sovGenerated(uint64(l)) |
| 934 | l = m.Status.Size() |
| 935 | n += 1 + l + sovGenerated(uint64(l)) |
| 936 | return n |
| 937 | } |
| 938 | |
| 939 | func (m *SelfSubjectAccessReviewSpec) Size() (n int) { |
| 940 | var l int |
| 941 | _ = l |
| 942 | if m.ResourceAttributes != nil { |
| 943 | l = m.ResourceAttributes.Size() |
| 944 | n += 1 + l + sovGenerated(uint64(l)) |
| 945 | } |
| 946 | if m.NonResourceAttributes != nil { |
| 947 | l = m.NonResourceAttributes.Size() |
| 948 | n += 1 + l + sovGenerated(uint64(l)) |
| 949 | } |
| 950 | return n |
| 951 | } |
| 952 | |
| 953 | func (m *SelfSubjectRulesReview) Size() (n int) { |
| 954 | var l int |
| 955 | _ = l |
| 956 | l = m.ObjectMeta.Size() |
| 957 | n += 1 + l + sovGenerated(uint64(l)) |
| 958 | l = m.Spec.Size() |
| 959 | n += 1 + l + sovGenerated(uint64(l)) |
| 960 | l = m.Status.Size() |
| 961 | n += 1 + l + sovGenerated(uint64(l)) |
| 962 | return n |
| 963 | } |
| 964 | |
| 965 | func (m *SelfSubjectRulesReviewSpec) Size() (n int) { |
| 966 | var l int |
| 967 | _ = l |
| 968 | l = len(m.Namespace) |
| 969 | n += 1 + l + sovGenerated(uint64(l)) |
| 970 | return n |
| 971 | } |
| 972 | |
| 973 | func (m *SubjectAccessReview) Size() (n int) { |
| 974 | var l int |
| 975 | _ = l |
| 976 | l = m.ObjectMeta.Size() |
| 977 | n += 1 + l + sovGenerated(uint64(l)) |
| 978 | l = m.Spec.Size() |
| 979 | n += 1 + l + sovGenerated(uint64(l)) |
| 980 | l = m.Status.Size() |
| 981 | n += 1 + l + sovGenerated(uint64(l)) |
| 982 | return n |
| 983 | } |
| 984 | |
| 985 | func (m *SubjectAccessReviewSpec) Size() (n int) { |
| 986 | var l int |
| 987 | _ = l |
| 988 | if m.ResourceAttributes != nil { |
| 989 | l = m.ResourceAttributes.Size() |
| 990 | n += 1 + l + sovGenerated(uint64(l)) |
| 991 | } |
| 992 | if m.NonResourceAttributes != nil { |
| 993 | l = m.NonResourceAttributes.Size() |
| 994 | n += 1 + l + sovGenerated(uint64(l)) |
| 995 | } |
| 996 | l = len(m.User) |
| 997 | n += 1 + l + sovGenerated(uint64(l)) |
| 998 | if len(m.Groups) > 0 { |
| 999 | for _, s := range m.Groups { |
| 1000 | l = len(s) |
| 1001 | n += 1 + l + sovGenerated(uint64(l)) |
| 1002 | } |
| 1003 | } |
| 1004 | if len(m.Extra) > 0 { |
| 1005 | for k, v := range m.Extra { |
| 1006 | _ = k |
| 1007 | _ = v |
| 1008 | l = v.Size() |
| 1009 | mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l)) |
| 1010 | n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) |
| 1011 | } |
| 1012 | } |
| 1013 | l = len(m.UID) |
| 1014 | n += 1 + l + sovGenerated(uint64(l)) |
| 1015 | return n |
| 1016 | } |
| 1017 | |
| 1018 | func (m *SubjectAccessReviewStatus) Size() (n int) { |
| 1019 | var l int |
| 1020 | _ = l |
| 1021 | n += 2 |
| 1022 | l = len(m.Reason) |
| 1023 | n += 1 + l + sovGenerated(uint64(l)) |
| 1024 | l = len(m.EvaluationError) |
| 1025 | n += 1 + l + sovGenerated(uint64(l)) |
| 1026 | n += 2 |
| 1027 | return n |
| 1028 | } |
| 1029 | |
| 1030 | func (m *SubjectRulesReviewStatus) Size() (n int) { |
| 1031 | var l int |
| 1032 | _ = l |
| 1033 | if len(m.ResourceRules) > 0 { |
| 1034 | for _, e := range m.ResourceRules { |
| 1035 | l = e.Size() |
| 1036 | n += 1 + l + sovGenerated(uint64(l)) |
| 1037 | } |
| 1038 | } |
| 1039 | if len(m.NonResourceRules) > 0 { |
| 1040 | for _, e := range m.NonResourceRules { |
| 1041 | l = e.Size() |
| 1042 | n += 1 + l + sovGenerated(uint64(l)) |
| 1043 | } |
| 1044 | } |
| 1045 | n += 2 |
| 1046 | l = len(m.EvaluationError) |
| 1047 | n += 1 + l + sovGenerated(uint64(l)) |
| 1048 | return n |
| 1049 | } |
| 1050 | |
| 1051 | func sovGenerated(x uint64) (n int) { |
| 1052 | for { |
| 1053 | n++ |
| 1054 | x >>= 7 |
| 1055 | if x == 0 { |
| 1056 | break |
| 1057 | } |
| 1058 | } |
| 1059 | return n |
| 1060 | } |
| 1061 | func sozGenerated(x uint64) (n int) { |
| 1062 | return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) |
| 1063 | } |
| 1064 | func (this *LocalSubjectAccessReview) String() string { |
| 1065 | if this == nil { |
| 1066 | return "nil" |
| 1067 | } |
| 1068 | s := strings.Join([]string{`&LocalSubjectAccessReview{`, |
| 1069 | `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, |
| 1070 | `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SubjectAccessReviewSpec", "SubjectAccessReviewSpec", 1), `&`, ``, 1) + `,`, |
| 1071 | `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SubjectAccessReviewStatus", "SubjectAccessReviewStatus", 1), `&`, ``, 1) + `,`, |
| 1072 | `}`, |
| 1073 | }, "") |
| 1074 | return s |
| 1075 | } |
| 1076 | func (this *NonResourceAttributes) String() string { |
| 1077 | if this == nil { |
| 1078 | return "nil" |
| 1079 | } |
| 1080 | s := strings.Join([]string{`&NonResourceAttributes{`, |
| 1081 | `Path:` + fmt.Sprintf("%v", this.Path) + `,`, |
| 1082 | `Verb:` + fmt.Sprintf("%v", this.Verb) + `,`, |
| 1083 | `}`, |
| 1084 | }, "") |
| 1085 | return s |
| 1086 | } |
| 1087 | func (this *NonResourceRule) String() string { |
| 1088 | if this == nil { |
| 1089 | return "nil" |
| 1090 | } |
| 1091 | s := strings.Join([]string{`&NonResourceRule{`, |
| 1092 | `Verbs:` + fmt.Sprintf("%v", this.Verbs) + `,`, |
| 1093 | `NonResourceURLs:` + fmt.Sprintf("%v", this.NonResourceURLs) + `,`, |
| 1094 | `}`, |
| 1095 | }, "") |
| 1096 | return s |
| 1097 | } |
| 1098 | func (this *ResourceAttributes) String() string { |
| 1099 | if this == nil { |
| 1100 | return "nil" |
| 1101 | } |
| 1102 | s := strings.Join([]string{`&ResourceAttributes{`, |
| 1103 | `Namespace:` + fmt.Sprintf("%v", this.Namespace) + `,`, |
| 1104 | `Verb:` + fmt.Sprintf("%v", this.Verb) + `,`, |
| 1105 | `Group:` + fmt.Sprintf("%v", this.Group) + `,`, |
| 1106 | `Version:` + fmt.Sprintf("%v", this.Version) + `,`, |
| 1107 | `Resource:` + fmt.Sprintf("%v", this.Resource) + `,`, |
| 1108 | `Subresource:` + fmt.Sprintf("%v", this.Subresource) + `,`, |
| 1109 | `Name:` + fmt.Sprintf("%v", this.Name) + `,`, |
| 1110 | `}`, |
| 1111 | }, "") |
| 1112 | return s |
| 1113 | } |
| 1114 | func (this *ResourceRule) String() string { |
| 1115 | if this == nil { |
| 1116 | return "nil" |
| 1117 | } |
| 1118 | s := strings.Join([]string{`&ResourceRule{`, |
| 1119 | `Verbs:` + fmt.Sprintf("%v", this.Verbs) + `,`, |
| 1120 | `APIGroups:` + fmt.Sprintf("%v", this.APIGroups) + `,`, |
| 1121 | `Resources:` + fmt.Sprintf("%v", this.Resources) + `,`, |
| 1122 | `ResourceNames:` + fmt.Sprintf("%v", this.ResourceNames) + `,`, |
| 1123 | `}`, |
| 1124 | }, "") |
| 1125 | return s |
| 1126 | } |
| 1127 | func (this *SelfSubjectAccessReview) String() string { |
| 1128 | if this == nil { |
| 1129 | return "nil" |
| 1130 | } |
| 1131 | s := strings.Join([]string{`&SelfSubjectAccessReview{`, |
| 1132 | `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, |
| 1133 | `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SelfSubjectAccessReviewSpec", "SelfSubjectAccessReviewSpec", 1), `&`, ``, 1) + `,`, |
| 1134 | `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SubjectAccessReviewStatus", "SubjectAccessReviewStatus", 1), `&`, ``, 1) + `,`, |
| 1135 | `}`, |
| 1136 | }, "") |
| 1137 | return s |
| 1138 | } |
| 1139 | func (this *SelfSubjectAccessReviewSpec) String() string { |
| 1140 | if this == nil { |
| 1141 | return "nil" |
| 1142 | } |
| 1143 | s := strings.Join([]string{`&SelfSubjectAccessReviewSpec{`, |
| 1144 | `ResourceAttributes:` + strings.Replace(fmt.Sprintf("%v", this.ResourceAttributes), "ResourceAttributes", "ResourceAttributes", 1) + `,`, |
| 1145 | `NonResourceAttributes:` + strings.Replace(fmt.Sprintf("%v", this.NonResourceAttributes), "NonResourceAttributes", "NonResourceAttributes", 1) + `,`, |
| 1146 | `}`, |
| 1147 | }, "") |
| 1148 | return s |
| 1149 | } |
| 1150 | func (this *SelfSubjectRulesReview) String() string { |
| 1151 | if this == nil { |
| 1152 | return "nil" |
| 1153 | } |
| 1154 | s := strings.Join([]string{`&SelfSubjectRulesReview{`, |
| 1155 | `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, |
| 1156 | `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SelfSubjectRulesReviewSpec", "SelfSubjectRulesReviewSpec", 1), `&`, ``, 1) + `,`, |
| 1157 | `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SubjectRulesReviewStatus", "SubjectRulesReviewStatus", 1), `&`, ``, 1) + `,`, |
| 1158 | `}`, |
| 1159 | }, "") |
| 1160 | return s |
| 1161 | } |
| 1162 | func (this *SelfSubjectRulesReviewSpec) String() string { |
| 1163 | if this == nil { |
| 1164 | return "nil" |
| 1165 | } |
| 1166 | s := strings.Join([]string{`&SelfSubjectRulesReviewSpec{`, |
| 1167 | `Namespace:` + fmt.Sprintf("%v", this.Namespace) + `,`, |
| 1168 | `}`, |
| 1169 | }, "") |
| 1170 | return s |
| 1171 | } |
| 1172 | func (this *SubjectAccessReview) String() string { |
| 1173 | if this == nil { |
| 1174 | return "nil" |
| 1175 | } |
| 1176 | s := strings.Join([]string{`&SubjectAccessReview{`, |
| 1177 | `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, |
| 1178 | `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SubjectAccessReviewSpec", "SubjectAccessReviewSpec", 1), `&`, ``, 1) + `,`, |
| 1179 | `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SubjectAccessReviewStatus", "SubjectAccessReviewStatus", 1), `&`, ``, 1) + `,`, |
| 1180 | `}`, |
| 1181 | }, "") |
| 1182 | return s |
| 1183 | } |
| 1184 | func (this *SubjectAccessReviewSpec) String() string { |
| 1185 | if this == nil { |
| 1186 | return "nil" |
| 1187 | } |
| 1188 | keysForExtra := make([]string, 0, len(this.Extra)) |
| 1189 | for k := range this.Extra { |
| 1190 | keysForExtra = append(keysForExtra, k) |
| 1191 | } |
| 1192 | github_com_gogo_protobuf_sortkeys.Strings(keysForExtra) |
| 1193 | mapStringForExtra := "map[string]ExtraValue{" |
| 1194 | for _, k := range keysForExtra { |
| 1195 | mapStringForExtra += fmt.Sprintf("%v: %v,", k, this.Extra[k]) |
| 1196 | } |
| 1197 | mapStringForExtra += "}" |
| 1198 | s := strings.Join([]string{`&SubjectAccessReviewSpec{`, |
| 1199 | `ResourceAttributes:` + strings.Replace(fmt.Sprintf("%v", this.ResourceAttributes), "ResourceAttributes", "ResourceAttributes", 1) + `,`, |
| 1200 | `NonResourceAttributes:` + strings.Replace(fmt.Sprintf("%v", this.NonResourceAttributes), "NonResourceAttributes", "NonResourceAttributes", 1) + `,`, |
| 1201 | `User:` + fmt.Sprintf("%v", this.User) + `,`, |
| 1202 | `Groups:` + fmt.Sprintf("%v", this.Groups) + `,`, |
| 1203 | `Extra:` + mapStringForExtra + `,`, |
| 1204 | `UID:` + fmt.Sprintf("%v", this.UID) + `,`, |
| 1205 | `}`, |
| 1206 | }, "") |
| 1207 | return s |
| 1208 | } |
| 1209 | func (this *SubjectAccessReviewStatus) String() string { |
| 1210 | if this == nil { |
| 1211 | return "nil" |
| 1212 | } |
| 1213 | s := strings.Join([]string{`&SubjectAccessReviewStatus{`, |
| 1214 | `Allowed:` + fmt.Sprintf("%v", this.Allowed) + `,`, |
| 1215 | `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, |
| 1216 | `EvaluationError:` + fmt.Sprintf("%v", this.EvaluationError) + `,`, |
| 1217 | `Denied:` + fmt.Sprintf("%v", this.Denied) + `,`, |
| 1218 | `}`, |
| 1219 | }, "") |
| 1220 | return s |
| 1221 | } |
| 1222 | func (this *SubjectRulesReviewStatus) String() string { |
| 1223 | if this == nil { |
| 1224 | return "nil" |
| 1225 | } |
| 1226 | s := strings.Join([]string{`&SubjectRulesReviewStatus{`, |
| 1227 | `ResourceRules:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ResourceRules), "ResourceRule", "ResourceRule", 1), `&`, ``, 1) + `,`, |
| 1228 | `NonResourceRules:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.NonResourceRules), "NonResourceRule", "NonResourceRule", 1), `&`, ``, 1) + `,`, |
| 1229 | `Incomplete:` + fmt.Sprintf("%v", this.Incomplete) + `,`, |
| 1230 | `EvaluationError:` + fmt.Sprintf("%v", this.EvaluationError) + `,`, |
| 1231 | `}`, |
| 1232 | }, "") |
| 1233 | return s |
| 1234 | } |
| 1235 | func valueToStringGenerated(v interface{}) string { |
| 1236 | rv := reflect.ValueOf(v) |
| 1237 | if rv.IsNil() { |
| 1238 | return "nil" |
| 1239 | } |
| 1240 | pv := reflect.Indirect(rv).Interface() |
| 1241 | return fmt.Sprintf("*%v", pv) |
| 1242 | } |
| 1243 | func (m *ExtraValue) Unmarshal(dAtA []byte) error { |
| 1244 | l := len(dAtA) |
| 1245 | iNdEx := 0 |
| 1246 | for iNdEx < l { |
| 1247 | preIndex := iNdEx |
| 1248 | var wire uint64 |
| 1249 | for shift := uint(0); ; shift += 7 { |
| 1250 | if shift >= 64 { |
| 1251 | return ErrIntOverflowGenerated |
| 1252 | } |
| 1253 | if iNdEx >= l { |
| 1254 | return io.ErrUnexpectedEOF |
| 1255 | } |
| 1256 | b := dAtA[iNdEx] |
| 1257 | iNdEx++ |
| 1258 | wire |= (uint64(b) & 0x7F) << shift |
| 1259 | if b < 0x80 { |
| 1260 | break |
| 1261 | } |
| 1262 | } |
| 1263 | fieldNum := int32(wire >> 3) |
| 1264 | wireType := int(wire & 0x7) |
| 1265 | if wireType == 4 { |
| 1266 | return fmt.Errorf("proto: ExtraValue: wiretype end group for non-group") |
| 1267 | } |
| 1268 | if fieldNum <= 0 { |
| 1269 | return fmt.Errorf("proto: ExtraValue: illegal tag %d (wire type %d)", fieldNum, wire) |
| 1270 | } |
| 1271 | switch fieldNum { |
| 1272 | case 1: |
| 1273 | if wireType != 2 { |
| 1274 | return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) |
| 1275 | } |
| 1276 | var stringLen uint64 |
| 1277 | for shift := uint(0); ; shift += 7 { |
| 1278 | if shift >= 64 { |
| 1279 | return ErrIntOverflowGenerated |
| 1280 | } |
| 1281 | if iNdEx >= l { |
| 1282 | return io.ErrUnexpectedEOF |
| 1283 | } |
| 1284 | b := dAtA[iNdEx] |
| 1285 | iNdEx++ |
| 1286 | stringLen |= (uint64(b) & 0x7F) << shift |
| 1287 | if b < 0x80 { |
| 1288 | break |
| 1289 | } |
| 1290 | } |
| 1291 | intStringLen := int(stringLen) |
| 1292 | if intStringLen < 0 { |
| 1293 | return ErrInvalidLengthGenerated |
| 1294 | } |
| 1295 | postIndex := iNdEx + intStringLen |
| 1296 | if postIndex > l { |
| 1297 | return io.ErrUnexpectedEOF |
| 1298 | } |
| 1299 | *m = append(*m, string(dAtA[iNdEx:postIndex])) |
| 1300 | iNdEx = postIndex |
| 1301 | default: |
| 1302 | iNdEx = preIndex |
| 1303 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 1304 | if err != nil { |
| 1305 | return err |
| 1306 | } |
| 1307 | if skippy < 0 { |
| 1308 | return ErrInvalidLengthGenerated |
| 1309 | } |
| 1310 | if (iNdEx + skippy) > l { |
| 1311 | return io.ErrUnexpectedEOF |
| 1312 | } |
| 1313 | iNdEx += skippy |
| 1314 | } |
| 1315 | } |
| 1316 | |
| 1317 | if iNdEx > l { |
| 1318 | return io.ErrUnexpectedEOF |
| 1319 | } |
| 1320 | return nil |
| 1321 | } |
| 1322 | func (m *LocalSubjectAccessReview) Unmarshal(dAtA []byte) error { |
| 1323 | l := len(dAtA) |
| 1324 | iNdEx := 0 |
| 1325 | for iNdEx < l { |
| 1326 | preIndex := iNdEx |
| 1327 | var wire uint64 |
| 1328 | for shift := uint(0); ; shift += 7 { |
| 1329 | if shift >= 64 { |
| 1330 | return ErrIntOverflowGenerated |
| 1331 | } |
| 1332 | if iNdEx >= l { |
| 1333 | return io.ErrUnexpectedEOF |
| 1334 | } |
| 1335 | b := dAtA[iNdEx] |
| 1336 | iNdEx++ |
| 1337 | wire |= (uint64(b) & 0x7F) << shift |
| 1338 | if b < 0x80 { |
| 1339 | break |
| 1340 | } |
| 1341 | } |
| 1342 | fieldNum := int32(wire >> 3) |
| 1343 | wireType := int(wire & 0x7) |
| 1344 | if wireType == 4 { |
| 1345 | return fmt.Errorf("proto: LocalSubjectAccessReview: wiretype end group for non-group") |
| 1346 | } |
| 1347 | if fieldNum <= 0 { |
| 1348 | return fmt.Errorf("proto: LocalSubjectAccessReview: illegal tag %d (wire type %d)", fieldNum, wire) |
| 1349 | } |
| 1350 | switch fieldNum { |
| 1351 | case 1: |
| 1352 | if wireType != 2 { |
| 1353 | return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) |
| 1354 | } |
| 1355 | var msglen int |
| 1356 | for shift := uint(0); ; shift += 7 { |
| 1357 | if shift >= 64 { |
| 1358 | return ErrIntOverflowGenerated |
| 1359 | } |
| 1360 | if iNdEx >= l { |
| 1361 | return io.ErrUnexpectedEOF |
| 1362 | } |
| 1363 | b := dAtA[iNdEx] |
| 1364 | iNdEx++ |
| 1365 | msglen |= (int(b) & 0x7F) << shift |
| 1366 | if b < 0x80 { |
| 1367 | break |
| 1368 | } |
| 1369 | } |
| 1370 | if msglen < 0 { |
| 1371 | return ErrInvalidLengthGenerated |
| 1372 | } |
| 1373 | postIndex := iNdEx + msglen |
| 1374 | if postIndex > l { |
| 1375 | return io.ErrUnexpectedEOF |
| 1376 | } |
| 1377 | if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 1378 | return err |
| 1379 | } |
| 1380 | iNdEx = postIndex |
| 1381 | case 2: |
| 1382 | if wireType != 2 { |
| 1383 | return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) |
| 1384 | } |
| 1385 | var msglen int |
| 1386 | for shift := uint(0); ; shift += 7 { |
| 1387 | if shift >= 64 { |
| 1388 | return ErrIntOverflowGenerated |
| 1389 | } |
| 1390 | if iNdEx >= l { |
| 1391 | return io.ErrUnexpectedEOF |
| 1392 | } |
| 1393 | b := dAtA[iNdEx] |
| 1394 | iNdEx++ |
| 1395 | msglen |= (int(b) & 0x7F) << shift |
| 1396 | if b < 0x80 { |
| 1397 | break |
| 1398 | } |
| 1399 | } |
| 1400 | if msglen < 0 { |
| 1401 | return ErrInvalidLengthGenerated |
| 1402 | } |
| 1403 | postIndex := iNdEx + msglen |
| 1404 | if postIndex > l { |
| 1405 | return io.ErrUnexpectedEOF |
| 1406 | } |
| 1407 | if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 1408 | return err |
| 1409 | } |
| 1410 | iNdEx = postIndex |
| 1411 | case 3: |
| 1412 | if wireType != 2 { |
| 1413 | return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) |
| 1414 | } |
| 1415 | var msglen int |
| 1416 | for shift := uint(0); ; shift += 7 { |
| 1417 | if shift >= 64 { |
| 1418 | return ErrIntOverflowGenerated |
| 1419 | } |
| 1420 | if iNdEx >= l { |
| 1421 | return io.ErrUnexpectedEOF |
| 1422 | } |
| 1423 | b := dAtA[iNdEx] |
| 1424 | iNdEx++ |
| 1425 | msglen |= (int(b) & 0x7F) << shift |
| 1426 | if b < 0x80 { |
| 1427 | break |
| 1428 | } |
| 1429 | } |
| 1430 | if msglen < 0 { |
| 1431 | return ErrInvalidLengthGenerated |
| 1432 | } |
| 1433 | postIndex := iNdEx + msglen |
| 1434 | if postIndex > l { |
| 1435 | return io.ErrUnexpectedEOF |
| 1436 | } |
| 1437 | if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 1438 | return err |
| 1439 | } |
| 1440 | iNdEx = postIndex |
| 1441 | default: |
| 1442 | iNdEx = preIndex |
| 1443 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 1444 | if err != nil { |
| 1445 | return err |
| 1446 | } |
| 1447 | if skippy < 0 { |
| 1448 | return ErrInvalidLengthGenerated |
| 1449 | } |
| 1450 | if (iNdEx + skippy) > l { |
| 1451 | return io.ErrUnexpectedEOF |
| 1452 | } |
| 1453 | iNdEx += skippy |
| 1454 | } |
| 1455 | } |
| 1456 | |
| 1457 | if iNdEx > l { |
| 1458 | return io.ErrUnexpectedEOF |
| 1459 | } |
| 1460 | return nil |
| 1461 | } |
| 1462 | func (m *NonResourceAttributes) Unmarshal(dAtA []byte) error { |
| 1463 | l := len(dAtA) |
| 1464 | iNdEx := 0 |
| 1465 | for iNdEx < l { |
| 1466 | preIndex := iNdEx |
| 1467 | var wire uint64 |
| 1468 | for shift := uint(0); ; shift += 7 { |
| 1469 | if shift >= 64 { |
| 1470 | return ErrIntOverflowGenerated |
| 1471 | } |
| 1472 | if iNdEx >= l { |
| 1473 | return io.ErrUnexpectedEOF |
| 1474 | } |
| 1475 | b := dAtA[iNdEx] |
| 1476 | iNdEx++ |
| 1477 | wire |= (uint64(b) & 0x7F) << shift |
| 1478 | if b < 0x80 { |
| 1479 | break |
| 1480 | } |
| 1481 | } |
| 1482 | fieldNum := int32(wire >> 3) |
| 1483 | wireType := int(wire & 0x7) |
| 1484 | if wireType == 4 { |
| 1485 | return fmt.Errorf("proto: NonResourceAttributes: wiretype end group for non-group") |
| 1486 | } |
| 1487 | if fieldNum <= 0 { |
| 1488 | return fmt.Errorf("proto: NonResourceAttributes: illegal tag %d (wire type %d)", fieldNum, wire) |
| 1489 | } |
| 1490 | switch fieldNum { |
| 1491 | case 1: |
| 1492 | if wireType != 2 { |
| 1493 | return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) |
| 1494 | } |
| 1495 | var stringLen uint64 |
| 1496 | for shift := uint(0); ; shift += 7 { |
| 1497 | if shift >= 64 { |
| 1498 | return ErrIntOverflowGenerated |
| 1499 | } |
| 1500 | if iNdEx >= l { |
| 1501 | return io.ErrUnexpectedEOF |
| 1502 | } |
| 1503 | b := dAtA[iNdEx] |
| 1504 | iNdEx++ |
| 1505 | stringLen |= (uint64(b) & 0x7F) << shift |
| 1506 | if b < 0x80 { |
| 1507 | break |
| 1508 | } |
| 1509 | } |
| 1510 | intStringLen := int(stringLen) |
| 1511 | if intStringLen < 0 { |
| 1512 | return ErrInvalidLengthGenerated |
| 1513 | } |
| 1514 | postIndex := iNdEx + intStringLen |
| 1515 | if postIndex > l { |
| 1516 | return io.ErrUnexpectedEOF |
| 1517 | } |
| 1518 | m.Path = string(dAtA[iNdEx:postIndex]) |
| 1519 | iNdEx = postIndex |
| 1520 | case 2: |
| 1521 | if wireType != 2 { |
| 1522 | return fmt.Errorf("proto: wrong wireType = %d for field Verb", wireType) |
| 1523 | } |
| 1524 | var stringLen uint64 |
| 1525 | for shift := uint(0); ; shift += 7 { |
| 1526 | if shift >= 64 { |
| 1527 | return ErrIntOverflowGenerated |
| 1528 | } |
| 1529 | if iNdEx >= l { |
| 1530 | return io.ErrUnexpectedEOF |
| 1531 | } |
| 1532 | b := dAtA[iNdEx] |
| 1533 | iNdEx++ |
| 1534 | stringLen |= (uint64(b) & 0x7F) << shift |
| 1535 | if b < 0x80 { |
| 1536 | break |
| 1537 | } |
| 1538 | } |
| 1539 | intStringLen := int(stringLen) |
| 1540 | if intStringLen < 0 { |
| 1541 | return ErrInvalidLengthGenerated |
| 1542 | } |
| 1543 | postIndex := iNdEx + intStringLen |
| 1544 | if postIndex > l { |
| 1545 | return io.ErrUnexpectedEOF |
| 1546 | } |
| 1547 | m.Verb = string(dAtA[iNdEx:postIndex]) |
| 1548 | iNdEx = postIndex |
| 1549 | default: |
| 1550 | iNdEx = preIndex |
| 1551 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 1552 | if err != nil { |
| 1553 | return err |
| 1554 | } |
| 1555 | if skippy < 0 { |
| 1556 | return ErrInvalidLengthGenerated |
| 1557 | } |
| 1558 | if (iNdEx + skippy) > l { |
| 1559 | return io.ErrUnexpectedEOF |
| 1560 | } |
| 1561 | iNdEx += skippy |
| 1562 | } |
| 1563 | } |
| 1564 | |
| 1565 | if iNdEx > l { |
| 1566 | return io.ErrUnexpectedEOF |
| 1567 | } |
| 1568 | return nil |
| 1569 | } |
| 1570 | func (m *NonResourceRule) Unmarshal(dAtA []byte) error { |
| 1571 | l := len(dAtA) |
| 1572 | iNdEx := 0 |
| 1573 | for iNdEx < l { |
| 1574 | preIndex := iNdEx |
| 1575 | var wire uint64 |
| 1576 | for shift := uint(0); ; shift += 7 { |
| 1577 | if shift >= 64 { |
| 1578 | return ErrIntOverflowGenerated |
| 1579 | } |
| 1580 | if iNdEx >= l { |
| 1581 | return io.ErrUnexpectedEOF |
| 1582 | } |
| 1583 | b := dAtA[iNdEx] |
| 1584 | iNdEx++ |
| 1585 | wire |= (uint64(b) & 0x7F) << shift |
| 1586 | if b < 0x80 { |
| 1587 | break |
| 1588 | } |
| 1589 | } |
| 1590 | fieldNum := int32(wire >> 3) |
| 1591 | wireType := int(wire & 0x7) |
| 1592 | if wireType == 4 { |
| 1593 | return fmt.Errorf("proto: NonResourceRule: wiretype end group for non-group") |
| 1594 | } |
| 1595 | if fieldNum <= 0 { |
| 1596 | return fmt.Errorf("proto: NonResourceRule: illegal tag %d (wire type %d)", fieldNum, wire) |
| 1597 | } |
| 1598 | switch fieldNum { |
| 1599 | case 1: |
| 1600 | if wireType != 2 { |
| 1601 | return fmt.Errorf("proto: wrong wireType = %d for field Verbs", wireType) |
| 1602 | } |
| 1603 | var stringLen uint64 |
| 1604 | for shift := uint(0); ; shift += 7 { |
| 1605 | if shift >= 64 { |
| 1606 | return ErrIntOverflowGenerated |
| 1607 | } |
| 1608 | if iNdEx >= l { |
| 1609 | return io.ErrUnexpectedEOF |
| 1610 | } |
| 1611 | b := dAtA[iNdEx] |
| 1612 | iNdEx++ |
| 1613 | stringLen |= (uint64(b) & 0x7F) << shift |
| 1614 | if b < 0x80 { |
| 1615 | break |
| 1616 | } |
| 1617 | } |
| 1618 | intStringLen := int(stringLen) |
| 1619 | if intStringLen < 0 { |
| 1620 | return ErrInvalidLengthGenerated |
| 1621 | } |
| 1622 | postIndex := iNdEx + intStringLen |
| 1623 | if postIndex > l { |
| 1624 | return io.ErrUnexpectedEOF |
| 1625 | } |
| 1626 | m.Verbs = append(m.Verbs, string(dAtA[iNdEx:postIndex])) |
| 1627 | iNdEx = postIndex |
| 1628 | case 2: |
| 1629 | if wireType != 2 { |
| 1630 | return fmt.Errorf("proto: wrong wireType = %d for field NonResourceURLs", wireType) |
| 1631 | } |
| 1632 | var stringLen uint64 |
| 1633 | for shift := uint(0); ; shift += 7 { |
| 1634 | if shift >= 64 { |
| 1635 | return ErrIntOverflowGenerated |
| 1636 | } |
| 1637 | if iNdEx >= l { |
| 1638 | return io.ErrUnexpectedEOF |
| 1639 | } |
| 1640 | b := dAtA[iNdEx] |
| 1641 | iNdEx++ |
| 1642 | stringLen |= (uint64(b) & 0x7F) << shift |
| 1643 | if b < 0x80 { |
| 1644 | break |
| 1645 | } |
| 1646 | } |
| 1647 | intStringLen := int(stringLen) |
| 1648 | if intStringLen < 0 { |
| 1649 | return ErrInvalidLengthGenerated |
| 1650 | } |
| 1651 | postIndex := iNdEx + intStringLen |
| 1652 | if postIndex > l { |
| 1653 | return io.ErrUnexpectedEOF |
| 1654 | } |
| 1655 | m.NonResourceURLs = append(m.NonResourceURLs, string(dAtA[iNdEx:postIndex])) |
| 1656 | iNdEx = postIndex |
| 1657 | default: |
| 1658 | iNdEx = preIndex |
| 1659 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 1660 | if err != nil { |
| 1661 | return err |
| 1662 | } |
| 1663 | if skippy < 0 { |
| 1664 | return ErrInvalidLengthGenerated |
| 1665 | } |
| 1666 | if (iNdEx + skippy) > l { |
| 1667 | return io.ErrUnexpectedEOF |
| 1668 | } |
| 1669 | iNdEx += skippy |
| 1670 | } |
| 1671 | } |
| 1672 | |
| 1673 | if iNdEx > l { |
| 1674 | return io.ErrUnexpectedEOF |
| 1675 | } |
| 1676 | return nil |
| 1677 | } |
| 1678 | func (m *ResourceAttributes) Unmarshal(dAtA []byte) error { |
| 1679 | l := len(dAtA) |
| 1680 | iNdEx := 0 |
| 1681 | for iNdEx < l { |
| 1682 | preIndex := iNdEx |
| 1683 | var wire uint64 |
| 1684 | for shift := uint(0); ; shift += 7 { |
| 1685 | if shift >= 64 { |
| 1686 | return ErrIntOverflowGenerated |
| 1687 | } |
| 1688 | if iNdEx >= l { |
| 1689 | return io.ErrUnexpectedEOF |
| 1690 | } |
| 1691 | b := dAtA[iNdEx] |
| 1692 | iNdEx++ |
| 1693 | wire |= (uint64(b) & 0x7F) << shift |
| 1694 | if b < 0x80 { |
| 1695 | break |
| 1696 | } |
| 1697 | } |
| 1698 | fieldNum := int32(wire >> 3) |
| 1699 | wireType := int(wire & 0x7) |
| 1700 | if wireType == 4 { |
| 1701 | return fmt.Errorf("proto: ResourceAttributes: wiretype end group for non-group") |
| 1702 | } |
| 1703 | if fieldNum <= 0 { |
| 1704 | return fmt.Errorf("proto: ResourceAttributes: illegal tag %d (wire type %d)", fieldNum, wire) |
| 1705 | } |
| 1706 | switch fieldNum { |
| 1707 | case 1: |
| 1708 | if wireType != 2 { |
| 1709 | return fmt.Errorf("proto: wrong wireType = %d for field Namespace", wireType) |
| 1710 | } |
| 1711 | var stringLen uint64 |
| 1712 | for shift := uint(0); ; shift += 7 { |
| 1713 | if shift >= 64 { |
| 1714 | return ErrIntOverflowGenerated |
| 1715 | } |
| 1716 | if iNdEx >= l { |
| 1717 | return io.ErrUnexpectedEOF |
| 1718 | } |
| 1719 | b := dAtA[iNdEx] |
| 1720 | iNdEx++ |
| 1721 | stringLen |= (uint64(b) & 0x7F) << shift |
| 1722 | if b < 0x80 { |
| 1723 | break |
| 1724 | } |
| 1725 | } |
| 1726 | intStringLen := int(stringLen) |
| 1727 | if intStringLen < 0 { |
| 1728 | return ErrInvalidLengthGenerated |
| 1729 | } |
| 1730 | postIndex := iNdEx + intStringLen |
| 1731 | if postIndex > l { |
| 1732 | return io.ErrUnexpectedEOF |
| 1733 | } |
| 1734 | m.Namespace = string(dAtA[iNdEx:postIndex]) |
| 1735 | iNdEx = postIndex |
| 1736 | case 2: |
| 1737 | if wireType != 2 { |
| 1738 | return fmt.Errorf("proto: wrong wireType = %d for field Verb", wireType) |
| 1739 | } |
| 1740 | var stringLen uint64 |
| 1741 | for shift := uint(0); ; shift += 7 { |
| 1742 | if shift >= 64 { |
| 1743 | return ErrIntOverflowGenerated |
| 1744 | } |
| 1745 | if iNdEx >= l { |
| 1746 | return io.ErrUnexpectedEOF |
| 1747 | } |
| 1748 | b := dAtA[iNdEx] |
| 1749 | iNdEx++ |
| 1750 | stringLen |= (uint64(b) & 0x7F) << shift |
| 1751 | if b < 0x80 { |
| 1752 | break |
| 1753 | } |
| 1754 | } |
| 1755 | intStringLen := int(stringLen) |
| 1756 | if intStringLen < 0 { |
| 1757 | return ErrInvalidLengthGenerated |
| 1758 | } |
| 1759 | postIndex := iNdEx + intStringLen |
| 1760 | if postIndex > l { |
| 1761 | return io.ErrUnexpectedEOF |
| 1762 | } |
| 1763 | m.Verb = string(dAtA[iNdEx:postIndex]) |
| 1764 | iNdEx = postIndex |
| 1765 | case 3: |
| 1766 | if wireType != 2 { |
| 1767 | return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType) |
| 1768 | } |
| 1769 | var stringLen uint64 |
| 1770 | for shift := uint(0); ; shift += 7 { |
| 1771 | if shift >= 64 { |
| 1772 | return ErrIntOverflowGenerated |
| 1773 | } |
| 1774 | if iNdEx >= l { |
| 1775 | return io.ErrUnexpectedEOF |
| 1776 | } |
| 1777 | b := dAtA[iNdEx] |
| 1778 | iNdEx++ |
| 1779 | stringLen |= (uint64(b) & 0x7F) << shift |
| 1780 | if b < 0x80 { |
| 1781 | break |
| 1782 | } |
| 1783 | } |
| 1784 | intStringLen := int(stringLen) |
| 1785 | if intStringLen < 0 { |
| 1786 | return ErrInvalidLengthGenerated |
| 1787 | } |
| 1788 | postIndex := iNdEx + intStringLen |
| 1789 | if postIndex > l { |
| 1790 | return io.ErrUnexpectedEOF |
| 1791 | } |
| 1792 | m.Group = string(dAtA[iNdEx:postIndex]) |
| 1793 | iNdEx = postIndex |
| 1794 | case 4: |
| 1795 | if wireType != 2 { |
| 1796 | return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) |
| 1797 | } |
| 1798 | var stringLen uint64 |
| 1799 | for shift := uint(0); ; shift += 7 { |
| 1800 | if shift >= 64 { |
| 1801 | return ErrIntOverflowGenerated |
| 1802 | } |
| 1803 | if iNdEx >= l { |
| 1804 | return io.ErrUnexpectedEOF |
| 1805 | } |
| 1806 | b := dAtA[iNdEx] |
| 1807 | iNdEx++ |
| 1808 | stringLen |= (uint64(b) & 0x7F) << shift |
| 1809 | if b < 0x80 { |
| 1810 | break |
| 1811 | } |
| 1812 | } |
| 1813 | intStringLen := int(stringLen) |
| 1814 | if intStringLen < 0 { |
| 1815 | return ErrInvalidLengthGenerated |
| 1816 | } |
| 1817 | postIndex := iNdEx + intStringLen |
| 1818 | if postIndex > l { |
| 1819 | return io.ErrUnexpectedEOF |
| 1820 | } |
| 1821 | m.Version = string(dAtA[iNdEx:postIndex]) |
| 1822 | iNdEx = postIndex |
| 1823 | case 5: |
| 1824 | if wireType != 2 { |
| 1825 | return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType) |
| 1826 | } |
| 1827 | var stringLen uint64 |
| 1828 | for shift := uint(0); ; shift += 7 { |
| 1829 | if shift >= 64 { |
| 1830 | return ErrIntOverflowGenerated |
| 1831 | } |
| 1832 | if iNdEx >= l { |
| 1833 | return io.ErrUnexpectedEOF |
| 1834 | } |
| 1835 | b := dAtA[iNdEx] |
| 1836 | iNdEx++ |
| 1837 | stringLen |= (uint64(b) & 0x7F) << shift |
| 1838 | if b < 0x80 { |
| 1839 | break |
| 1840 | } |
| 1841 | } |
| 1842 | intStringLen := int(stringLen) |
| 1843 | if intStringLen < 0 { |
| 1844 | return ErrInvalidLengthGenerated |
| 1845 | } |
| 1846 | postIndex := iNdEx + intStringLen |
| 1847 | if postIndex > l { |
| 1848 | return io.ErrUnexpectedEOF |
| 1849 | } |
| 1850 | m.Resource = string(dAtA[iNdEx:postIndex]) |
| 1851 | iNdEx = postIndex |
| 1852 | case 6: |
| 1853 | if wireType != 2 { |
| 1854 | return fmt.Errorf("proto: wrong wireType = %d for field Subresource", wireType) |
| 1855 | } |
| 1856 | var stringLen uint64 |
| 1857 | for shift := uint(0); ; shift += 7 { |
| 1858 | if shift >= 64 { |
| 1859 | return ErrIntOverflowGenerated |
| 1860 | } |
| 1861 | if iNdEx >= l { |
| 1862 | return io.ErrUnexpectedEOF |
| 1863 | } |
| 1864 | b := dAtA[iNdEx] |
| 1865 | iNdEx++ |
| 1866 | stringLen |= (uint64(b) & 0x7F) << shift |
| 1867 | if b < 0x80 { |
| 1868 | break |
| 1869 | } |
| 1870 | } |
| 1871 | intStringLen := int(stringLen) |
| 1872 | if intStringLen < 0 { |
| 1873 | return ErrInvalidLengthGenerated |
| 1874 | } |
| 1875 | postIndex := iNdEx + intStringLen |
| 1876 | if postIndex > l { |
| 1877 | return io.ErrUnexpectedEOF |
| 1878 | } |
| 1879 | m.Subresource = string(dAtA[iNdEx:postIndex]) |
| 1880 | iNdEx = postIndex |
| 1881 | case 7: |
| 1882 | if wireType != 2 { |
| 1883 | return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) |
| 1884 | } |
| 1885 | var stringLen uint64 |
| 1886 | for shift := uint(0); ; shift += 7 { |
| 1887 | if shift >= 64 { |
| 1888 | return ErrIntOverflowGenerated |
| 1889 | } |
| 1890 | if iNdEx >= l { |
| 1891 | return io.ErrUnexpectedEOF |
| 1892 | } |
| 1893 | b := dAtA[iNdEx] |
| 1894 | iNdEx++ |
| 1895 | stringLen |= (uint64(b) & 0x7F) << shift |
| 1896 | if b < 0x80 { |
| 1897 | break |
| 1898 | } |
| 1899 | } |
| 1900 | intStringLen := int(stringLen) |
| 1901 | if intStringLen < 0 { |
| 1902 | return ErrInvalidLengthGenerated |
| 1903 | } |
| 1904 | postIndex := iNdEx + intStringLen |
| 1905 | if postIndex > l { |
| 1906 | return io.ErrUnexpectedEOF |
| 1907 | } |
| 1908 | m.Name = string(dAtA[iNdEx:postIndex]) |
| 1909 | iNdEx = postIndex |
| 1910 | default: |
| 1911 | iNdEx = preIndex |
| 1912 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 1913 | if err != nil { |
| 1914 | return err |
| 1915 | } |
| 1916 | if skippy < 0 { |
| 1917 | return ErrInvalidLengthGenerated |
| 1918 | } |
| 1919 | if (iNdEx + skippy) > l { |
| 1920 | return io.ErrUnexpectedEOF |
| 1921 | } |
| 1922 | iNdEx += skippy |
| 1923 | } |
| 1924 | } |
| 1925 | |
| 1926 | if iNdEx > l { |
| 1927 | return io.ErrUnexpectedEOF |
| 1928 | } |
| 1929 | return nil |
| 1930 | } |
| 1931 | func (m *ResourceRule) Unmarshal(dAtA []byte) error { |
| 1932 | l := len(dAtA) |
| 1933 | iNdEx := 0 |
| 1934 | for iNdEx < l { |
| 1935 | preIndex := iNdEx |
| 1936 | var wire uint64 |
| 1937 | for shift := uint(0); ; shift += 7 { |
| 1938 | if shift >= 64 { |
| 1939 | return ErrIntOverflowGenerated |
| 1940 | } |
| 1941 | if iNdEx >= l { |
| 1942 | return io.ErrUnexpectedEOF |
| 1943 | } |
| 1944 | b := dAtA[iNdEx] |
| 1945 | iNdEx++ |
| 1946 | wire |= (uint64(b) & 0x7F) << shift |
| 1947 | if b < 0x80 { |
| 1948 | break |
| 1949 | } |
| 1950 | } |
| 1951 | fieldNum := int32(wire >> 3) |
| 1952 | wireType := int(wire & 0x7) |
| 1953 | if wireType == 4 { |
| 1954 | return fmt.Errorf("proto: ResourceRule: wiretype end group for non-group") |
| 1955 | } |
| 1956 | if fieldNum <= 0 { |
| 1957 | return fmt.Errorf("proto: ResourceRule: illegal tag %d (wire type %d)", fieldNum, wire) |
| 1958 | } |
| 1959 | switch fieldNum { |
| 1960 | case 1: |
| 1961 | if wireType != 2 { |
| 1962 | return fmt.Errorf("proto: wrong wireType = %d for field Verbs", wireType) |
| 1963 | } |
| 1964 | var stringLen uint64 |
| 1965 | for shift := uint(0); ; shift += 7 { |
| 1966 | if shift >= 64 { |
| 1967 | return ErrIntOverflowGenerated |
| 1968 | } |
| 1969 | if iNdEx >= l { |
| 1970 | return io.ErrUnexpectedEOF |
| 1971 | } |
| 1972 | b := dAtA[iNdEx] |
| 1973 | iNdEx++ |
| 1974 | stringLen |= (uint64(b) & 0x7F) << shift |
| 1975 | if b < 0x80 { |
| 1976 | break |
| 1977 | } |
| 1978 | } |
| 1979 | intStringLen := int(stringLen) |
| 1980 | if intStringLen < 0 { |
| 1981 | return ErrInvalidLengthGenerated |
| 1982 | } |
| 1983 | postIndex := iNdEx + intStringLen |
| 1984 | if postIndex > l { |
| 1985 | return io.ErrUnexpectedEOF |
| 1986 | } |
| 1987 | m.Verbs = append(m.Verbs, string(dAtA[iNdEx:postIndex])) |
| 1988 | iNdEx = postIndex |
| 1989 | case 2: |
| 1990 | if wireType != 2 { |
| 1991 | return fmt.Errorf("proto: wrong wireType = %d for field APIGroups", wireType) |
| 1992 | } |
| 1993 | var stringLen uint64 |
| 1994 | for shift := uint(0); ; shift += 7 { |
| 1995 | if shift >= 64 { |
| 1996 | return ErrIntOverflowGenerated |
| 1997 | } |
| 1998 | if iNdEx >= l { |
| 1999 | return io.ErrUnexpectedEOF |
| 2000 | } |
| 2001 | b := dAtA[iNdEx] |
| 2002 | iNdEx++ |
| 2003 | stringLen |= (uint64(b) & 0x7F) << shift |
| 2004 | if b < 0x80 { |
| 2005 | break |
| 2006 | } |
| 2007 | } |
| 2008 | intStringLen := int(stringLen) |
| 2009 | if intStringLen < 0 { |
| 2010 | return ErrInvalidLengthGenerated |
| 2011 | } |
| 2012 | postIndex := iNdEx + intStringLen |
| 2013 | if postIndex > l { |
| 2014 | return io.ErrUnexpectedEOF |
| 2015 | } |
| 2016 | m.APIGroups = append(m.APIGroups, string(dAtA[iNdEx:postIndex])) |
| 2017 | iNdEx = postIndex |
| 2018 | case 3: |
| 2019 | if wireType != 2 { |
| 2020 | return fmt.Errorf("proto: wrong wireType = %d for field Resources", wireType) |
| 2021 | } |
| 2022 | var stringLen uint64 |
| 2023 | for shift := uint(0); ; shift += 7 { |
| 2024 | if shift >= 64 { |
| 2025 | return ErrIntOverflowGenerated |
| 2026 | } |
| 2027 | if iNdEx >= l { |
| 2028 | return io.ErrUnexpectedEOF |
| 2029 | } |
| 2030 | b := dAtA[iNdEx] |
| 2031 | iNdEx++ |
| 2032 | stringLen |= (uint64(b) & 0x7F) << shift |
| 2033 | if b < 0x80 { |
| 2034 | break |
| 2035 | } |
| 2036 | } |
| 2037 | intStringLen := int(stringLen) |
| 2038 | if intStringLen < 0 { |
| 2039 | return ErrInvalidLengthGenerated |
| 2040 | } |
| 2041 | postIndex := iNdEx + intStringLen |
| 2042 | if postIndex > l { |
| 2043 | return io.ErrUnexpectedEOF |
| 2044 | } |
| 2045 | m.Resources = append(m.Resources, string(dAtA[iNdEx:postIndex])) |
| 2046 | iNdEx = postIndex |
| 2047 | case 4: |
| 2048 | if wireType != 2 { |
| 2049 | return fmt.Errorf("proto: wrong wireType = %d for field ResourceNames", wireType) |
| 2050 | } |
| 2051 | var stringLen uint64 |
| 2052 | for shift := uint(0); ; shift += 7 { |
| 2053 | if shift >= 64 { |
| 2054 | return ErrIntOverflowGenerated |
| 2055 | } |
| 2056 | if iNdEx >= l { |
| 2057 | return io.ErrUnexpectedEOF |
| 2058 | } |
| 2059 | b := dAtA[iNdEx] |
| 2060 | iNdEx++ |
| 2061 | stringLen |= (uint64(b) & 0x7F) << shift |
| 2062 | if b < 0x80 { |
| 2063 | break |
| 2064 | } |
| 2065 | } |
| 2066 | intStringLen := int(stringLen) |
| 2067 | if intStringLen < 0 { |
| 2068 | return ErrInvalidLengthGenerated |
| 2069 | } |
| 2070 | postIndex := iNdEx + intStringLen |
| 2071 | if postIndex > l { |
| 2072 | return io.ErrUnexpectedEOF |
| 2073 | } |
| 2074 | m.ResourceNames = append(m.ResourceNames, string(dAtA[iNdEx:postIndex])) |
| 2075 | iNdEx = postIndex |
| 2076 | default: |
| 2077 | iNdEx = preIndex |
| 2078 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 2079 | if err != nil { |
| 2080 | return err |
| 2081 | } |
| 2082 | if skippy < 0 { |
| 2083 | return ErrInvalidLengthGenerated |
| 2084 | } |
| 2085 | if (iNdEx + skippy) > l { |
| 2086 | return io.ErrUnexpectedEOF |
| 2087 | } |
| 2088 | iNdEx += skippy |
| 2089 | } |
| 2090 | } |
| 2091 | |
| 2092 | if iNdEx > l { |
| 2093 | return io.ErrUnexpectedEOF |
| 2094 | } |
| 2095 | return nil |
| 2096 | } |
| 2097 | func (m *SelfSubjectAccessReview) Unmarshal(dAtA []byte) error { |
| 2098 | l := len(dAtA) |
| 2099 | iNdEx := 0 |
| 2100 | for iNdEx < l { |
| 2101 | preIndex := iNdEx |
| 2102 | var wire uint64 |
| 2103 | for shift := uint(0); ; shift += 7 { |
| 2104 | if shift >= 64 { |
| 2105 | return ErrIntOverflowGenerated |
| 2106 | } |
| 2107 | if iNdEx >= l { |
| 2108 | return io.ErrUnexpectedEOF |
| 2109 | } |
| 2110 | b := dAtA[iNdEx] |
| 2111 | iNdEx++ |
| 2112 | wire |= (uint64(b) & 0x7F) << shift |
| 2113 | if b < 0x80 { |
| 2114 | break |
| 2115 | } |
| 2116 | } |
| 2117 | fieldNum := int32(wire >> 3) |
| 2118 | wireType := int(wire & 0x7) |
| 2119 | if wireType == 4 { |
| 2120 | return fmt.Errorf("proto: SelfSubjectAccessReview: wiretype end group for non-group") |
| 2121 | } |
| 2122 | if fieldNum <= 0 { |
| 2123 | return fmt.Errorf("proto: SelfSubjectAccessReview: illegal tag %d (wire type %d)", fieldNum, wire) |
| 2124 | } |
| 2125 | switch fieldNum { |
| 2126 | case 1: |
| 2127 | if wireType != 2 { |
| 2128 | return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) |
| 2129 | } |
| 2130 | var msglen int |
| 2131 | for shift := uint(0); ; shift += 7 { |
| 2132 | if shift >= 64 { |
| 2133 | return ErrIntOverflowGenerated |
| 2134 | } |
| 2135 | if iNdEx >= l { |
| 2136 | return io.ErrUnexpectedEOF |
| 2137 | } |
| 2138 | b := dAtA[iNdEx] |
| 2139 | iNdEx++ |
| 2140 | msglen |= (int(b) & 0x7F) << shift |
| 2141 | if b < 0x80 { |
| 2142 | break |
| 2143 | } |
| 2144 | } |
| 2145 | if msglen < 0 { |
| 2146 | return ErrInvalidLengthGenerated |
| 2147 | } |
| 2148 | postIndex := iNdEx + msglen |
| 2149 | if postIndex > l { |
| 2150 | return io.ErrUnexpectedEOF |
| 2151 | } |
| 2152 | if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 2153 | return err |
| 2154 | } |
| 2155 | iNdEx = postIndex |
| 2156 | case 2: |
| 2157 | if wireType != 2 { |
| 2158 | return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) |
| 2159 | } |
| 2160 | var msglen int |
| 2161 | for shift := uint(0); ; shift += 7 { |
| 2162 | if shift >= 64 { |
| 2163 | return ErrIntOverflowGenerated |
| 2164 | } |
| 2165 | if iNdEx >= l { |
| 2166 | return io.ErrUnexpectedEOF |
| 2167 | } |
| 2168 | b := dAtA[iNdEx] |
| 2169 | iNdEx++ |
| 2170 | msglen |= (int(b) & 0x7F) << shift |
| 2171 | if b < 0x80 { |
| 2172 | break |
| 2173 | } |
| 2174 | } |
| 2175 | if msglen < 0 { |
| 2176 | return ErrInvalidLengthGenerated |
| 2177 | } |
| 2178 | postIndex := iNdEx + msglen |
| 2179 | if postIndex > l { |
| 2180 | return io.ErrUnexpectedEOF |
| 2181 | } |
| 2182 | if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 2183 | return err |
| 2184 | } |
| 2185 | iNdEx = postIndex |
| 2186 | case 3: |
| 2187 | if wireType != 2 { |
| 2188 | return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) |
| 2189 | } |
| 2190 | var msglen int |
| 2191 | for shift := uint(0); ; shift += 7 { |
| 2192 | if shift >= 64 { |
| 2193 | return ErrIntOverflowGenerated |
| 2194 | } |
| 2195 | if iNdEx >= l { |
| 2196 | return io.ErrUnexpectedEOF |
| 2197 | } |
| 2198 | b := dAtA[iNdEx] |
| 2199 | iNdEx++ |
| 2200 | msglen |= (int(b) & 0x7F) << shift |
| 2201 | if b < 0x80 { |
| 2202 | break |
| 2203 | } |
| 2204 | } |
| 2205 | if msglen < 0 { |
| 2206 | return ErrInvalidLengthGenerated |
| 2207 | } |
| 2208 | postIndex := iNdEx + msglen |
| 2209 | if postIndex > l { |
| 2210 | return io.ErrUnexpectedEOF |
| 2211 | } |
| 2212 | if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 2213 | return err |
| 2214 | } |
| 2215 | iNdEx = postIndex |
| 2216 | default: |
| 2217 | iNdEx = preIndex |
| 2218 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 2219 | if err != nil { |
| 2220 | return err |
| 2221 | } |
| 2222 | if skippy < 0 { |
| 2223 | return ErrInvalidLengthGenerated |
| 2224 | } |
| 2225 | if (iNdEx + skippy) > l { |
| 2226 | return io.ErrUnexpectedEOF |
| 2227 | } |
| 2228 | iNdEx += skippy |
| 2229 | } |
| 2230 | } |
| 2231 | |
| 2232 | if iNdEx > l { |
| 2233 | return io.ErrUnexpectedEOF |
| 2234 | } |
| 2235 | return nil |
| 2236 | } |
| 2237 | func (m *SelfSubjectAccessReviewSpec) Unmarshal(dAtA []byte) error { |
| 2238 | l := len(dAtA) |
| 2239 | iNdEx := 0 |
| 2240 | for iNdEx < l { |
| 2241 | preIndex := iNdEx |
| 2242 | var wire uint64 |
| 2243 | for shift := uint(0); ; shift += 7 { |
| 2244 | if shift >= 64 { |
| 2245 | return ErrIntOverflowGenerated |
| 2246 | } |
| 2247 | if iNdEx >= l { |
| 2248 | return io.ErrUnexpectedEOF |
| 2249 | } |
| 2250 | b := dAtA[iNdEx] |
| 2251 | iNdEx++ |
| 2252 | wire |= (uint64(b) & 0x7F) << shift |
| 2253 | if b < 0x80 { |
| 2254 | break |
| 2255 | } |
| 2256 | } |
| 2257 | fieldNum := int32(wire >> 3) |
| 2258 | wireType := int(wire & 0x7) |
| 2259 | if wireType == 4 { |
| 2260 | return fmt.Errorf("proto: SelfSubjectAccessReviewSpec: wiretype end group for non-group") |
| 2261 | } |
| 2262 | if fieldNum <= 0 { |
| 2263 | return fmt.Errorf("proto: SelfSubjectAccessReviewSpec: illegal tag %d (wire type %d)", fieldNum, wire) |
| 2264 | } |
| 2265 | switch fieldNum { |
| 2266 | case 1: |
| 2267 | if wireType != 2 { |
| 2268 | return fmt.Errorf("proto: wrong wireType = %d for field ResourceAttributes", wireType) |
| 2269 | } |
| 2270 | var msglen int |
| 2271 | for shift := uint(0); ; shift += 7 { |
| 2272 | if shift >= 64 { |
| 2273 | return ErrIntOverflowGenerated |
| 2274 | } |
| 2275 | if iNdEx >= l { |
| 2276 | return io.ErrUnexpectedEOF |
| 2277 | } |
| 2278 | b := dAtA[iNdEx] |
| 2279 | iNdEx++ |
| 2280 | msglen |= (int(b) & 0x7F) << shift |
| 2281 | if b < 0x80 { |
| 2282 | break |
| 2283 | } |
| 2284 | } |
| 2285 | if msglen < 0 { |
| 2286 | return ErrInvalidLengthGenerated |
| 2287 | } |
| 2288 | postIndex := iNdEx + msglen |
| 2289 | if postIndex > l { |
| 2290 | return io.ErrUnexpectedEOF |
| 2291 | } |
| 2292 | if m.ResourceAttributes == nil { |
| 2293 | m.ResourceAttributes = &ResourceAttributes{} |
| 2294 | } |
| 2295 | if err := m.ResourceAttributes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 2296 | return err |
| 2297 | } |
| 2298 | iNdEx = postIndex |
| 2299 | case 2: |
| 2300 | if wireType != 2 { |
| 2301 | return fmt.Errorf("proto: wrong wireType = %d for field NonResourceAttributes", wireType) |
| 2302 | } |
| 2303 | var msglen int |
| 2304 | for shift := uint(0); ; shift += 7 { |
| 2305 | if shift >= 64 { |
| 2306 | return ErrIntOverflowGenerated |
| 2307 | } |
| 2308 | if iNdEx >= l { |
| 2309 | return io.ErrUnexpectedEOF |
| 2310 | } |
| 2311 | b := dAtA[iNdEx] |
| 2312 | iNdEx++ |
| 2313 | msglen |= (int(b) & 0x7F) << shift |
| 2314 | if b < 0x80 { |
| 2315 | break |
| 2316 | } |
| 2317 | } |
| 2318 | if msglen < 0 { |
| 2319 | return ErrInvalidLengthGenerated |
| 2320 | } |
| 2321 | postIndex := iNdEx + msglen |
| 2322 | if postIndex > l { |
| 2323 | return io.ErrUnexpectedEOF |
| 2324 | } |
| 2325 | if m.NonResourceAttributes == nil { |
| 2326 | m.NonResourceAttributes = &NonResourceAttributes{} |
| 2327 | } |
| 2328 | if err := m.NonResourceAttributes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 2329 | return err |
| 2330 | } |
| 2331 | iNdEx = postIndex |
| 2332 | default: |
| 2333 | iNdEx = preIndex |
| 2334 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 2335 | if err != nil { |
| 2336 | return err |
| 2337 | } |
| 2338 | if skippy < 0 { |
| 2339 | return ErrInvalidLengthGenerated |
| 2340 | } |
| 2341 | if (iNdEx + skippy) > l { |
| 2342 | return io.ErrUnexpectedEOF |
| 2343 | } |
| 2344 | iNdEx += skippy |
| 2345 | } |
| 2346 | } |
| 2347 | |
| 2348 | if iNdEx > l { |
| 2349 | return io.ErrUnexpectedEOF |
| 2350 | } |
| 2351 | return nil |
| 2352 | } |
| 2353 | func (m *SelfSubjectRulesReview) Unmarshal(dAtA []byte) error { |
| 2354 | l := len(dAtA) |
| 2355 | iNdEx := 0 |
| 2356 | for iNdEx < l { |
| 2357 | preIndex := iNdEx |
| 2358 | var wire uint64 |
| 2359 | for shift := uint(0); ; shift += 7 { |
| 2360 | if shift >= 64 { |
| 2361 | return ErrIntOverflowGenerated |
| 2362 | } |
| 2363 | if iNdEx >= l { |
| 2364 | return io.ErrUnexpectedEOF |
| 2365 | } |
| 2366 | b := dAtA[iNdEx] |
| 2367 | iNdEx++ |
| 2368 | wire |= (uint64(b) & 0x7F) << shift |
| 2369 | if b < 0x80 { |
| 2370 | break |
| 2371 | } |
| 2372 | } |
| 2373 | fieldNum := int32(wire >> 3) |
| 2374 | wireType := int(wire & 0x7) |
| 2375 | if wireType == 4 { |
| 2376 | return fmt.Errorf("proto: SelfSubjectRulesReview: wiretype end group for non-group") |
| 2377 | } |
| 2378 | if fieldNum <= 0 { |
| 2379 | return fmt.Errorf("proto: SelfSubjectRulesReview: illegal tag %d (wire type %d)", fieldNum, wire) |
| 2380 | } |
| 2381 | switch fieldNum { |
| 2382 | case 1: |
| 2383 | if wireType != 2 { |
| 2384 | return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) |
| 2385 | } |
| 2386 | var msglen int |
| 2387 | for shift := uint(0); ; shift += 7 { |
| 2388 | if shift >= 64 { |
| 2389 | return ErrIntOverflowGenerated |
| 2390 | } |
| 2391 | if iNdEx >= l { |
| 2392 | return io.ErrUnexpectedEOF |
| 2393 | } |
| 2394 | b := dAtA[iNdEx] |
| 2395 | iNdEx++ |
| 2396 | msglen |= (int(b) & 0x7F) << shift |
| 2397 | if b < 0x80 { |
| 2398 | break |
| 2399 | } |
| 2400 | } |
| 2401 | if msglen < 0 { |
| 2402 | return ErrInvalidLengthGenerated |
| 2403 | } |
| 2404 | postIndex := iNdEx + msglen |
| 2405 | if postIndex > l { |
| 2406 | return io.ErrUnexpectedEOF |
| 2407 | } |
| 2408 | if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 2409 | return err |
| 2410 | } |
| 2411 | iNdEx = postIndex |
| 2412 | case 2: |
| 2413 | if wireType != 2 { |
| 2414 | return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) |
| 2415 | } |
| 2416 | var msglen int |
| 2417 | for shift := uint(0); ; shift += 7 { |
| 2418 | if shift >= 64 { |
| 2419 | return ErrIntOverflowGenerated |
| 2420 | } |
| 2421 | if iNdEx >= l { |
| 2422 | return io.ErrUnexpectedEOF |
| 2423 | } |
| 2424 | b := dAtA[iNdEx] |
| 2425 | iNdEx++ |
| 2426 | msglen |= (int(b) & 0x7F) << shift |
| 2427 | if b < 0x80 { |
| 2428 | break |
| 2429 | } |
| 2430 | } |
| 2431 | if msglen < 0 { |
| 2432 | return ErrInvalidLengthGenerated |
| 2433 | } |
| 2434 | postIndex := iNdEx + msglen |
| 2435 | if postIndex > l { |
| 2436 | return io.ErrUnexpectedEOF |
| 2437 | } |
| 2438 | if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 2439 | return err |
| 2440 | } |
| 2441 | iNdEx = postIndex |
| 2442 | case 3: |
| 2443 | if wireType != 2 { |
| 2444 | return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) |
| 2445 | } |
| 2446 | var msglen int |
| 2447 | for shift := uint(0); ; shift += 7 { |
| 2448 | if shift >= 64 { |
| 2449 | return ErrIntOverflowGenerated |
| 2450 | } |
| 2451 | if iNdEx >= l { |
| 2452 | return io.ErrUnexpectedEOF |
| 2453 | } |
| 2454 | b := dAtA[iNdEx] |
| 2455 | iNdEx++ |
| 2456 | msglen |= (int(b) & 0x7F) << shift |
| 2457 | if b < 0x80 { |
| 2458 | break |
| 2459 | } |
| 2460 | } |
| 2461 | if msglen < 0 { |
| 2462 | return ErrInvalidLengthGenerated |
| 2463 | } |
| 2464 | postIndex := iNdEx + msglen |
| 2465 | if postIndex > l { |
| 2466 | return io.ErrUnexpectedEOF |
| 2467 | } |
| 2468 | if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 2469 | return err |
| 2470 | } |
| 2471 | iNdEx = postIndex |
| 2472 | default: |
| 2473 | iNdEx = preIndex |
| 2474 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 2475 | if err != nil { |
| 2476 | return err |
| 2477 | } |
| 2478 | if skippy < 0 { |
| 2479 | return ErrInvalidLengthGenerated |
| 2480 | } |
| 2481 | if (iNdEx + skippy) > l { |
| 2482 | return io.ErrUnexpectedEOF |
| 2483 | } |
| 2484 | iNdEx += skippy |
| 2485 | } |
| 2486 | } |
| 2487 | |
| 2488 | if iNdEx > l { |
| 2489 | return io.ErrUnexpectedEOF |
| 2490 | } |
| 2491 | return nil |
| 2492 | } |
| 2493 | func (m *SelfSubjectRulesReviewSpec) Unmarshal(dAtA []byte) error { |
| 2494 | l := len(dAtA) |
| 2495 | iNdEx := 0 |
| 2496 | for iNdEx < l { |
| 2497 | preIndex := iNdEx |
| 2498 | var wire uint64 |
| 2499 | for shift := uint(0); ; shift += 7 { |
| 2500 | if shift >= 64 { |
| 2501 | return ErrIntOverflowGenerated |
| 2502 | } |
| 2503 | if iNdEx >= l { |
| 2504 | return io.ErrUnexpectedEOF |
| 2505 | } |
| 2506 | b := dAtA[iNdEx] |
| 2507 | iNdEx++ |
| 2508 | wire |= (uint64(b) & 0x7F) << shift |
| 2509 | if b < 0x80 { |
| 2510 | break |
| 2511 | } |
| 2512 | } |
| 2513 | fieldNum := int32(wire >> 3) |
| 2514 | wireType := int(wire & 0x7) |
| 2515 | if wireType == 4 { |
| 2516 | return fmt.Errorf("proto: SelfSubjectRulesReviewSpec: wiretype end group for non-group") |
| 2517 | } |
| 2518 | if fieldNum <= 0 { |
| 2519 | return fmt.Errorf("proto: SelfSubjectRulesReviewSpec: illegal tag %d (wire type %d)", fieldNum, wire) |
| 2520 | } |
| 2521 | switch fieldNum { |
| 2522 | case 1: |
| 2523 | if wireType != 2 { |
| 2524 | return fmt.Errorf("proto: wrong wireType = %d for field Namespace", wireType) |
| 2525 | } |
| 2526 | var stringLen uint64 |
| 2527 | for shift := uint(0); ; shift += 7 { |
| 2528 | if shift >= 64 { |
| 2529 | return ErrIntOverflowGenerated |
| 2530 | } |
| 2531 | if iNdEx >= l { |
| 2532 | return io.ErrUnexpectedEOF |
| 2533 | } |
| 2534 | b := dAtA[iNdEx] |
| 2535 | iNdEx++ |
| 2536 | stringLen |= (uint64(b) & 0x7F) << shift |
| 2537 | if b < 0x80 { |
| 2538 | break |
| 2539 | } |
| 2540 | } |
| 2541 | intStringLen := int(stringLen) |
| 2542 | if intStringLen < 0 { |
| 2543 | return ErrInvalidLengthGenerated |
| 2544 | } |
| 2545 | postIndex := iNdEx + intStringLen |
| 2546 | if postIndex > l { |
| 2547 | return io.ErrUnexpectedEOF |
| 2548 | } |
| 2549 | m.Namespace = string(dAtA[iNdEx:postIndex]) |
| 2550 | iNdEx = postIndex |
| 2551 | default: |
| 2552 | iNdEx = preIndex |
| 2553 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 2554 | if err != nil { |
| 2555 | return err |
| 2556 | } |
| 2557 | if skippy < 0 { |
| 2558 | return ErrInvalidLengthGenerated |
| 2559 | } |
| 2560 | if (iNdEx + skippy) > l { |
| 2561 | return io.ErrUnexpectedEOF |
| 2562 | } |
| 2563 | iNdEx += skippy |
| 2564 | } |
| 2565 | } |
| 2566 | |
| 2567 | if iNdEx > l { |
| 2568 | return io.ErrUnexpectedEOF |
| 2569 | } |
| 2570 | return nil |
| 2571 | } |
| 2572 | func (m *SubjectAccessReview) Unmarshal(dAtA []byte) error { |
| 2573 | l := len(dAtA) |
| 2574 | iNdEx := 0 |
| 2575 | for iNdEx < l { |
| 2576 | preIndex := iNdEx |
| 2577 | var wire uint64 |
| 2578 | for shift := uint(0); ; shift += 7 { |
| 2579 | if shift >= 64 { |
| 2580 | return ErrIntOverflowGenerated |
| 2581 | } |
| 2582 | if iNdEx >= l { |
| 2583 | return io.ErrUnexpectedEOF |
| 2584 | } |
| 2585 | b := dAtA[iNdEx] |
| 2586 | iNdEx++ |
| 2587 | wire |= (uint64(b) & 0x7F) << shift |
| 2588 | if b < 0x80 { |
| 2589 | break |
| 2590 | } |
| 2591 | } |
| 2592 | fieldNum := int32(wire >> 3) |
| 2593 | wireType := int(wire & 0x7) |
| 2594 | if wireType == 4 { |
| 2595 | return fmt.Errorf("proto: SubjectAccessReview: wiretype end group for non-group") |
| 2596 | } |
| 2597 | if fieldNum <= 0 { |
| 2598 | return fmt.Errorf("proto: SubjectAccessReview: illegal tag %d (wire type %d)", fieldNum, wire) |
| 2599 | } |
| 2600 | switch fieldNum { |
| 2601 | case 1: |
| 2602 | if wireType != 2 { |
| 2603 | return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) |
| 2604 | } |
| 2605 | var msglen int |
| 2606 | for shift := uint(0); ; shift += 7 { |
| 2607 | if shift >= 64 { |
| 2608 | return ErrIntOverflowGenerated |
| 2609 | } |
| 2610 | if iNdEx >= l { |
| 2611 | return io.ErrUnexpectedEOF |
| 2612 | } |
| 2613 | b := dAtA[iNdEx] |
| 2614 | iNdEx++ |
| 2615 | msglen |= (int(b) & 0x7F) << shift |
| 2616 | if b < 0x80 { |
| 2617 | break |
| 2618 | } |
| 2619 | } |
| 2620 | if msglen < 0 { |
| 2621 | return ErrInvalidLengthGenerated |
| 2622 | } |
| 2623 | postIndex := iNdEx + msglen |
| 2624 | if postIndex > l { |
| 2625 | return io.ErrUnexpectedEOF |
| 2626 | } |
| 2627 | if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 2628 | return err |
| 2629 | } |
| 2630 | iNdEx = postIndex |
| 2631 | case 2: |
| 2632 | if wireType != 2 { |
| 2633 | return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) |
| 2634 | } |
| 2635 | var msglen int |
| 2636 | for shift := uint(0); ; shift += 7 { |
| 2637 | if shift >= 64 { |
| 2638 | return ErrIntOverflowGenerated |
| 2639 | } |
| 2640 | if iNdEx >= l { |
| 2641 | return io.ErrUnexpectedEOF |
| 2642 | } |
| 2643 | b := dAtA[iNdEx] |
| 2644 | iNdEx++ |
| 2645 | msglen |= (int(b) & 0x7F) << shift |
| 2646 | if b < 0x80 { |
| 2647 | break |
| 2648 | } |
| 2649 | } |
| 2650 | if msglen < 0 { |
| 2651 | return ErrInvalidLengthGenerated |
| 2652 | } |
| 2653 | postIndex := iNdEx + msglen |
| 2654 | if postIndex > l { |
| 2655 | return io.ErrUnexpectedEOF |
| 2656 | } |
| 2657 | if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 2658 | return err |
| 2659 | } |
| 2660 | iNdEx = postIndex |
| 2661 | case 3: |
| 2662 | if wireType != 2 { |
| 2663 | return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) |
| 2664 | } |
| 2665 | var msglen int |
| 2666 | for shift := uint(0); ; shift += 7 { |
| 2667 | if shift >= 64 { |
| 2668 | return ErrIntOverflowGenerated |
| 2669 | } |
| 2670 | if iNdEx >= l { |
| 2671 | return io.ErrUnexpectedEOF |
| 2672 | } |
| 2673 | b := dAtA[iNdEx] |
| 2674 | iNdEx++ |
| 2675 | msglen |= (int(b) & 0x7F) << shift |
| 2676 | if b < 0x80 { |
| 2677 | break |
| 2678 | } |
| 2679 | } |
| 2680 | if msglen < 0 { |
| 2681 | return ErrInvalidLengthGenerated |
| 2682 | } |
| 2683 | postIndex := iNdEx + msglen |
| 2684 | if postIndex > l { |
| 2685 | return io.ErrUnexpectedEOF |
| 2686 | } |
| 2687 | if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 2688 | return err |
| 2689 | } |
| 2690 | iNdEx = postIndex |
| 2691 | default: |
| 2692 | iNdEx = preIndex |
| 2693 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 2694 | if err != nil { |
| 2695 | return err |
| 2696 | } |
| 2697 | if skippy < 0 { |
| 2698 | return ErrInvalidLengthGenerated |
| 2699 | } |
| 2700 | if (iNdEx + skippy) > l { |
| 2701 | return io.ErrUnexpectedEOF |
| 2702 | } |
| 2703 | iNdEx += skippy |
| 2704 | } |
| 2705 | } |
| 2706 | |
| 2707 | if iNdEx > l { |
| 2708 | return io.ErrUnexpectedEOF |
| 2709 | } |
| 2710 | return nil |
| 2711 | } |
| 2712 | func (m *SubjectAccessReviewSpec) Unmarshal(dAtA []byte) error { |
| 2713 | l := len(dAtA) |
| 2714 | iNdEx := 0 |
| 2715 | for iNdEx < l { |
| 2716 | preIndex := iNdEx |
| 2717 | var wire uint64 |
| 2718 | for shift := uint(0); ; shift += 7 { |
| 2719 | if shift >= 64 { |
| 2720 | return ErrIntOverflowGenerated |
| 2721 | } |
| 2722 | if iNdEx >= l { |
| 2723 | return io.ErrUnexpectedEOF |
| 2724 | } |
| 2725 | b := dAtA[iNdEx] |
| 2726 | iNdEx++ |
| 2727 | wire |= (uint64(b) & 0x7F) << shift |
| 2728 | if b < 0x80 { |
| 2729 | break |
| 2730 | } |
| 2731 | } |
| 2732 | fieldNum := int32(wire >> 3) |
| 2733 | wireType := int(wire & 0x7) |
| 2734 | if wireType == 4 { |
| 2735 | return fmt.Errorf("proto: SubjectAccessReviewSpec: wiretype end group for non-group") |
| 2736 | } |
| 2737 | if fieldNum <= 0 { |
| 2738 | return fmt.Errorf("proto: SubjectAccessReviewSpec: illegal tag %d (wire type %d)", fieldNum, wire) |
| 2739 | } |
| 2740 | switch fieldNum { |
| 2741 | case 1: |
| 2742 | if wireType != 2 { |
| 2743 | return fmt.Errorf("proto: wrong wireType = %d for field ResourceAttributes", wireType) |
| 2744 | } |
| 2745 | var msglen int |
| 2746 | for shift := uint(0); ; shift += 7 { |
| 2747 | if shift >= 64 { |
| 2748 | return ErrIntOverflowGenerated |
| 2749 | } |
| 2750 | if iNdEx >= l { |
| 2751 | return io.ErrUnexpectedEOF |
| 2752 | } |
| 2753 | b := dAtA[iNdEx] |
| 2754 | iNdEx++ |
| 2755 | msglen |= (int(b) & 0x7F) << shift |
| 2756 | if b < 0x80 { |
| 2757 | break |
| 2758 | } |
| 2759 | } |
| 2760 | if msglen < 0 { |
| 2761 | return ErrInvalidLengthGenerated |
| 2762 | } |
| 2763 | postIndex := iNdEx + msglen |
| 2764 | if postIndex > l { |
| 2765 | return io.ErrUnexpectedEOF |
| 2766 | } |
| 2767 | if m.ResourceAttributes == nil { |
| 2768 | m.ResourceAttributes = &ResourceAttributes{} |
| 2769 | } |
| 2770 | if err := m.ResourceAttributes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 2771 | return err |
| 2772 | } |
| 2773 | iNdEx = postIndex |
| 2774 | case 2: |
| 2775 | if wireType != 2 { |
| 2776 | return fmt.Errorf("proto: wrong wireType = %d for field NonResourceAttributes", wireType) |
| 2777 | } |
| 2778 | var msglen int |
| 2779 | for shift := uint(0); ; shift += 7 { |
| 2780 | if shift >= 64 { |
| 2781 | return ErrIntOverflowGenerated |
| 2782 | } |
| 2783 | if iNdEx >= l { |
| 2784 | return io.ErrUnexpectedEOF |
| 2785 | } |
| 2786 | b := dAtA[iNdEx] |
| 2787 | iNdEx++ |
| 2788 | msglen |= (int(b) & 0x7F) << shift |
| 2789 | if b < 0x80 { |
| 2790 | break |
| 2791 | } |
| 2792 | } |
| 2793 | if msglen < 0 { |
| 2794 | return ErrInvalidLengthGenerated |
| 2795 | } |
| 2796 | postIndex := iNdEx + msglen |
| 2797 | if postIndex > l { |
| 2798 | return io.ErrUnexpectedEOF |
| 2799 | } |
| 2800 | if m.NonResourceAttributes == nil { |
| 2801 | m.NonResourceAttributes = &NonResourceAttributes{} |
| 2802 | } |
| 2803 | if err := m.NonResourceAttributes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 2804 | return err |
| 2805 | } |
| 2806 | iNdEx = postIndex |
| 2807 | case 3: |
| 2808 | if wireType != 2 { |
| 2809 | return fmt.Errorf("proto: wrong wireType = %d for field User", wireType) |
| 2810 | } |
| 2811 | var stringLen uint64 |
| 2812 | for shift := uint(0); ; shift += 7 { |
| 2813 | if shift >= 64 { |
| 2814 | return ErrIntOverflowGenerated |
| 2815 | } |
| 2816 | if iNdEx >= l { |
| 2817 | return io.ErrUnexpectedEOF |
| 2818 | } |
| 2819 | b := dAtA[iNdEx] |
| 2820 | iNdEx++ |
| 2821 | stringLen |= (uint64(b) & 0x7F) << shift |
| 2822 | if b < 0x80 { |
| 2823 | break |
| 2824 | } |
| 2825 | } |
| 2826 | intStringLen := int(stringLen) |
| 2827 | if intStringLen < 0 { |
| 2828 | return ErrInvalidLengthGenerated |
| 2829 | } |
| 2830 | postIndex := iNdEx + intStringLen |
| 2831 | if postIndex > l { |
| 2832 | return io.ErrUnexpectedEOF |
| 2833 | } |
| 2834 | m.User = string(dAtA[iNdEx:postIndex]) |
| 2835 | iNdEx = postIndex |
| 2836 | case 4: |
| 2837 | if wireType != 2 { |
| 2838 | return fmt.Errorf("proto: wrong wireType = %d for field Groups", wireType) |
| 2839 | } |
| 2840 | var stringLen uint64 |
| 2841 | for shift := uint(0); ; shift += 7 { |
| 2842 | if shift >= 64 { |
| 2843 | return ErrIntOverflowGenerated |
| 2844 | } |
| 2845 | if iNdEx >= l { |
| 2846 | return io.ErrUnexpectedEOF |
| 2847 | } |
| 2848 | b := dAtA[iNdEx] |
| 2849 | iNdEx++ |
| 2850 | stringLen |= (uint64(b) & 0x7F) << shift |
| 2851 | if b < 0x80 { |
| 2852 | break |
| 2853 | } |
| 2854 | } |
| 2855 | intStringLen := int(stringLen) |
| 2856 | if intStringLen < 0 { |
| 2857 | return ErrInvalidLengthGenerated |
| 2858 | } |
| 2859 | postIndex := iNdEx + intStringLen |
| 2860 | if postIndex > l { |
| 2861 | return io.ErrUnexpectedEOF |
| 2862 | } |
| 2863 | m.Groups = append(m.Groups, string(dAtA[iNdEx:postIndex])) |
| 2864 | iNdEx = postIndex |
| 2865 | case 5: |
| 2866 | if wireType != 2 { |
| 2867 | return fmt.Errorf("proto: wrong wireType = %d for field Extra", wireType) |
| 2868 | } |
| 2869 | var msglen int |
| 2870 | for shift := uint(0); ; shift += 7 { |
| 2871 | if shift >= 64 { |
| 2872 | return ErrIntOverflowGenerated |
| 2873 | } |
| 2874 | if iNdEx >= l { |
| 2875 | return io.ErrUnexpectedEOF |
| 2876 | } |
| 2877 | b := dAtA[iNdEx] |
| 2878 | iNdEx++ |
| 2879 | msglen |= (int(b) & 0x7F) << shift |
| 2880 | if b < 0x80 { |
| 2881 | break |
| 2882 | } |
| 2883 | } |
| 2884 | if msglen < 0 { |
| 2885 | return ErrInvalidLengthGenerated |
| 2886 | } |
| 2887 | postIndex := iNdEx + msglen |
| 2888 | if postIndex > l { |
| 2889 | return io.ErrUnexpectedEOF |
| 2890 | } |
| 2891 | var keykey uint64 |
| 2892 | for shift := uint(0); ; shift += 7 { |
| 2893 | if shift >= 64 { |
| 2894 | return ErrIntOverflowGenerated |
| 2895 | } |
| 2896 | if iNdEx >= l { |
| 2897 | return io.ErrUnexpectedEOF |
| 2898 | } |
| 2899 | b := dAtA[iNdEx] |
| 2900 | iNdEx++ |
| 2901 | keykey |= (uint64(b) & 0x7F) << shift |
| 2902 | if b < 0x80 { |
| 2903 | break |
| 2904 | } |
| 2905 | } |
| 2906 | var stringLenmapkey uint64 |
| 2907 | for shift := uint(0); ; shift += 7 { |
| 2908 | if shift >= 64 { |
| 2909 | return ErrIntOverflowGenerated |
| 2910 | } |
| 2911 | if iNdEx >= l { |
| 2912 | return io.ErrUnexpectedEOF |
| 2913 | } |
| 2914 | b := dAtA[iNdEx] |
| 2915 | iNdEx++ |
| 2916 | stringLenmapkey |= (uint64(b) & 0x7F) << shift |
| 2917 | if b < 0x80 { |
| 2918 | break |
| 2919 | } |
| 2920 | } |
| 2921 | intStringLenmapkey := int(stringLenmapkey) |
| 2922 | if intStringLenmapkey < 0 { |
| 2923 | return ErrInvalidLengthGenerated |
| 2924 | } |
| 2925 | postStringIndexmapkey := iNdEx + intStringLenmapkey |
| 2926 | if postStringIndexmapkey > l { |
| 2927 | return io.ErrUnexpectedEOF |
| 2928 | } |
| 2929 | mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) |
| 2930 | iNdEx = postStringIndexmapkey |
| 2931 | if m.Extra == nil { |
| 2932 | m.Extra = make(map[string]ExtraValue) |
| 2933 | } |
| 2934 | if iNdEx < postIndex { |
| 2935 | var valuekey uint64 |
| 2936 | for shift := uint(0); ; shift += 7 { |
| 2937 | if shift >= 64 { |
| 2938 | return ErrIntOverflowGenerated |
| 2939 | } |
| 2940 | if iNdEx >= l { |
| 2941 | return io.ErrUnexpectedEOF |
| 2942 | } |
| 2943 | b := dAtA[iNdEx] |
| 2944 | iNdEx++ |
| 2945 | valuekey |= (uint64(b) & 0x7F) << shift |
| 2946 | if b < 0x80 { |
| 2947 | break |
| 2948 | } |
| 2949 | } |
| 2950 | var mapmsglen int |
| 2951 | for shift := uint(0); ; shift += 7 { |
| 2952 | if shift >= 64 { |
| 2953 | return ErrIntOverflowGenerated |
| 2954 | } |
| 2955 | if iNdEx >= l { |
| 2956 | return io.ErrUnexpectedEOF |
| 2957 | } |
| 2958 | b := dAtA[iNdEx] |
| 2959 | iNdEx++ |
| 2960 | mapmsglen |= (int(b) & 0x7F) << shift |
| 2961 | if b < 0x80 { |
| 2962 | break |
| 2963 | } |
| 2964 | } |
| 2965 | if mapmsglen < 0 { |
| 2966 | return ErrInvalidLengthGenerated |
| 2967 | } |
| 2968 | postmsgIndex := iNdEx + mapmsglen |
| 2969 | if mapmsglen < 0 { |
| 2970 | return ErrInvalidLengthGenerated |
| 2971 | } |
| 2972 | if postmsgIndex > l { |
| 2973 | return io.ErrUnexpectedEOF |
| 2974 | } |
| 2975 | mapvalue := &ExtraValue{} |
| 2976 | if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { |
| 2977 | return err |
| 2978 | } |
| 2979 | iNdEx = postmsgIndex |
| 2980 | m.Extra[mapkey] = *mapvalue |
| 2981 | } else { |
| 2982 | var mapvalue ExtraValue |
| 2983 | m.Extra[mapkey] = mapvalue |
| 2984 | } |
| 2985 | iNdEx = postIndex |
| 2986 | case 6: |
| 2987 | if wireType != 2 { |
| 2988 | return fmt.Errorf("proto: wrong wireType = %d for field UID", wireType) |
| 2989 | } |
| 2990 | var stringLen uint64 |
| 2991 | for shift := uint(0); ; shift += 7 { |
| 2992 | if shift >= 64 { |
| 2993 | return ErrIntOverflowGenerated |
| 2994 | } |
| 2995 | if iNdEx >= l { |
| 2996 | return io.ErrUnexpectedEOF |
| 2997 | } |
| 2998 | b := dAtA[iNdEx] |
| 2999 | iNdEx++ |
| 3000 | stringLen |= (uint64(b) & 0x7F) << shift |
| 3001 | if b < 0x80 { |
| 3002 | break |
| 3003 | } |
| 3004 | } |
| 3005 | intStringLen := int(stringLen) |
| 3006 | if intStringLen < 0 { |
| 3007 | return ErrInvalidLengthGenerated |
| 3008 | } |
| 3009 | postIndex := iNdEx + intStringLen |
| 3010 | if postIndex > l { |
| 3011 | return io.ErrUnexpectedEOF |
| 3012 | } |
| 3013 | m.UID = string(dAtA[iNdEx:postIndex]) |
| 3014 | iNdEx = postIndex |
| 3015 | default: |
| 3016 | iNdEx = preIndex |
| 3017 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 3018 | if err != nil { |
| 3019 | return err |
| 3020 | } |
| 3021 | if skippy < 0 { |
| 3022 | return ErrInvalidLengthGenerated |
| 3023 | } |
| 3024 | if (iNdEx + skippy) > l { |
| 3025 | return io.ErrUnexpectedEOF |
| 3026 | } |
| 3027 | iNdEx += skippy |
| 3028 | } |
| 3029 | } |
| 3030 | |
| 3031 | if iNdEx > l { |
| 3032 | return io.ErrUnexpectedEOF |
| 3033 | } |
| 3034 | return nil |
| 3035 | } |
| 3036 | func (m *SubjectAccessReviewStatus) Unmarshal(dAtA []byte) error { |
| 3037 | l := len(dAtA) |
| 3038 | iNdEx := 0 |
| 3039 | for iNdEx < l { |
| 3040 | preIndex := iNdEx |
| 3041 | var wire uint64 |
| 3042 | for shift := uint(0); ; shift += 7 { |
| 3043 | if shift >= 64 { |
| 3044 | return ErrIntOverflowGenerated |
| 3045 | } |
| 3046 | if iNdEx >= l { |
| 3047 | return io.ErrUnexpectedEOF |
| 3048 | } |
| 3049 | b := dAtA[iNdEx] |
| 3050 | iNdEx++ |
| 3051 | wire |= (uint64(b) & 0x7F) << shift |
| 3052 | if b < 0x80 { |
| 3053 | break |
| 3054 | } |
| 3055 | } |
| 3056 | fieldNum := int32(wire >> 3) |
| 3057 | wireType := int(wire & 0x7) |
| 3058 | if wireType == 4 { |
| 3059 | return fmt.Errorf("proto: SubjectAccessReviewStatus: wiretype end group for non-group") |
| 3060 | } |
| 3061 | if fieldNum <= 0 { |
| 3062 | return fmt.Errorf("proto: SubjectAccessReviewStatus: illegal tag %d (wire type %d)", fieldNum, wire) |
| 3063 | } |
| 3064 | switch fieldNum { |
| 3065 | case 1: |
| 3066 | if wireType != 0 { |
| 3067 | return fmt.Errorf("proto: wrong wireType = %d for field Allowed", wireType) |
| 3068 | } |
| 3069 | var v int |
| 3070 | for shift := uint(0); ; shift += 7 { |
| 3071 | if shift >= 64 { |
| 3072 | return ErrIntOverflowGenerated |
| 3073 | } |
| 3074 | if iNdEx >= l { |
| 3075 | return io.ErrUnexpectedEOF |
| 3076 | } |
| 3077 | b := dAtA[iNdEx] |
| 3078 | iNdEx++ |
| 3079 | v |= (int(b) & 0x7F) << shift |
| 3080 | if b < 0x80 { |
| 3081 | break |
| 3082 | } |
| 3083 | } |
| 3084 | m.Allowed = bool(v != 0) |
| 3085 | case 2: |
| 3086 | if wireType != 2 { |
| 3087 | return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) |
| 3088 | } |
| 3089 | var stringLen uint64 |
| 3090 | for shift := uint(0); ; shift += 7 { |
| 3091 | if shift >= 64 { |
| 3092 | return ErrIntOverflowGenerated |
| 3093 | } |
| 3094 | if iNdEx >= l { |
| 3095 | return io.ErrUnexpectedEOF |
| 3096 | } |
| 3097 | b := dAtA[iNdEx] |
| 3098 | iNdEx++ |
| 3099 | stringLen |= (uint64(b) & 0x7F) << shift |
| 3100 | if b < 0x80 { |
| 3101 | break |
| 3102 | } |
| 3103 | } |
| 3104 | intStringLen := int(stringLen) |
| 3105 | if intStringLen < 0 { |
| 3106 | return ErrInvalidLengthGenerated |
| 3107 | } |
| 3108 | postIndex := iNdEx + intStringLen |
| 3109 | if postIndex > l { |
| 3110 | return io.ErrUnexpectedEOF |
| 3111 | } |
| 3112 | m.Reason = string(dAtA[iNdEx:postIndex]) |
| 3113 | iNdEx = postIndex |
| 3114 | case 3: |
| 3115 | if wireType != 2 { |
| 3116 | return fmt.Errorf("proto: wrong wireType = %d for field EvaluationError", wireType) |
| 3117 | } |
| 3118 | var stringLen uint64 |
| 3119 | for shift := uint(0); ; shift += 7 { |
| 3120 | if shift >= 64 { |
| 3121 | return ErrIntOverflowGenerated |
| 3122 | } |
| 3123 | if iNdEx >= l { |
| 3124 | return io.ErrUnexpectedEOF |
| 3125 | } |
| 3126 | b := dAtA[iNdEx] |
| 3127 | iNdEx++ |
| 3128 | stringLen |= (uint64(b) & 0x7F) << shift |
| 3129 | if b < 0x80 { |
| 3130 | break |
| 3131 | } |
| 3132 | } |
| 3133 | intStringLen := int(stringLen) |
| 3134 | if intStringLen < 0 { |
| 3135 | return ErrInvalidLengthGenerated |
| 3136 | } |
| 3137 | postIndex := iNdEx + intStringLen |
| 3138 | if postIndex > l { |
| 3139 | return io.ErrUnexpectedEOF |
| 3140 | } |
| 3141 | m.EvaluationError = string(dAtA[iNdEx:postIndex]) |
| 3142 | iNdEx = postIndex |
| 3143 | case 4: |
| 3144 | if wireType != 0 { |
| 3145 | return fmt.Errorf("proto: wrong wireType = %d for field Denied", wireType) |
| 3146 | } |
| 3147 | var v int |
| 3148 | for shift := uint(0); ; shift += 7 { |
| 3149 | if shift >= 64 { |
| 3150 | return ErrIntOverflowGenerated |
| 3151 | } |
| 3152 | if iNdEx >= l { |
| 3153 | return io.ErrUnexpectedEOF |
| 3154 | } |
| 3155 | b := dAtA[iNdEx] |
| 3156 | iNdEx++ |
| 3157 | v |= (int(b) & 0x7F) << shift |
| 3158 | if b < 0x80 { |
| 3159 | break |
| 3160 | } |
| 3161 | } |
| 3162 | m.Denied = bool(v != 0) |
| 3163 | default: |
| 3164 | iNdEx = preIndex |
| 3165 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 3166 | if err != nil { |
| 3167 | return err |
| 3168 | } |
| 3169 | if skippy < 0 { |
| 3170 | return ErrInvalidLengthGenerated |
| 3171 | } |
| 3172 | if (iNdEx + skippy) > l { |
| 3173 | return io.ErrUnexpectedEOF |
| 3174 | } |
| 3175 | iNdEx += skippy |
| 3176 | } |
| 3177 | } |
| 3178 | |
| 3179 | if iNdEx > l { |
| 3180 | return io.ErrUnexpectedEOF |
| 3181 | } |
| 3182 | return nil |
| 3183 | } |
| 3184 | func (m *SubjectRulesReviewStatus) Unmarshal(dAtA []byte) error { |
| 3185 | l := len(dAtA) |
| 3186 | iNdEx := 0 |
| 3187 | for iNdEx < l { |
| 3188 | preIndex := iNdEx |
| 3189 | var wire uint64 |
| 3190 | for shift := uint(0); ; shift += 7 { |
| 3191 | if shift >= 64 { |
| 3192 | return ErrIntOverflowGenerated |
| 3193 | } |
| 3194 | if iNdEx >= l { |
| 3195 | return io.ErrUnexpectedEOF |
| 3196 | } |
| 3197 | b := dAtA[iNdEx] |
| 3198 | iNdEx++ |
| 3199 | wire |= (uint64(b) & 0x7F) << shift |
| 3200 | if b < 0x80 { |
| 3201 | break |
| 3202 | } |
| 3203 | } |
| 3204 | fieldNum := int32(wire >> 3) |
| 3205 | wireType := int(wire & 0x7) |
| 3206 | if wireType == 4 { |
| 3207 | return fmt.Errorf("proto: SubjectRulesReviewStatus: wiretype end group for non-group") |
| 3208 | } |
| 3209 | if fieldNum <= 0 { |
| 3210 | return fmt.Errorf("proto: SubjectRulesReviewStatus: illegal tag %d (wire type %d)", fieldNum, wire) |
| 3211 | } |
| 3212 | switch fieldNum { |
| 3213 | case 1: |
| 3214 | if wireType != 2 { |
| 3215 | return fmt.Errorf("proto: wrong wireType = %d for field ResourceRules", wireType) |
| 3216 | } |
| 3217 | var msglen int |
| 3218 | for shift := uint(0); ; shift += 7 { |
| 3219 | if shift >= 64 { |
| 3220 | return ErrIntOverflowGenerated |
| 3221 | } |
| 3222 | if iNdEx >= l { |
| 3223 | return io.ErrUnexpectedEOF |
| 3224 | } |
| 3225 | b := dAtA[iNdEx] |
| 3226 | iNdEx++ |
| 3227 | msglen |= (int(b) & 0x7F) << shift |
| 3228 | if b < 0x80 { |
| 3229 | break |
| 3230 | } |
| 3231 | } |
| 3232 | if msglen < 0 { |
| 3233 | return ErrInvalidLengthGenerated |
| 3234 | } |
| 3235 | postIndex := iNdEx + msglen |
| 3236 | if postIndex > l { |
| 3237 | return io.ErrUnexpectedEOF |
| 3238 | } |
| 3239 | m.ResourceRules = append(m.ResourceRules, ResourceRule{}) |
| 3240 | if err := m.ResourceRules[len(m.ResourceRules)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 3241 | return err |
| 3242 | } |
| 3243 | iNdEx = postIndex |
| 3244 | case 2: |
| 3245 | if wireType != 2 { |
| 3246 | return fmt.Errorf("proto: wrong wireType = %d for field NonResourceRules", wireType) |
| 3247 | } |
| 3248 | var msglen int |
| 3249 | for shift := uint(0); ; shift += 7 { |
| 3250 | if shift >= 64 { |
| 3251 | return ErrIntOverflowGenerated |
| 3252 | } |
| 3253 | if iNdEx >= l { |
| 3254 | return io.ErrUnexpectedEOF |
| 3255 | } |
| 3256 | b := dAtA[iNdEx] |
| 3257 | iNdEx++ |
| 3258 | msglen |= (int(b) & 0x7F) << shift |
| 3259 | if b < 0x80 { |
| 3260 | break |
| 3261 | } |
| 3262 | } |
| 3263 | if msglen < 0 { |
| 3264 | return ErrInvalidLengthGenerated |
| 3265 | } |
| 3266 | postIndex := iNdEx + msglen |
| 3267 | if postIndex > l { |
| 3268 | return io.ErrUnexpectedEOF |
| 3269 | } |
| 3270 | m.NonResourceRules = append(m.NonResourceRules, NonResourceRule{}) |
| 3271 | if err := m.NonResourceRules[len(m.NonResourceRules)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
| 3272 | return err |
| 3273 | } |
| 3274 | iNdEx = postIndex |
| 3275 | case 3: |
| 3276 | if wireType != 0 { |
| 3277 | return fmt.Errorf("proto: wrong wireType = %d for field Incomplete", wireType) |
| 3278 | } |
| 3279 | var v int |
| 3280 | for shift := uint(0); ; shift += 7 { |
| 3281 | if shift >= 64 { |
| 3282 | return ErrIntOverflowGenerated |
| 3283 | } |
| 3284 | if iNdEx >= l { |
| 3285 | return io.ErrUnexpectedEOF |
| 3286 | } |
| 3287 | b := dAtA[iNdEx] |
| 3288 | iNdEx++ |
| 3289 | v |= (int(b) & 0x7F) << shift |
| 3290 | if b < 0x80 { |
| 3291 | break |
| 3292 | } |
| 3293 | } |
| 3294 | m.Incomplete = bool(v != 0) |
| 3295 | case 4: |
| 3296 | if wireType != 2 { |
| 3297 | return fmt.Errorf("proto: wrong wireType = %d for field EvaluationError", wireType) |
| 3298 | } |
| 3299 | var stringLen uint64 |
| 3300 | for shift := uint(0); ; shift += 7 { |
| 3301 | if shift >= 64 { |
| 3302 | return ErrIntOverflowGenerated |
| 3303 | } |
| 3304 | if iNdEx >= l { |
| 3305 | return io.ErrUnexpectedEOF |
| 3306 | } |
| 3307 | b := dAtA[iNdEx] |
| 3308 | iNdEx++ |
| 3309 | stringLen |= (uint64(b) & 0x7F) << shift |
| 3310 | if b < 0x80 { |
| 3311 | break |
| 3312 | } |
| 3313 | } |
| 3314 | intStringLen := int(stringLen) |
| 3315 | if intStringLen < 0 { |
| 3316 | return ErrInvalidLengthGenerated |
| 3317 | } |
| 3318 | postIndex := iNdEx + intStringLen |
| 3319 | if postIndex > l { |
| 3320 | return io.ErrUnexpectedEOF |
| 3321 | } |
| 3322 | m.EvaluationError = string(dAtA[iNdEx:postIndex]) |
| 3323 | iNdEx = postIndex |
| 3324 | default: |
| 3325 | iNdEx = preIndex |
| 3326 | skippy, err := skipGenerated(dAtA[iNdEx:]) |
| 3327 | if err != nil { |
| 3328 | return err |
| 3329 | } |
| 3330 | if skippy < 0 { |
| 3331 | return ErrInvalidLengthGenerated |
| 3332 | } |
| 3333 | if (iNdEx + skippy) > l { |
| 3334 | return io.ErrUnexpectedEOF |
| 3335 | } |
| 3336 | iNdEx += skippy |
| 3337 | } |
| 3338 | } |
| 3339 | |
| 3340 | if iNdEx > l { |
| 3341 | return io.ErrUnexpectedEOF |
| 3342 | } |
| 3343 | return nil |
| 3344 | } |
| 3345 | func skipGenerated(dAtA []byte) (n int, err error) { |
| 3346 | l := len(dAtA) |
| 3347 | iNdEx := 0 |
| 3348 | for iNdEx < l { |
| 3349 | var wire uint64 |
| 3350 | for shift := uint(0); ; shift += 7 { |
| 3351 | if shift >= 64 { |
| 3352 | return 0, ErrIntOverflowGenerated |
| 3353 | } |
| 3354 | if iNdEx >= l { |
| 3355 | return 0, io.ErrUnexpectedEOF |
| 3356 | } |
| 3357 | b := dAtA[iNdEx] |
| 3358 | iNdEx++ |
| 3359 | wire |= (uint64(b) & 0x7F) << shift |
| 3360 | if b < 0x80 { |
| 3361 | break |
| 3362 | } |
| 3363 | } |
| 3364 | wireType := int(wire & 0x7) |
| 3365 | switch wireType { |
| 3366 | case 0: |
| 3367 | for shift := uint(0); ; shift += 7 { |
| 3368 | if shift >= 64 { |
| 3369 | return 0, ErrIntOverflowGenerated |
| 3370 | } |
| 3371 | if iNdEx >= l { |
| 3372 | return 0, io.ErrUnexpectedEOF |
| 3373 | } |
| 3374 | iNdEx++ |
| 3375 | if dAtA[iNdEx-1] < 0x80 { |
| 3376 | break |
| 3377 | } |
| 3378 | } |
| 3379 | return iNdEx, nil |
| 3380 | case 1: |
| 3381 | iNdEx += 8 |
| 3382 | return iNdEx, nil |
| 3383 | case 2: |
| 3384 | var length int |
| 3385 | for shift := uint(0); ; shift += 7 { |
| 3386 | if shift >= 64 { |
| 3387 | return 0, ErrIntOverflowGenerated |
| 3388 | } |
| 3389 | if iNdEx >= l { |
| 3390 | return 0, io.ErrUnexpectedEOF |
| 3391 | } |
| 3392 | b := dAtA[iNdEx] |
| 3393 | iNdEx++ |
| 3394 | length |= (int(b) & 0x7F) << shift |
| 3395 | if b < 0x80 { |
| 3396 | break |
| 3397 | } |
| 3398 | } |
| 3399 | iNdEx += length |
| 3400 | if length < 0 { |
| 3401 | return 0, ErrInvalidLengthGenerated |
| 3402 | } |
| 3403 | return iNdEx, nil |
| 3404 | case 3: |
| 3405 | for { |
| 3406 | var innerWire uint64 |
| 3407 | var start int = iNdEx |
| 3408 | for shift := uint(0); ; shift += 7 { |
| 3409 | if shift >= 64 { |
| 3410 | return 0, ErrIntOverflowGenerated |
| 3411 | } |
| 3412 | if iNdEx >= l { |
| 3413 | return 0, io.ErrUnexpectedEOF |
| 3414 | } |
| 3415 | b := dAtA[iNdEx] |
| 3416 | iNdEx++ |
| 3417 | innerWire |= (uint64(b) & 0x7F) << shift |
| 3418 | if b < 0x80 { |
| 3419 | break |
| 3420 | } |
| 3421 | } |
| 3422 | innerWireType := int(innerWire & 0x7) |
| 3423 | if innerWireType == 4 { |
| 3424 | break |
| 3425 | } |
| 3426 | next, err := skipGenerated(dAtA[start:]) |
| 3427 | if err != nil { |
| 3428 | return 0, err |
| 3429 | } |
| 3430 | iNdEx = start + next |
| 3431 | } |
| 3432 | return iNdEx, nil |
| 3433 | case 4: |
| 3434 | return iNdEx, nil |
| 3435 | case 5: |
| 3436 | iNdEx += 4 |
| 3437 | return iNdEx, nil |
| 3438 | default: |
| 3439 | return 0, fmt.Errorf("proto: illegal wireType %d", wireType) |
| 3440 | } |
| 3441 | } |
| 3442 | panic("unreachable") |
| 3443 | } |
| 3444 | |
| 3445 | var ( |
| 3446 | ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") |
| 3447 | ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") |
| 3448 | ) |
| 3449 | |
| 3450 | func init() { |
| 3451 | proto.RegisterFile("k8s.io/kubernetes/vendor/k8s.io/api/authorization/v1/generated.proto", fileDescriptorGenerated) |
| 3452 | } |
| 3453 | |
| 3454 | var fileDescriptorGenerated = []byte{ |
| 3455 | // 1152 bytes of a gzipped FileDescriptorProto |
| 3456 | 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x56, 0x4f, 0x6f, 0x1b, 0x45, |
| 3457 | 0x14, 0xf7, 0xae, 0xed, 0xd4, 0x1e, 0x37, 0x24, 0x9d, 0x28, 0xcd, 0x36, 0x15, 0x76, 0xb4, 0x48, |
| 3458 | 0x90, 0x8a, 0xb2, 0x4b, 0x4c, 0xdb, 0x44, 0x95, 0x2a, 0x14, 0x2b, 0x11, 0x8a, 0xd4, 0x96, 0x6a, |
| 3459 | 0xa2, 0x44, 0xa2, 0x08, 0xc4, 0x78, 0x3d, 0xb1, 0x97, 0xd8, 0xbb, 0xcb, 0xcc, 0xac, 0x43, 0x38, |
| 3460 | 0x55, 0xe2, 0x0b, 0x70, 0xe4, 0xc0, 0x81, 0x6f, 0xc0, 0x05, 0x89, 0x1b, 0x07, 0x0e, 0x28, 0xc7, |
| 3461 | 0x1e, 0x8b, 0x84, 0x2c, 0xb2, 0x9c, 0xf9, 0x0e, 0x68, 0x66, 0xc7, 0xde, 0x75, 0xb2, 0x76, 0x13, |
| 3462 | 0x0e, 0xf4, 0xd2, 0xdb, 0xee, 0xfb, 0xfd, 0xde, 0x9f, 0x79, 0x7f, 0x66, 0x1e, 0xd8, 0x3a, 0xdc, |
| 3463 | 0x60, 0x96, 0xeb, 0xdb, 0x87, 0x61, 0x93, 0x50, 0x8f, 0x70, 0xc2, 0xec, 0x3e, 0xf1, 0x5a, 0x3e, |
| 3464 | 0xb5, 0x15, 0x80, 0x03, 0xd7, 0xc6, 0x21, 0xef, 0xf8, 0xd4, 0xfd, 0x06, 0x73, 0xd7, 0xf7, 0xec, |
| 3465 | 0xfe, 0x9a, 0xdd, 0x26, 0x1e, 0xa1, 0x98, 0x93, 0x96, 0x15, 0x50, 0x9f, 0xfb, 0xf0, 0x66, 0x4c, |
| 3466 | 0xb6, 0x70, 0xe0, 0x5a, 0x63, 0x64, 0xab, 0xbf, 0xb6, 0xfc, 0x5e, 0xdb, 0xe5, 0x9d, 0xb0, 0x69, |
| 3467 | 0x39, 0x7e, 0xcf, 0x6e, 0xfb, 0x6d, 0xdf, 0x96, 0x3a, 0xcd, 0xf0, 0x40, 0xfe, 0xc9, 0x1f, 0xf9, |
| 3468 | 0x15, 0xdb, 0x5a, 0xbe, 0x93, 0x38, 0xee, 0x61, 0xa7, 0xe3, 0x7a, 0x84, 0x1e, 0xdb, 0xc1, 0x61, |
| 3469 | 0x5b, 0x08, 0x98, 0xdd, 0x23, 0x1c, 0x67, 0x44, 0xb0, 0x6c, 0x4f, 0xd2, 0xa2, 0xa1, 0xc7, 0xdd, |
| 3470 | 0x1e, 0x39, 0xa7, 0x70, 0xef, 0x65, 0x0a, 0xcc, 0xe9, 0x90, 0x1e, 0x3e, 0xa7, 0xf7, 0xc1, 0x24, |
| 3471 | 0xbd, 0x90, 0xbb, 0x5d, 0xdb, 0xf5, 0x38, 0xe3, 0xf4, 0xac, 0x92, 0xb9, 0x0e, 0xc0, 0xf6, 0xd7, |
| 3472 | 0x9c, 0xe2, 0x7d, 0xdc, 0x0d, 0x09, 0xac, 0x81, 0xa2, 0xcb, 0x49, 0x8f, 0x19, 0xda, 0x4a, 0x7e, |
| 3473 | 0xb5, 0xdc, 0x28, 0x47, 0x83, 0x5a, 0x71, 0x47, 0x08, 0x50, 0x2c, 0xbf, 0x5f, 0xfa, 0xfe, 0xc7, |
| 3474 | 0x5a, 0xee, 0xd9, 0x9f, 0x2b, 0x39, 0xf3, 0x67, 0x1d, 0x18, 0x0f, 0x7d, 0x07, 0x77, 0x77, 0xc3, |
| 3475 | 0xe6, 0x97, 0xc4, 0xe1, 0x9b, 0x8e, 0x43, 0x18, 0x43, 0xa4, 0xef, 0x92, 0x23, 0xf8, 0x05, 0x28, |
| 3476 | 0x89, 0x74, 0xb4, 0x30, 0xc7, 0x86, 0xb6, 0xa2, 0xad, 0x56, 0xea, 0xef, 0x5b, 0x49, 0x21, 0x46, |
| 3477 | 0xd1, 0x59, 0xc1, 0x61, 0x5b, 0x08, 0x98, 0x25, 0xd8, 0x56, 0x7f, 0xcd, 0xfa, 0x58, 0xda, 0x7a, |
| 3478 | 0x44, 0x38, 0x6e, 0xc0, 0x93, 0x41, 0x2d, 0x17, 0x0d, 0x6a, 0x20, 0x91, 0xa1, 0x91, 0x55, 0xb8, |
| 3479 | 0x0f, 0x0a, 0x2c, 0x20, 0x8e, 0xa1, 0x4b, 0xeb, 0x77, 0xac, 0x29, 0x65, 0xb6, 0x32, 0x22, 0xdc, |
| 3480 | 0x0d, 0x88, 0xd3, 0xb8, 0xaa, 0x3c, 0x14, 0xc4, 0x1f, 0x92, 0xf6, 0xe0, 0xe7, 0x60, 0x86, 0x71, |
| 3481 | 0xcc, 0x43, 0x66, 0xe4, 0xa5, 0xe5, 0x7b, 0x97, 0xb6, 0x2c, 0xb5, 0x1b, 0x6f, 0x28, 0xdb, 0x33, |
| 3482 | 0xf1, 0x3f, 0x52, 0x56, 0xcd, 0x4f, 0xc1, 0xe2, 0x63, 0xdf, 0x43, 0x84, 0xf9, 0x21, 0x75, 0xc8, |
| 3483 | 0x26, 0xe7, 0xd4, 0x6d, 0x86, 0x9c, 0x30, 0xb8, 0x02, 0x0a, 0x01, 0xe6, 0x1d, 0x99, 0xae, 0x72, |
| 3484 | 0x12, 0xda, 0x13, 0xcc, 0x3b, 0x48, 0x22, 0x82, 0xd1, 0x27, 0xb4, 0x29, 0x8f, 0x9c, 0x62, 0xec, |
| 3485 | 0x13, 0xda, 0x44, 0x12, 0x31, 0xbf, 0x02, 0x73, 0x29, 0xe3, 0x28, 0xec, 0xca, 0x8a, 0x0a, 0x68, |
| 3486 | 0xac, 0xa2, 0x42, 0x83, 0xa1, 0x58, 0x0e, 0x1f, 0x80, 0x39, 0x2f, 0xd1, 0xd9, 0x43, 0x0f, 0x99, |
| 3487 | 0xa1, 0x4b, 0xea, 0x42, 0x34, 0xa8, 0xa5, 0xcd, 0x09, 0x08, 0x9d, 0xe5, 0x9a, 0xbf, 0xea, 0x00, |
| 3488 | 0x66, 0x9c, 0xc6, 0x06, 0x65, 0x0f, 0xf7, 0x08, 0x0b, 0xb0, 0x43, 0xd4, 0x91, 0xae, 0xa9, 0x80, |
| 3489 | 0xcb, 0x8f, 0x87, 0x00, 0x4a, 0x38, 0x2f, 0x3f, 0x1c, 0x7c, 0x0b, 0x14, 0xdb, 0xd4, 0x0f, 0x03, |
| 3490 | 0x59, 0x98, 0x72, 0x63, 0x56, 0x51, 0x8a, 0x1f, 0x09, 0x21, 0x8a, 0x31, 0x78, 0x0b, 0x5c, 0xe9, |
| 3491 | 0x13, 0xca, 0x5c, 0xdf, 0x33, 0x0a, 0x92, 0x36, 0xa7, 0x68, 0x57, 0xf6, 0x63, 0x31, 0x1a, 0xe2, |
| 3492 | 0xf0, 0x36, 0x28, 0x51, 0x15, 0xb8, 0x51, 0x94, 0xdc, 0x79, 0xc5, 0x2d, 0x8d, 0x32, 0x38, 0x62, |
| 3493 | 0xc0, 0xbb, 0xa0, 0xc2, 0xc2, 0xe6, 0x48, 0x61, 0x46, 0x2a, 0x2c, 0x28, 0x85, 0xca, 0x6e, 0x02, |
| 3494 | 0xa1, 0x34, 0x4f, 0x1c, 0x4b, 0x9c, 0xd1, 0xb8, 0x32, 0x7e, 0x2c, 0x91, 0x02, 0x24, 0x11, 0xf3, |
| 3495 | 0x37, 0x0d, 0x5c, 0xbd, 0x5c, 0xc5, 0xde, 0x05, 0x65, 0x1c, 0xb8, 0xf2, 0xd8, 0xc3, 0x5a, 0xcd, |
| 3496 | 0x8a, 0xbc, 0x6e, 0x3e, 0xd9, 0x89, 0x85, 0x28, 0xc1, 0x05, 0x79, 0x18, 0x8c, 0x68, 0xe9, 0x11, |
| 3497 | 0x79, 0xe8, 0x92, 0xa1, 0x04, 0x87, 0xeb, 0x60, 0x76, 0xf8, 0x23, 0x8b, 0x64, 0x14, 0xa4, 0xc2, |
| 3498 | 0xb5, 0x68, 0x50, 0x9b, 0x45, 0x69, 0x00, 0x8d, 0xf3, 0xcc, 0x5f, 0x74, 0xb0, 0xb4, 0x4b, 0xba, |
| 3499 | 0x07, 0xaf, 0xe6, 0x2e, 0x78, 0x3a, 0x76, 0x17, 0x6c, 0x4c, 0x9f, 0xd8, 0xec, 0x28, 0x5f, 0xd9, |
| 3500 | 0x7d, 0xf0, 0x83, 0x0e, 0x6e, 0x4e, 0x89, 0x09, 0x1e, 0x01, 0x48, 0xcf, 0x8d, 0x97, 0xca, 0xa3, |
| 3501 | 0x3d, 0x35, 0x96, 0xf3, 0x53, 0xd9, 0xb8, 0x1e, 0x0d, 0x6a, 0x19, 0xd3, 0x8a, 0x32, 0x5c, 0xc0, |
| 3502 | 0x6f, 0x35, 0xb0, 0xe8, 0x65, 0xdd, 0x54, 0x2a, 0xcd, 0xf5, 0xa9, 0xce, 0x33, 0xef, 0xb8, 0xc6, |
| 3503 | 0x8d, 0x68, 0x50, 0xcb, 0xbe, 0xfe, 0x50, 0xb6, 0x2f, 0xf1, 0xca, 0x5c, 0x4f, 0xa5, 0x47, 0x0c, |
| 3504 | 0xc8, 0xff, 0xd7, 0x57, 0x9f, 0x8c, 0xf5, 0xd5, 0xfa, 0x45, 0xfb, 0x2a, 0x15, 0xe4, 0xc4, 0xb6, |
| 3505 | 0xfa, 0xec, 0x4c, 0x5b, 0xdd, 0xbd, 0x48, 0x5b, 0xa5, 0x0d, 0x4f, 0xef, 0xaa, 0x47, 0x60, 0x79, |
| 3506 | 0x72, 0x40, 0x97, 0xbe, 0x9c, 0xcd, 0x9f, 0x74, 0xb0, 0xf0, 0xfa, 0x99, 0xbf, 0xcc, 0x58, 0xff, |
| 3507 | 0x5e, 0x00, 0x4b, 0xaf, 0x47, 0x7a, 0xd2, 0xa2, 0x13, 0x32, 0x42, 0xd5, 0x33, 0x3e, 0x2a, 0xce, |
| 3508 | 0x1e, 0x23, 0x14, 0x49, 0x04, 0x9a, 0x60, 0xa6, 0x1d, 0xbf, 0x6e, 0xf1, 0xfb, 0x03, 0x44, 0x82, |
| 3509 | 0xd5, 0xd3, 0xa6, 0x10, 0xd8, 0x02, 0x45, 0x22, 0xf6, 0x56, 0xa3, 0xb8, 0x92, 0x5f, 0xad, 0xd4, |
| 3510 | 0x3f, 0xfc, 0x2f, 0x9d, 0x61, 0xc9, 0xcd, 0x77, 0xdb, 0xe3, 0xf4, 0x38, 0x59, 0x27, 0xa4, 0x0c, |
| 3511 | 0xc5, 0xc6, 0xe1, 0x9b, 0x20, 0x1f, 0xba, 0x2d, 0xf5, 0xda, 0x57, 0x14, 0x25, 0xbf, 0xb7, 0xb3, |
| 3512 | 0x85, 0x84, 0x7c, 0x19, 0xab, 0xe5, 0x59, 0x9a, 0x80, 0xf3, 0x20, 0x7f, 0x48, 0x8e, 0xe3, 0x81, |
| 3513 | 0x42, 0xe2, 0x13, 0x3e, 0x00, 0xc5, 0xbe, 0xd8, 0xab, 0x55, 0x7e, 0xdf, 0x99, 0x1a, 0x64, 0xb2, |
| 3514 | 0x86, 0xa3, 0x58, 0xeb, 0xbe, 0xbe, 0xa1, 0x99, 0x7f, 0x68, 0xe0, 0xc6, 0xc4, 0xf6, 0x13, 0xeb, |
| 3515 | 0x0e, 0xee, 0x76, 0xfd, 0x23, 0xd2, 0x92, 0x6e, 0x4b, 0xc9, 0xba, 0xb3, 0x19, 0x8b, 0xd1, 0x10, |
| 3516 | 0x87, 0x6f, 0x83, 0x19, 0x4a, 0x30, 0xf3, 0x3d, 0xb5, 0x62, 0x8d, 0x3a, 0x17, 0x49, 0x29, 0x52, |
| 3517 | 0x28, 0xdc, 0x04, 0x73, 0x44, 0xb8, 0x97, 0x71, 0x6d, 0x53, 0xea, 0x0f, 0x2b, 0xb5, 0xa4, 0x14, |
| 3518 | 0xe6, 0xb6, 0xc7, 0x61, 0x74, 0x96, 0x2f, 0x5c, 0xb5, 0x88, 0xe7, 0x92, 0x96, 0xdc, 0xc1, 0x4a, |
| 3519 | 0x89, 0xab, 0x2d, 0x29, 0x45, 0x0a, 0x35, 0xff, 0xd1, 0x81, 0x31, 0xe9, 0x6a, 0x83, 0x07, 0xc9, |
| 3520 | 0x2e, 0x22, 0x41, 0xb9, 0x0e, 0x55, 0xea, 0xb7, 0x2e, 0x34, 0x20, 0x42, 0xa3, 0xb1, 0xa8, 0xdc, |
| 3521 | 0xce, 0xa6, 0xa5, 0xa9, 0xd5, 0x45, 0xfe, 0x42, 0x0a, 0xe6, 0xbd, 0xf1, 0x9d, 0x39, 0x5e, 0xaa, |
| 3522 | 0x2a, 0xf5, 0xdb, 0x17, 0x1d, 0x07, 0xe9, 0xcd, 0x50, 0xde, 0xe6, 0xcf, 0x00, 0x0c, 0x9d, 0xb3, |
| 3523 | 0x0f, 0xeb, 0x00, 0xb8, 0x9e, 0xe3, 0xf7, 0x82, 0x2e, 0xe1, 0x44, 0xa6, 0xb7, 0x94, 0xdc, 0x83, |
| 3524 | 0x3b, 0x23, 0x04, 0xa5, 0x58, 0x59, 0x75, 0x29, 0x5c, 0xae, 0x2e, 0x8d, 0xd5, 0x93, 0xd3, 0x6a, |
| 3525 | 0xee, 0xf9, 0x69, 0x35, 0xf7, 0xe2, 0xb4, 0x9a, 0x7b, 0x16, 0x55, 0xb5, 0x93, 0xa8, 0xaa, 0x3d, |
| 3526 | 0x8f, 0xaa, 0xda, 0x8b, 0xa8, 0xaa, 0xfd, 0x15, 0x55, 0xb5, 0xef, 0xfe, 0xae, 0xe6, 0x9e, 0xea, |
| 3527 | 0xfd, 0xb5, 0x7f, 0x03, 0x00, 0x00, 0xff, 0xff, 0xd6, 0x0e, 0xab, 0x82, 0x7c, 0x0f, 0x00, 0x00, |
| 3528 | } |