OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 library crypto.sha1; | |
6 | |
7 import 'dart:convert'; | 5 import 'dart:convert'; |
8 import 'dart:typed_data'; | 6 import 'dart:typed_data'; |
9 | 7 |
10 import 'digest.dart'; | 8 import 'digest.dart'; |
11 import 'hash.dart'; | 9 import 'hash.dart'; |
12 import 'hash_sink.dart'; | 10 import 'hash_sink.dart'; |
13 import 'utils.dart'; | 11 import 'utils.dart'; |
14 | 12 |
15 /// An instance of [SHA1]. | 13 /// An instance of [SHA1]. |
16 /// | 14 /// |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
97 a = newA & mask32; | 95 a = newA & mask32; |
98 } | 96 } |
99 | 97 |
100 digest[0] = add32(a, digest[0]); | 98 digest[0] = add32(a, digest[0]); |
101 digest[1] = add32(b, digest[1]); | 99 digest[1] = add32(b, digest[1]); |
102 digest[2] = add32(c, digest[2]); | 100 digest[2] = add32(c, digest[2]); |
103 digest[3] = add32(d, digest[3]); | 101 digest[3] = add32(d, digest[3]); |
104 digest[4] = add32(e, digest[4]); | 102 digest[4] = add32(e, digest[4]); |
105 } | 103 } |
106 } | 104 } |
OLD | NEW |