doorkeeper 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of doorkeeper might be problematic. Click here for more details.
- data/README.md +63 -48
- data/app/assets/stylesheets/doorkeeper/application.css +10 -2
- data/app/controllers/doorkeeper/application_controller.rbc +663 -0
- data/app/controllers/doorkeeper/applications_controller.rbc +954 -0
- data/app/controllers/doorkeeper/authorizations_controller.rb +8 -1
- data/app/controllers/doorkeeper/authorizations_controller.rbc +595 -0
- data/app/controllers/doorkeeper/tokens_controller.rbc +423 -0
- data/app/helpers/doorkeeper/application_helper.rbc +127 -0
- data/app/models/access_grant.rb +10 -2
- data/app/models/access_grant.rbc +656 -0
- data/app/models/access_token.rbc +781 -0
- data/app/models/application.rbc +507 -0
- data/app/views/doorkeeper/authorizations/new.html.erb +16 -12
- data/app/views/layouts/doorkeeper/application.html.erb +9 -0
- data/config/initializers/form_errors.rbc +272 -0
- data/config/routes.rbc +322 -0
- data/lib/doorkeeper.rbc +407 -0
- data/lib/doorkeeper/config.rbc +941 -0
- data/lib/doorkeeper/doorkeeper_for.rbc +1029 -0
- data/lib/doorkeeper/engine.rbc +318 -0
- data/lib/doorkeeper/oauth/access_token_request.rb +9 -2
- data/lib/doorkeeper/oauth/access_token_request.rbc +1853 -0
- data/lib/doorkeeper/oauth/authorization_request.rb +5 -0
- data/lib/doorkeeper/oauth/authorization_request.rbc +2107 -0
- data/lib/doorkeeper/oauth/random_string.rbc +437 -0
- data/lib/doorkeeper/validations.rbc +774 -0
- data/lib/doorkeeper/version.rb +1 -1
- data/lib/doorkeeper/version.rbc +130 -0
- data/lib/generators/doorkeeper/install_generator.rbc +453 -0
- data/lib/generators/doorkeeper/templates/migration.rb +1 -0
- data/lib/tasks/doorkeeper_tasks.rake.compiled.rbc +40 -0
- metadata +44 -17
data/app/models/access_grant.rb
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
class AccessGrant < ActiveRecord::Base
|
2
2
|
include Doorkeeper::OAuth::RandomString
|
3
3
|
|
4
|
-
|
4
|
+
set_table_name :oauth_access_grants
|
5
5
|
|
6
6
|
belongs_to :application
|
7
7
|
|
@@ -14,7 +14,15 @@ class AccessGrant < ActiveRecord::Base
|
|
14
14
|
end
|
15
15
|
|
16
16
|
def accessible?
|
17
|
-
!expired?
|
17
|
+
!expired? && !revoked?
|
18
|
+
end
|
19
|
+
|
20
|
+
def revoke
|
21
|
+
update_attribute :revoked_at, DateTime.now
|
22
|
+
end
|
23
|
+
|
24
|
+
def revoked?
|
25
|
+
revoked_at.present?
|
18
26
|
end
|
19
27
|
|
20
28
|
private
|
@@ -0,0 +1,656 @@
|
|
1
|
+
!RBIX
|
2
|
+
9595534255132031488
|
3
|
+
x
|
4
|
+
M
|
5
|
+
1
|
6
|
+
n
|
7
|
+
n
|
8
|
+
x
|
9
|
+
10
|
10
|
+
__script__
|
11
|
+
i
|
12
|
+
33
|
13
|
+
99
|
14
|
+
7
|
15
|
+
0
|
16
|
+
45
|
17
|
+
1
|
18
|
+
2
|
19
|
+
43
|
20
|
+
3
|
21
|
+
65
|
22
|
+
49
|
23
|
+
4
|
24
|
+
3
|
25
|
+
13
|
26
|
+
99
|
27
|
+
12
|
28
|
+
7
|
29
|
+
5
|
30
|
+
12
|
31
|
+
7
|
32
|
+
6
|
33
|
+
12
|
34
|
+
65
|
35
|
+
12
|
36
|
+
49
|
37
|
+
7
|
38
|
+
4
|
39
|
+
15
|
40
|
+
49
|
41
|
+
5
|
42
|
+
0
|
43
|
+
15
|
44
|
+
2
|
45
|
+
11
|
46
|
+
I
|
47
|
+
6
|
48
|
+
I
|
49
|
+
0
|
50
|
+
I
|
51
|
+
0
|
52
|
+
I
|
53
|
+
0
|
54
|
+
n
|
55
|
+
p
|
56
|
+
8
|
57
|
+
x
|
58
|
+
11
|
59
|
+
AccessGrant
|
60
|
+
x
|
61
|
+
12
|
62
|
+
ActiveRecord
|
63
|
+
n
|
64
|
+
x
|
65
|
+
4
|
66
|
+
Base
|
67
|
+
x
|
68
|
+
10
|
69
|
+
open_class
|
70
|
+
x
|
71
|
+
14
|
72
|
+
__class_init__
|
73
|
+
M
|
74
|
+
1
|
75
|
+
n
|
76
|
+
n
|
77
|
+
x
|
78
|
+
11
|
79
|
+
AccessGrant
|
80
|
+
i
|
81
|
+
151
|
82
|
+
5
|
83
|
+
66
|
84
|
+
5
|
85
|
+
45
|
86
|
+
0
|
87
|
+
1
|
88
|
+
43
|
89
|
+
2
|
90
|
+
43
|
91
|
+
3
|
92
|
+
47
|
93
|
+
49
|
94
|
+
4
|
95
|
+
1
|
96
|
+
15
|
97
|
+
5
|
98
|
+
7
|
99
|
+
5
|
100
|
+
64
|
101
|
+
13
|
102
|
+
18
|
103
|
+
2
|
104
|
+
47
|
105
|
+
49
|
106
|
+
6
|
107
|
+
1
|
108
|
+
15
|
109
|
+
15
|
110
|
+
5
|
111
|
+
7
|
112
|
+
7
|
113
|
+
47
|
114
|
+
49
|
115
|
+
8
|
116
|
+
1
|
117
|
+
15
|
118
|
+
5
|
119
|
+
7
|
120
|
+
9
|
121
|
+
7
|
122
|
+
10
|
123
|
+
7
|
124
|
+
11
|
125
|
+
7
|
126
|
+
12
|
127
|
+
7
|
128
|
+
13
|
129
|
+
44
|
130
|
+
43
|
131
|
+
14
|
132
|
+
79
|
133
|
+
49
|
134
|
+
15
|
135
|
+
1
|
136
|
+
13
|
137
|
+
7
|
138
|
+
16
|
139
|
+
2
|
140
|
+
49
|
141
|
+
17
|
142
|
+
2
|
143
|
+
15
|
144
|
+
47
|
145
|
+
49
|
146
|
+
18
|
147
|
+
6
|
148
|
+
15
|
149
|
+
5
|
150
|
+
7
|
151
|
+
19
|
152
|
+
44
|
153
|
+
43
|
154
|
+
14
|
155
|
+
79
|
156
|
+
49
|
157
|
+
15
|
158
|
+
1
|
159
|
+
13
|
160
|
+
7
|
161
|
+
20
|
162
|
+
7
|
163
|
+
21
|
164
|
+
49
|
165
|
+
17
|
166
|
+
2
|
167
|
+
15
|
168
|
+
47
|
169
|
+
49
|
170
|
+
22
|
171
|
+
2
|
172
|
+
15
|
173
|
+
99
|
174
|
+
7
|
175
|
+
23
|
176
|
+
7
|
177
|
+
24
|
178
|
+
65
|
179
|
+
67
|
180
|
+
49
|
181
|
+
25
|
182
|
+
0
|
183
|
+
49
|
184
|
+
26
|
185
|
+
4
|
186
|
+
15
|
187
|
+
99
|
188
|
+
7
|
189
|
+
27
|
190
|
+
7
|
191
|
+
28
|
192
|
+
65
|
193
|
+
67
|
194
|
+
49
|
195
|
+
25
|
196
|
+
0
|
197
|
+
49
|
198
|
+
26
|
199
|
+
4
|
200
|
+
15
|
201
|
+
5
|
202
|
+
48
|
203
|
+
29
|
204
|
+
15
|
205
|
+
99
|
206
|
+
7
|
207
|
+
30
|
208
|
+
7
|
209
|
+
31
|
210
|
+
65
|
211
|
+
67
|
212
|
+
49
|
213
|
+
25
|
214
|
+
0
|
215
|
+
49
|
216
|
+
26
|
217
|
+
4
|
218
|
+
15
|
219
|
+
99
|
220
|
+
7
|
221
|
+
19
|
222
|
+
7
|
223
|
+
32
|
224
|
+
65
|
225
|
+
67
|
226
|
+
49
|
227
|
+
25
|
228
|
+
0
|
229
|
+
49
|
230
|
+
26
|
231
|
+
4
|
232
|
+
11
|
233
|
+
I
|
234
|
+
a
|
235
|
+
I
|
236
|
+
0
|
237
|
+
I
|
238
|
+
0
|
239
|
+
I
|
240
|
+
0
|
241
|
+
n
|
242
|
+
p
|
243
|
+
33
|
244
|
+
x
|
245
|
+
10
|
246
|
+
Doorkeeper
|
247
|
+
n
|
248
|
+
x
|
249
|
+
5
|
250
|
+
OAuth
|
251
|
+
x
|
252
|
+
12
|
253
|
+
RandomString
|
254
|
+
x
|
255
|
+
7
|
256
|
+
include
|
257
|
+
s
|
258
|
+
19
|
259
|
+
oauth_access_grants
|
260
|
+
x
|
261
|
+
11
|
262
|
+
table_name=
|
263
|
+
x
|
264
|
+
11
|
265
|
+
application
|
266
|
+
x
|
267
|
+
10
|
268
|
+
belongs_to
|
269
|
+
x
|
270
|
+
17
|
271
|
+
resource_owner_id
|
272
|
+
x
|
273
|
+
14
|
274
|
+
application_id
|
275
|
+
x
|
276
|
+
5
|
277
|
+
token
|
278
|
+
x
|
279
|
+
10
|
280
|
+
expires_in
|
281
|
+
x
|
282
|
+
12
|
283
|
+
redirect_uri
|
284
|
+
x
|
285
|
+
4
|
286
|
+
Hash
|
287
|
+
x
|
288
|
+
16
|
289
|
+
new_from_literal
|
290
|
+
x
|
291
|
+
8
|
292
|
+
presence
|
293
|
+
x
|
294
|
+
3
|
295
|
+
[]=
|
296
|
+
x
|
297
|
+
9
|
298
|
+
validates
|
299
|
+
x
|
300
|
+
14
|
301
|
+
generate_token
|
302
|
+
x
|
303
|
+
2
|
304
|
+
on
|
305
|
+
x
|
306
|
+
6
|
307
|
+
create
|
308
|
+
x
|
309
|
+
17
|
310
|
+
before_validation
|
311
|
+
x
|
312
|
+
8
|
313
|
+
expired?
|
314
|
+
M
|
315
|
+
1
|
316
|
+
n
|
317
|
+
n
|
318
|
+
x
|
319
|
+
8
|
320
|
+
expired?
|
321
|
+
i
|
322
|
+
22
|
323
|
+
5
|
324
|
+
48
|
325
|
+
0
|
326
|
+
49
|
327
|
+
1
|
328
|
+
0
|
329
|
+
13
|
330
|
+
9
|
331
|
+
21
|
332
|
+
15
|
333
|
+
45
|
334
|
+
2
|
335
|
+
3
|
336
|
+
49
|
337
|
+
4
|
338
|
+
0
|
339
|
+
5
|
340
|
+
48
|
341
|
+
5
|
342
|
+
85
|
343
|
+
6
|
344
|
+
11
|
345
|
+
I
|
346
|
+
2
|
347
|
+
I
|
348
|
+
0
|
349
|
+
I
|
350
|
+
0
|
351
|
+
I
|
352
|
+
0
|
353
|
+
n
|
354
|
+
p
|
355
|
+
7
|
356
|
+
x
|
357
|
+
10
|
358
|
+
expires_in
|
359
|
+
x
|
360
|
+
8
|
361
|
+
present?
|
362
|
+
x
|
363
|
+
4
|
364
|
+
Time
|
365
|
+
n
|
366
|
+
x
|
367
|
+
3
|
368
|
+
now
|
369
|
+
x
|
370
|
+
12
|
371
|
+
expired_time
|
372
|
+
x
|
373
|
+
1
|
374
|
+
>
|
375
|
+
p
|
376
|
+
5
|
377
|
+
I
|
378
|
+
-1
|
379
|
+
I
|
380
|
+
c
|
381
|
+
I
|
382
|
+
0
|
383
|
+
I
|
384
|
+
d
|
385
|
+
I
|
386
|
+
16
|
387
|
+
x
|
388
|
+
66
|
389
|
+
/Users/felipeelias/Applicake/doorkeeper/app/models/access_grant.rb
|
390
|
+
p
|
391
|
+
0
|
392
|
+
x
|
393
|
+
17
|
394
|
+
method_visibility
|
395
|
+
x
|
396
|
+
15
|
397
|
+
add_defn_method
|
398
|
+
x
|
399
|
+
11
|
400
|
+
accessible?
|
401
|
+
M
|
402
|
+
1
|
403
|
+
n
|
404
|
+
n
|
405
|
+
x
|
406
|
+
11
|
407
|
+
accessible?
|
408
|
+
i
|
409
|
+
12
|
410
|
+
5
|
411
|
+
47
|
412
|
+
49
|
413
|
+
0
|
414
|
+
0
|
415
|
+
10
|
416
|
+
10
|
417
|
+
2
|
418
|
+
8
|
419
|
+
11
|
420
|
+
3
|
421
|
+
11
|
422
|
+
I
|
423
|
+
1
|
424
|
+
I
|
425
|
+
0
|
426
|
+
I
|
427
|
+
0
|
428
|
+
I
|
429
|
+
0
|
430
|
+
n
|
431
|
+
p
|
432
|
+
1
|
433
|
+
x
|
434
|
+
8
|
435
|
+
expired?
|
436
|
+
p
|
437
|
+
5
|
438
|
+
I
|
439
|
+
-1
|
440
|
+
I
|
441
|
+
10
|
442
|
+
I
|
443
|
+
0
|
444
|
+
I
|
445
|
+
11
|
446
|
+
I
|
447
|
+
c
|
448
|
+
x
|
449
|
+
66
|
450
|
+
/Users/felipeelias/Applicake/doorkeeper/app/models/access_grant.rb
|
451
|
+
p
|
452
|
+
0
|
453
|
+
x
|
454
|
+
7
|
455
|
+
private
|
456
|
+
x
|
457
|
+
12
|
458
|
+
expired_time
|
459
|
+
M
|
460
|
+
1
|
461
|
+
n
|
462
|
+
n
|
463
|
+
x
|
464
|
+
12
|
465
|
+
expired_time
|
466
|
+
i
|
467
|
+
13
|
468
|
+
5
|
469
|
+
49
|
470
|
+
0
|
471
|
+
0
|
472
|
+
5
|
473
|
+
48
|
474
|
+
1
|
475
|
+
49
|
476
|
+
2
|
477
|
+
0
|
478
|
+
81
|
479
|
+
3
|
480
|
+
11
|
481
|
+
I
|
482
|
+
2
|
483
|
+
I
|
484
|
+
0
|
485
|
+
I
|
486
|
+
0
|
487
|
+
I
|
488
|
+
0
|
489
|
+
n
|
490
|
+
p
|
491
|
+
4
|
492
|
+
x
|
493
|
+
10
|
494
|
+
created_at
|
495
|
+
x
|
496
|
+
10
|
497
|
+
expires_in
|
498
|
+
x
|
499
|
+
7
|
500
|
+
seconds
|
501
|
+
x
|
502
|
+
1
|
503
|
+
+
|
504
|
+
p
|
505
|
+
5
|
506
|
+
I
|
507
|
+
-1
|
508
|
+
I
|
509
|
+
16
|
510
|
+
I
|
511
|
+
0
|
512
|
+
I
|
513
|
+
17
|
514
|
+
I
|
515
|
+
d
|
516
|
+
x
|
517
|
+
66
|
518
|
+
/Users/felipeelias/Applicake/doorkeeper/app/models/access_grant.rb
|
519
|
+
p
|
520
|
+
0
|
521
|
+
M
|
522
|
+
1
|
523
|
+
n
|
524
|
+
n
|
525
|
+
x
|
526
|
+
14
|
527
|
+
generate_token
|
528
|
+
i
|
529
|
+
17
|
530
|
+
5
|
531
|
+
5
|
532
|
+
7
|
533
|
+
0
|
534
|
+
47
|
535
|
+
49
|
536
|
+
1
|
537
|
+
1
|
538
|
+
13
|
539
|
+
18
|
540
|
+
2
|
541
|
+
47
|
542
|
+
49
|
543
|
+
2
|
544
|
+
1
|
545
|
+
15
|
546
|
+
11
|
547
|
+
I
|
548
|
+
3
|
549
|
+
I
|
550
|
+
0
|
551
|
+
I
|
552
|
+
0
|
553
|
+
I
|
554
|
+
0
|
555
|
+
n
|
556
|
+
p
|
557
|
+
3
|
558
|
+
x
|
559
|
+
5
|
560
|
+
token
|
561
|
+
x
|
562
|
+
24
|
563
|
+
unique_random_string_for
|
564
|
+
x
|
565
|
+
6
|
566
|
+
token=
|
567
|
+
p
|
568
|
+
7
|
569
|
+
I
|
570
|
+
-1
|
571
|
+
I
|
572
|
+
1a
|
573
|
+
I
|
574
|
+
0
|
575
|
+
I
|
576
|
+
1d
|
577
|
+
I
|
578
|
+
1
|
579
|
+
I
|
580
|
+
1b
|
581
|
+
I
|
582
|
+
11
|
583
|
+
x
|
584
|
+
66
|
585
|
+
/Users/felipeelias/Applicake/doorkeeper/app/models/access_grant.rb
|
586
|
+
p
|
587
|
+
0
|
588
|
+
p
|
589
|
+
23
|
590
|
+
I
|
591
|
+
2
|
592
|
+
I
|
593
|
+
2
|
594
|
+
I
|
595
|
+
f
|
596
|
+
I
|
597
|
+
1d
|
598
|
+
I
|
599
|
+
10
|
600
|
+
I
|
601
|
+
4
|
602
|
+
I
|
603
|
+
1c
|
604
|
+
I
|
605
|
+
6
|
606
|
+
I
|
607
|
+
24
|
608
|
+
I
|
609
|
+
8
|
610
|
+
I
|
611
|
+
43
|
612
|
+
I
|
613
|
+
a
|
614
|
+
I
|
615
|
+
5b
|
616
|
+
I
|
617
|
+
c
|
618
|
+
I
|
619
|
+
69
|
620
|
+
I
|
621
|
+
10
|
622
|
+
I
|
623
|
+
77
|
624
|
+
I
|
625
|
+
14
|
626
|
+
I
|
627
|
+
7b
|
628
|
+
I
|
629
|
+
16
|
630
|
+
I
|
631
|
+
89
|
632
|
+
I
|
633
|
+
1a
|
634
|
+
I
|
635
|
+
97
|
636
|
+
x
|
637
|
+
66
|
638
|
+
/Users/felipeelias/Applicake/doorkeeper/app/models/access_grant.rb
|
639
|
+
p
|
640
|
+
0
|
641
|
+
x
|
642
|
+
13
|
643
|
+
attach_method
|
644
|
+
p
|
645
|
+
3
|
646
|
+
I
|
647
|
+
0
|
648
|
+
I
|
649
|
+
1
|
650
|
+
I
|
651
|
+
21
|
652
|
+
x
|
653
|
+
66
|
654
|
+
/Users/felipeelias/Applicake/doorkeeper/app/models/access_grant.rb
|
655
|
+
p
|
656
|
+
0
|