corrade-nucleus-nucleons – Blame information for rev 26

Subversion Repositories:
Rev:
Rev Author Line No. Line
22 office 1 /**
2 * Supported cipher modes.
3 *
4 * @author Dave Longley
5 *
6 * Copyright (c) 2010-2014 Digital Bazaar, Inc.
7 */
8 var forge = require('./forge');
9 require('./util');
10  
11 forge.cipher = forge.cipher || {};
12  
13 // supported cipher modes
14 var modes = module.exports = forge.cipher.modes = forge.cipher.modes || {};
15  
16 /** Electronic codebook (ECB) (Don't use this; it's not secure) **/
17  
18 modes.ecb = function(options) {
19 options = options || {};
20 this.name = 'ECB';
21 this.cipher = options.cipher;
22 this.blockSize = options.blockSize || 16;
23 this._ints = this.blockSize / 4;
24 this._inBlock = new Array(this._ints);
25 this._outBlock = new Array(this._ints);
26 };
27  
28 modes.ecb.prototype.start = function(options) {};
29  
30 modes.ecb.prototype.encrypt = function(input, output, finish) {
31 // not enough input to encrypt
32 if(input.length() < this.blockSize && !(finish && input.length() > 0)) {
33 < this.blockSize && !(finish && input.length() > return true;
34 < this.blockSize && !(finish && input.length() > }
35  
36 < this.blockSize && !(finish && input.length() > // get next block
37 < this.blockSize && !(finish && input.length() > for(var i = 0; i < this._ints; ++i) {
38 < this.blockSize && !(finish && input.length() >< this._ints; ++i) { this._inBlock[i] = input.getInt32();
39 < this.blockSize && !(finish && input.length() >< this._ints; ++i) { }
40  
41 < this.blockSize && !(finish && input.length() >< this._ints; ++i) { // encrypt block
42 < this.blockSize && !(finish && input.length() >< this._ints; ++i) { this.cipher.encrypt(this._inBlock, this._outBlock);
43  
44 < this.blockSize && !(finish && input.length() >< this._ints; ++i) { // write output
45 < this.blockSize && !(finish && input.length() >< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
46 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { output.putInt32(this._outBlock[i]);
47 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { }
48 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {};
49  
50 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {modes.ecb.prototype.decrypt = function(input, output, finish) {
51 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { // not enough input to decrypt
52 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { if(input.length() < this.blockSize && !(finish && input.length() > 0)) {
53 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() > return true;
54 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() > }
55  
56 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() > // get next block
57 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() > for(var i = 0; i < this._ints; ++i) {
58 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) { this._inBlock[i] = input.getInt32();
59 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) { }
60  
61 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) { // decrypt block
62 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) { this.cipher.decrypt(this._inBlock, this._outBlock);
63  
64 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) { // write output
65 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
66 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { output.putInt32(this._outBlock[i]);
67 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { }
68 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {};
69  
70 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {modes.ecb.prototype.pad = function(input, options) {
71 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { // add PKCS#7 padding to block (each pad byte is the
72 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { // value of the number of pad bytes)
73 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { var padding = (input.length() === this.blockSize ?
74 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { this.blockSize : (this.blockSize - input.length()));
75 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { input.fillWithByte(padding, padding);
76 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { return true;
77 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {};
78  
79 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {modes.ecb.prototype.unpad = function(output, options) {
80 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { // check for error: input data not a multiple of blockSize
81 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { if(options.overflow > 0) {
82 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { return false;
83 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { }
84  
85 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { // ensure padding byte count is valid
86 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { var len = output.length();
87 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { var count = output.at(len - 1);
88 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) { if(count > (this.blockSize << 2)) {
89 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { return false;
90 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { }
91  
92 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // trim off padding bytes
93 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { output.truncate(count);
94 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { return true;
95 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {};
96  
97 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {/** Cipher-block Chaining (CBC) **/
98  
99 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {modes.cbc = function(options) {
100 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { options = options || {};
101 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this.name = 'CBC';
102 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this.cipher = options.cipher;
103 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this.blockSize = options.blockSize || 16;
104 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._ints = this.blockSize / 4;
105 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._inBlock = new Array(this._ints);
106 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._outBlock = new Array(this._ints);
107 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {};
108  
109 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {modes.cbc.prototype.start = function(options) {
110 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // Note: legacy support for using IV residue (has security flaws)
111 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // if IV is null, reuse block from previous processing
112 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { if(options.iv === null) {
113 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // must have a previous block
114 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { if(!this._prev) {
115 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { throw new Error('Invalid IV parameter.');
116 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { }
117 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._iv = this._prev.slice(0);
118 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { } else if(!('iv' in options)) {
119 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { throw new Error('Invalid IV parameter.');
120 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { } else {
121 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // save IV as "previous" block
122 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._iv = transformIV(options.iv);
123 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._prev = this._iv.slice(0);
124 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { }
125 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {};
126  
127 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {modes.cbc.prototype.encrypt = function(input, output, finish) {
128 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // not enough input to encrypt
129 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { if(input.length() < this.blockSize && !(finish && input.length() > 0)) {
130 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { return true;
131 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { }
132  
133 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // get next block
134 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // CBC XOR's IV (or previous block) with plaintext
135 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { for(var i = 0; i < this._ints; ++i) {
136 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._inBlock[i] = this._prev[i] ^ input.getInt32();
137 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { }
138  
139 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // encrypt block
140 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this.cipher.encrypt(this._inBlock, this._outBlock);
141  
142 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // write output, save previous block
143 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { for(var i = 0; i < this._ints; ++i) {
144 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { output.putInt32(this._outBlock[i]);
145 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { }
146 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._prev = this._outBlock;
147 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {};
148  
149 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {modes.cbc.prototype.decrypt = function(input, output, finish) {
150 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // not enough input to decrypt
151 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { if(input.length() < this.blockSize && !(finish && input.length() > 0)) {
152 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { return true;
153 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { }
154  
155 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // get next block
156 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { for(var i = 0; i < this._ints; ++i) {
157 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._inBlock[i] = input.getInt32();
158 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { }
159  
160 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // decrypt block
161 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this.cipher.decrypt(this._inBlock, this._outBlock);
162  
163 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // write output, save previous ciphered block
164 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // CBC XOR's IV (or previous block) with ciphertext
165 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { for(var i = 0; i < this._ints; ++i) {
166 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { output.putInt32(this._prev[i] ^ this._outBlock[i]);
167 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { }
168 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._prev = this._inBlock.slice(0);
169 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {};
170  
171 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {modes.cbc.prototype.pad = function(input, options) {
172 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // add PKCS#7 padding to block (each pad byte is the
173 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // value of the number of pad bytes)
174 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { var padding = (input.length() === this.blockSize ?
175 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this.blockSize : (this.blockSize - input.length()));
176 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { input.fillWithByte(padding, padding);
177 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { return true;
178 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {};
179  
180 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {modes.cbc.prototype.unpad = function(output, options) {
181 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // check for error: input data not a multiple of blockSize
182 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { if(options.overflow > 0) {
183 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { return false;
184 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { }
185  
186 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // ensure padding byte count is valid
187 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { var len = output.length();
188 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { var count = output.at(len - 1);
189 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { if(count > (this.blockSize << 2)) {
190 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { return false;
191 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { }
192  
193 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // trim off padding bytes
194 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { output.truncate(count);
195 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { return true;
196 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {};
197  
198 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {/** Cipher feedback (CFB) **/
199  
200 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {modes.cfb = function(options) {
201 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { options = options || {};
202 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this.name = 'CFB';
203 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this.cipher = options.cipher;
204 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this.blockSize = options.blockSize || 16;
205 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._ints = this.blockSize / 4;
206 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._inBlock = null;
207 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._outBlock = new Array(this._ints);
208 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._partialBlock = new Array(this._ints);
209 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._partialOutput = forge.util.createBuffer();
210 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._partialBytes = 0;
211 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {};
212  
213 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {modes.cfb.prototype.start = function(options) {
214 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { if(!('iv' in options)) {
215 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { throw new Error('Invalid IV parameter.');
216 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { }
217 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // use IV as first input
218 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._iv = transformIV(options.iv);
219 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._inBlock = this._iv.slice(0);
220 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this._partialBytes = 0;
221 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {};
222  
223 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {modes.cfb.prototype.encrypt = function(input, output, finish) {
224 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // not enough input to encrypt
225 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { var inputLength = input.length();
226 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { if(inputLength === 0) {
227 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { return true;
228 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { }
229  
230 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // encrypt block
231 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { this.cipher.encrypt(this._inBlock, this._outBlock);
232  
233 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // handle full block
234 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { if(this._partialBytes === 0 && inputLength >= this.blockSize) {
235 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { // XOR input with output, write input as output
236 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) { for(var i = 0; i < this._ints; ++i) {
237 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) { this._inBlock[i] = input.getInt32() ^ this._outBlock[i];
238 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) { output.putInt32(this._inBlock[i]);
239 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) { }
240 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) { return;
241 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) { }
242  
243 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) { // handle partial block
244 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) { var partialBytes = (this.blockSize - inputLength) % this.blockSize;
245 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) { if(partialBytes > 0) {
246 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) { partialBytes = this.blockSize - partialBytes;
247 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) { }
248  
249 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) { // XOR input with output, write input as partial output
250 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) { this._partialOutput.clear();
251 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
252 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) { this._partialBlock[i] = input.getInt32() ^ this._outBlock[i];
253 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.putInt32(this._partialBlock[i]);
254 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) { }
255  
256 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) { if(partialBytes > 0) {
257 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) { // block still incomplete, restore input buffer
258 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) { input.read -= this.blockSize;
259 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) { } else {
260 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) { // block complete, update input block
261 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
262 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._inBlock[i] = this._partialBlock[i];
263 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
264 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
265  
266 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // skip any previous partial bytes
267 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(this._partialBytes > 0) {
268 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.getBytes(this._partialBytes);
269 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
270  
271 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(partialBytes > 0 && !finish) {
272 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putBytes(this._partialOutput.getBytes(
273 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { partialBytes - this._partialBytes));
274 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = partialBytes;
275 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return true;
276 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
277  
278 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putBytes(this._partialOutput.getBytes(
279 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { inputLength - this._partialBytes));
280 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = 0;
281 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
282  
283 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.cfb.prototype.decrypt = function(input, output, finish) {
284 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // not enough input to decrypt
285 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var inputLength = input.length();
286 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(inputLength === 0) {
287 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return true;
288 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
289  
290 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // encrypt block (CFB always uses encryption mode)
291 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.cipher.encrypt(this._inBlock, this._outBlock);
292  
293 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // handle full block
294 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(this._partialBytes === 0 && inputLength >= this.blockSize) {
295 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // XOR input with output, write input as output
296 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
297 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._inBlock[i] = input.getInt32();
298 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putInt32(this._inBlock[i] ^ this._outBlock[i]);
299 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
300 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return;
301 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
302  
303 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // handle partial block
304 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var partialBytes = (this.blockSize - inputLength) % this.blockSize;
305 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(partialBytes > 0) {
306 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { partialBytes = this.blockSize - partialBytes;
307 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
308  
309 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // XOR input with output, write input as partial output
310 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.clear();
311 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
312 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBlock[i] = input.getInt32();
313 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.putInt32(this._partialBlock[i] ^ this._outBlock[i]);
314 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
315  
316 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(partialBytes > 0) {
317 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // block still incomplete, restore input buffer
318 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { input.read -= this.blockSize;
319 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { } else {
320 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // block complete, update input block
321 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
322 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._inBlock[i] = this._partialBlock[i];
323 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
324 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
325  
326 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // skip any previous partial bytes
327 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(this._partialBytes > 0) {
328 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.getBytes(this._partialBytes);
329 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
330  
331 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(partialBytes > 0 && !finish) {
332 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putBytes(this._partialOutput.getBytes(
333 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { partialBytes - this._partialBytes));
334 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = partialBytes;
335 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return true;
336 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
337  
338 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putBytes(this._partialOutput.getBytes(
339 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { inputLength - this._partialBytes));
340 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = 0;
341 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
342  
343 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {/** Output feedback (OFB) **/
344  
345 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.ofb = function(options) {
346 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { options = options || {};
347 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.name = 'OFB';
348 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.cipher = options.cipher;
349 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.blockSize = options.blockSize || 16;
350 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._ints = this.blockSize / 4;
351 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._inBlock = null;
352 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._outBlock = new Array(this._ints);
353 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput = forge.util.createBuffer();
354 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = 0;
355 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
356  
357 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.ofb.prototype.start = function(options) {
358 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(!('iv' in options)) {
359 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { throw new Error('Invalid IV parameter.');
360 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
361 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // use IV as first input
362 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._iv = transformIV(options.iv);
363 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._inBlock = this._iv.slice(0);
364 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = 0;
365 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
366  
367 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.ofb.prototype.encrypt = function(input, output, finish) {
368 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // not enough input to encrypt
369 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var inputLength = input.length();
370 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(input.length() === 0) {
371 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return true;
372 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
373  
374 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // encrypt block (OFB always uses encryption mode)
375 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.cipher.encrypt(this._inBlock, this._outBlock);
376  
377 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // handle full block
378 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(this._partialBytes === 0 && inputLength >= this.blockSize) {
379 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // XOR input with output and update next input
380 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
381 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putInt32(input.getInt32() ^ this._outBlock[i]);
382 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._inBlock[i] = this._outBlock[i];
383 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
384 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return;
385 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
386  
387 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // handle partial block
388 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var partialBytes = (this.blockSize - inputLength) % this.blockSize;
389 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(partialBytes > 0) {
390 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { partialBytes = this.blockSize - partialBytes;
391 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
392  
393 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // XOR input with output
394 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.clear();
395 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
396 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.putInt32(input.getInt32() ^ this._outBlock[i]);
397 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
398  
399 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(partialBytes > 0) {
400 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // block still incomplete, restore input buffer
401 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { input.read -= this.blockSize;
402 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { } else {
403 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // block complete, update input block
404 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
405 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._inBlock[i] = this._outBlock[i];
406 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
407 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
408  
409 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // skip any previous partial bytes
410 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(this._partialBytes > 0) {
411 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.getBytes(this._partialBytes);
412 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
413  
414 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(partialBytes > 0 && !finish) {
415 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putBytes(this._partialOutput.getBytes(
416 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { partialBytes - this._partialBytes));
417 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = partialBytes;
418 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return true;
419 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
420  
421 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putBytes(this._partialOutput.getBytes(
422 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { inputLength - this._partialBytes));
423 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = 0;
424 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
425  
426 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.ofb.prototype.decrypt = modes.ofb.prototype.encrypt;
427  
428 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {/** Counter (CTR) **/
429  
430 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.ctr = function(options) {
431 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { options = options || {};
432 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.name = 'CTR';
433 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.cipher = options.cipher;
434 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.blockSize = options.blockSize || 16;
435 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._ints = this.blockSize / 4;
436 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._inBlock = null;
437 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._outBlock = new Array(this._ints);
438 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput = forge.util.createBuffer();
439 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = 0;
440 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
441  
442 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.ctr.prototype.start = function(options) {
443 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(!('iv' in options)) {
444 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { throw new Error('Invalid IV parameter.');
445 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
446 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // use IV as first input
447 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._iv = transformIV(options.iv);
448 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._inBlock = this._iv.slice(0);
449 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = 0;
450 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
451  
452 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.ctr.prototype.encrypt = function(input, output, finish) {
453 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // not enough input to encrypt
454 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var inputLength = input.length();
455 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(inputLength === 0) {
456 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return true;
457 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
458  
459 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // encrypt block (CTR always uses encryption mode)
460 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.cipher.encrypt(this._inBlock, this._outBlock);
461  
462 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // handle full block
463 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(this._partialBytes === 0 && inputLength >= this.blockSize) {
464 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // XOR input with output
465 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
466 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putInt32(input.getInt32() ^ this._outBlock[i]);
467 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
468 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { } else {
469 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // handle partial block
470 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var partialBytes = (this.blockSize - inputLength) % this.blockSize;
471 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(partialBytes > 0) {
472 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { partialBytes = this.blockSize - partialBytes;
473 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
474  
475 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // XOR input with output
476 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.clear();
477 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
478 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.putInt32(input.getInt32() ^ this._outBlock[i]);
479 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
480  
481 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(partialBytes > 0) {
482 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // block still incomplete, restore input buffer
483 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { input.read -= this.blockSize;
484 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
485  
486 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // skip any previous partial bytes
487 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(this._partialBytes > 0) {
488 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.getBytes(this._partialBytes);
489 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
490  
491 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(partialBytes > 0 && !finish) {
492 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putBytes(this._partialOutput.getBytes(
493 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { partialBytes - this._partialBytes));
494 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = partialBytes;
495 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return true;
496 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
497  
498 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putBytes(this._partialOutput.getBytes(
499 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { inputLength - this._partialBytes));
500 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = 0;
501 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
502  
503 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // block complete, increment counter (input block)
504 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { inc32(this._inBlock);
505 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
506  
507 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.ctr.prototype.decrypt = modes.ctr.prototype.encrypt;
508  
509 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {/** Galois/Counter Mode (GCM) **/
510  
511 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.gcm = function(options) {
512 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { options = options || {};
513 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.name = 'GCM';
514 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.cipher = options.cipher;
515 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.blockSize = options.blockSize || 16;
516 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._ints = this.blockSize / 4;
517 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._inBlock = new Array(this._ints);
518 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._outBlock = new Array(this._ints);
519 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput = forge.util.createBuffer();
520 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = 0;
521  
522 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // R is actually this value concatenated with 120 more zero bits, but
523 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // we only XOR against R so the other zeros have no effect -- we just
524 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // apply this value to the first integer in a block
525 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._R = 0xE1000000;
526 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
527  
528 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.gcm.prototype.start = function(options) {
529 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(!('iv' in options)) {
530 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { throw new Error('Invalid IV parameter.');
531 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
532 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // ensure IV is a byte buffer
533 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var iv = forge.util.createBuffer(options.iv);
534  
535 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // no ciphered data processed yet
536 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._cipherLength = 0;
537  
538 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // default additional data is none
539 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var additionalData;
540 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if('additionalData' in options) {
541 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { additionalData = forge.util.createBuffer(options.additionalData);
542 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { } else {
543 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { additionalData = forge.util.createBuffer();
544 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
545  
546 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // default tag length is 128 bits
547 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if('tagLength' in options) {
548 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._tagLength = options.tagLength;
549 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { } else {
550 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._tagLength = 128;
551 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
552  
553 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // if tag is given, ensure tag matches tag length
554 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._tag = null;
555 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(options.decrypt) {
556 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // save tag to check later
557 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._tag = forge.util.createBuffer(options.tag).getBytes();
558 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(this._tag.length !== (this._tagLength / 8)) {
559 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { throw new Error('Authentication tag does not match tag length.');
560 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
561 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
562  
563 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // create tmp storage for hash calculation
564 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._hashBlock = new Array(this._ints);
565  
566 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // no tag generated yet
567 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.tag = null;
568  
569 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // generate hash subkey
570 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // (apply block cipher to "zero" block)
571 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._hashSubkey = new Array(this._ints);
572 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.cipher.encrypt([0, 0, 0, 0], this._hashSubkey);
573  
574 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // generate table M
575 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // use 4-bit tables (32 component decomposition of a 16 byte value)
576 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // 8-bit tables take more space and are known to have security
577 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // vulnerabilities (in native implementations)
578 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.componentBits = 4;
579 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._m = this.generateHashTable(this._hashSubkey, this.componentBits);
580  
581 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // Note: support IV length different from 96 bits? (only supporting
582 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // 96 bits is recommended by NIST SP-800-38D)
583 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // generate J_0
584 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var ivLength = iv.length();
585 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(ivLength === 12) {
586 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // 96-bit IV
587 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._j0 = [iv.getInt32(), iv.getInt32(), iv.getInt32(), 1];
588 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { } else {
589 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // IV is NOT 96-bits
590 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._j0 = [0, 0, 0, 0];
591 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { while(iv.length() > 0) {
592 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._j0 = this.ghash(
593 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._hashSubkey, this._j0,
594 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { [iv.getInt32(), iv.getInt32(), iv.getInt32(), iv.getInt32()]);
595 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
596 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._j0 = this.ghash(
597 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._hashSubkey, this._j0, [0, 0].concat(from64To32(ivLength * 8)));
598 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
599  
600 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // generate ICB (initial counter block)
601 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._inBlock = this._j0.slice(0);
602 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { inc32(this._inBlock);
603 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = 0;
604  
605 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // consume authentication data
606 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { additionalData = forge.util.createBuffer(additionalData);
607 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // save additional data length as a BE 64-bit number
608 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._aDataLength = from64To32(additionalData.length() * 8);
609 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // pad additional data to 128 bit (16 byte) block size
610 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var overflow = additionalData.length() % this.blockSize;
611 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(overflow) {
612 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { additionalData.fillWithByte(0, this.blockSize - overflow);
613 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
614 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._s = [0, 0, 0, 0];
615 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { while(additionalData.length() > 0) {
616 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._s = this.ghash(this._hashSubkey, this._s, [
617 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { additionalData.getInt32(),
618 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { additionalData.getInt32(),
619 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { additionalData.getInt32(),
620 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { additionalData.getInt32()
621 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { ]);
622 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
623 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
624  
625 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.gcm.prototype.encrypt = function(input, output, finish) {
626 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // not enough input to encrypt
627 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var inputLength = input.length();
628 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(inputLength === 0) {
629 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return true;
630 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
631  
632 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // encrypt block
633 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.cipher.encrypt(this._inBlock, this._outBlock);
634  
635 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // handle full block
636 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(this._partialBytes === 0 && inputLength >= this.blockSize) {
637 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // XOR input with output
638 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
639 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putInt32(this._outBlock[i] ^= input.getInt32());
640 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
641 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._cipherLength += this.blockSize;
642 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { } else {
643 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // handle partial block
644 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var partialBytes = (this.blockSize - inputLength) % this.blockSize;
645 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(partialBytes > 0) {
646 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { partialBytes = this.blockSize - partialBytes;
647 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
648  
649 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // XOR input with output
650 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.clear();
651 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
652 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.putInt32(input.getInt32() ^ this._outBlock[i]);
653 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
654  
655 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(partialBytes === 0 || finish) {
656 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // handle overflow prior to hashing
657 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(finish) {
658 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // get block overflow
659 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var overflow = inputLength % this.blockSize;
660 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._cipherLength += overflow;
661 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // truncate for hash function
662 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.truncate(this.blockSize - overflow);
663 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { } else {
664 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._cipherLength += this.blockSize;
665 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
666  
667 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // get output block for hashing
668 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
669 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._outBlock[i] = this._partialOutput.getInt32();
670 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
671 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.read -= this.blockSize;
672 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
673  
674 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // skip any previous partial bytes
675 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(this._partialBytes > 0) {
676 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialOutput.getBytes(this._partialBytes);
677 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
678  
679 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(partialBytes > 0 && !finish) {
680 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // block still incomplete, restore input buffer, get partial output,
681 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // and return early
682 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { input.read -= this.blockSize;
683 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putBytes(this._partialOutput.getBytes(
684 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { partialBytes - this._partialBytes));
685 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = partialBytes;
686 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return true;
687 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
688  
689 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putBytes(this._partialOutput.getBytes(
690 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { inputLength - this._partialBytes));
691 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._partialBytes = 0;
692 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
693  
694 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // update hash block S
695 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._s = this.ghash(this._hashSubkey, this._s, this._outBlock);
696  
697 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // increment counter (input block)
698 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { inc32(this._inBlock);
699 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
700  
701 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.gcm.prototype.decrypt = function(input, output, finish) {
702 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // not enough input to decrypt
703 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var inputLength = input.length();
704 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(inputLength < this.blockSize && !(finish && inputLength > 0)) {
705 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return true;
706 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
707  
708 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // encrypt block (GCM always uses encryption mode)
709 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.cipher.encrypt(this._inBlock, this._outBlock);
710  
711 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // increment counter (input block)
712 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { inc32(this._inBlock);
713  
714 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // update hash block S
715 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._hashBlock[0] = input.getInt32();
716 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._hashBlock[1] = input.getInt32();
717 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._hashBlock[2] = input.getInt32();
718 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._hashBlock[3] = input.getInt32();
719 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._s = this.ghash(this._hashSubkey, this._s, this._hashBlock);
720  
721 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // XOR hash input with output
722 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
723 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.putInt32(this._outBlock[i] ^ this._hashBlock[i]);
724 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
725  
726 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // increment cipher data length
727 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(inputLength < this.blockSize) {
728 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._cipherLength += inputLength % this.blockSize;
729 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { } else {
730 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._cipherLength += this.blockSize;
731 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
732 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
733  
734 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.gcm.prototype.afterFinish = function(output, options) {
735 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var rval = true;
736  
737 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // handle overflow
738 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(options.decrypt && options.overflow) {
739 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { output.truncate(this.blockSize - options.overflow);
740 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
741  
742 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // handle authentication tag
743 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.tag = forge.util.createBuffer();
744  
745 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // concatenate additional data length with cipher length
746 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var lengths = this._aDataLength.concat(from64To32(this._cipherLength * 8));
747  
748 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // include lengths in hash
749 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this._s = this.ghash(this._hashSubkey, this._s, lengths);
750  
751 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // do GCTR(J_0, S)
752 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var tag = [];
753 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.cipher.encrypt(this._j0, tag);
754 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < this._ints; ++i) {
755 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.tag.putInt32(this._s[i] ^ tag[i]);
756 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
757  
758 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // trim tag to length
759 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.tag.truncate(this.tag.length() % (this._tagLength / 8));
760  
761 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // check authentication tag
762 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(options.decrypt && this.tag.bytes() !== this._tag) {
763 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { rval = false;
764 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
765  
766 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return rval;
767 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
768  
769 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {/**
770 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * See NIST SP-800-38D 6.3 (Algorithm 1). This function performs Galois
771 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * field multiplication. The field, GF(2^128), is defined by the polynomial:
772 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { *
773 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * x^128 + x^7 + x^2 + x + 1
774 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { *
775 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * Which is represented in little-endian binary form as: 11100001 (0xe1). When
776 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * the value of a coefficient is 1, a bit is set. The value R, is the
777 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * concatenation of this value and 120 zero bits, yielding a 128-bit value
778 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * which matches the block size.
779 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { *
780 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * This function will multiply two elements (vectors of bytes), X and Y, in
781 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * the field GF(2^128). The result is initialized to zero. For each bit of
782 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * X (out of 128), x_i, if x_i is set, then the result is multiplied (XOR'd)
783 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * by the current value of Y. For each bit, the value of Y will be raised by
784 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * a power of x (multiplied by the polynomial x). This can be achieved by
785 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * shifting Y once to the right. If the current value of Y, prior to being
786 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * multiplied by x, has 0 as its LSB, then it is a 127th degree polynomial.
787 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * Otherwise, we must divide by R after shifting to find the remainder.
788 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { *
789 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * @param x the first block to multiply by the second.
790 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * @param y the second block to multiply by the first.
791 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { *
792 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * @return the block result of the multiplication.
793 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { */
794 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.gcm.prototype.multiply = function(x, y) {
795 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var z_i = [0, 0, 0, 0];
796 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var v_i = y.slice(0);
797  
798 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // calculate Z_128 (block has 128 bits)
799 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < 128; ++i) {
800 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // if x_i is 0, Z_{i+1} = Z_i (unchanged)
801 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // else Z_{i+1} = Z_i ^ V_i
802 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // get x_i by finding 32-bit int position, then left shift 1 by remainder
803 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var x_i = x[(i / 32) | 0] & (1 << (31 - i % 32));
804 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(x_i) {
805 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { z_i[0] ^= v_i[0];
806 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { z_i[1] ^= v_i[1];
807 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { z_i[2] ^= v_i[2];
808 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { z_i[3] ^= v_i[3];
809 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
810  
811 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // if LSB(V_i) is 1, V_i = V_i >> 1
812 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // else V_i = (V_i >> 1) ^ R
813 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { this.pow(v_i, v_i);
814 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
815  
816 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return z_i;
817 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
818  
819 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.gcm.prototype.pow = function(x, out) {
820 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // if LSB(x) is 1, x = x >>> 1
821 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // else x = (x >>> 1) ^ R
822 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var lsb = x[3] & 1;
823  
824 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // always do x >>> 1:
825 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // starting with the rightmost integer, shift each integer to the right
826 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // one bit, pulling in the bit from the integer to the left as its top
827 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // most bit (do this for the last 3 integers)
828 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 3; i > 0; --i) {
829 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { out[i] = (x[i] >>> 1) | ((x[i - 1] & 1) << 31);
830 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
831 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // shift the first integer normally
832 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { out[0] = x[0] >>> 1;
833  
834 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // if lsb was not set, then polynomial had a degree of 127 and doesn't
835 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // need to divided; otherwise, XOR with R to find the remainder; we only
836 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // need to XOR the first integer since R technically ends w/120 zero bits
837 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { if(lsb) {
838 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { out[0] ^= this._R;
839 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
840 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
841  
842 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.gcm.prototype.tableMultiply = function(x) {
843 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // assumes 4-bit tables are used
844 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var z = [0, 0, 0, 0];
845 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < 32; ++i) {
846 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var idx = (i / 8) | 0;
847 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var x_i = (x[idx] >>> ((7 - (i % 8)) * 4)) & 0xF;
848 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var ah = this._m[i][x_i];
849 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { z[0] ^= ah[0];
850 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { z[1] ^= ah[1];
851 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { z[2] ^= ah[2];
852 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { z[3] ^= ah[3];
853 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { }
854 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return z;
855 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
856  
857 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {/**
858 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * A continuing version of the GHASH algorithm that operates on a single
859 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * block. The hash block, last hash value (Ym) and the new block to hash
860 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * are given.
861 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { *
862 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * @param h the hash block.
863 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * @param y the previous value for Ym, use [0, 0, 0, 0] for a new hash.
864 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * @param x the block to hash.
865 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { *
866 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * @return the hashed value (Ym).
867 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { */
868 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.gcm.prototype.ghash = function(h, y, x) {
869 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { y[0] ^= x[0];
870 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { y[1] ^= x[1];
871 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { y[2] ^= x[2];
872 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { y[3] ^= x[3];
873 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { return this.tableMultiply(y);
874 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { //return this.multiply(y, h);
875 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {};
876  
877 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {/**
878 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * Precomputes a table for multiplying against the hash subkey. This
879 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * mechanism provides a substantial speed increase over multiplication
880 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * performed without a table. The table-based multiplication this table is
881 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * for solves X * H by multiplying each component of X by H and then
882 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * composing the results together using XOR.
883 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { *
884 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * This function can be used to generate tables with different bit sizes
885 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * for the components, however, this implementation assumes there are
886 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * 32 components of X (which is a 16 byte vector), therefore each component
887 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * takes 4-bits (so the table is constructed with bits=4).
888 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { *
889 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * @param h the hash subkey.
890 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { * @param bits the bit size for a component.
891 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { */
892 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {modes.gcm.prototype.generateHashTable = function(h, bits) {
893 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // TODO: There are further optimizations that would use only the
894 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // first table M_0 (or some variant) along with a remainder table;
895 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { // this can be explored in the future
896 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var multiplier = 8 / bits;
897 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var perInt = 4 * multiplier;
898 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var size = 16 * multiplier;
899 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var m = new Array(size);
900 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { for(var i = 0; i < size; ++i) {
901 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var tmp = [0, 0, 0, 0];
902 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var idx = (i / perInt) | 0;
903 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { var shft = ((perInt - 1 - (i % perInt)) * bits);
904 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) { tmp[idx] = (1 << (bits - 1)) << shft;
905 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft; m[i] = this.generateSubHashTable(this.multiply(tmp, h), bits);
906 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft; }
907 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft; return m;
908 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;};
909  
910 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;/**
911 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft; * Generates a table for multiplying against the hash subkey for one
912 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft; * particular component (out of all possible component values).
913 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft; *
914 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft; * @param mid the pre-multiplied value for the middle key of the table.
915 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft; * @param bits the bit size for a component.
916 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft; */
917 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;modes.gcm.prototype.generateSubHashTable = function(mid, bits) {
918 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft; // compute the table quickly by minimizing the number of
919 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft; // POW operations -- they only need to be performed for powers of 2,
920 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft; // all other entries can be composed from those powers using XOR
921 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft; var size = 1 << bits;
922 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits; var half = size >>> 1;
923 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits; var m = new Array(size);
924 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits; m[half] = mid.slice(0);
925 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits; var i = half >>> 1;
926 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits; while(i > 0) {
927 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits; // raise m0[2 * i] and store in m0[i]
928 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits; this.pow(m[2 * i], m[i] = []);
929 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits; i >>= 1;
930 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits; }
931 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits; i = 2;
932 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits; while(i < half) {
933 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) { for(var j = 1; j < i; ++j) {
934 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { var m_i = m[i];
935 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { var m_j = m[j];
936 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { m[i + j] = [
937 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { m_i[0] ^ m_j[0],
938 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { m_i[1] ^ m_j[1],
939 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { m_i[2] ^ m_j[2],
940 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { m_i[3] ^ m_j[3]
941 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { ];
942 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { }
943 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { i *= 2;
944 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { }
945 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { m[0] = [0, 0, 0, 0];
946 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { /* Note: We could avoid storing these by doing composition during multiply
947 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { calculate top half using composition by speed is preferred. */
948 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) { for(i = half + 1; i < size; ++i) {
949 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) { var c = m[i ^ half];
950 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) { m[i] = [mid[0] ^ c[0], mid[1] ^ c[1], mid[2] ^ c[2], mid[3] ^ c[3]];
951 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) { }
952 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) { return m;
953 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {};
954  
955 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {/** Utility functions */
956  
957 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {function transformIV(iv) {
958 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) { if(typeof iv === 'string') {
959 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) { // convert iv string into byte buffer
960 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) { iv = forge.util.createBuffer(iv);
961 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) { }
962  
963 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) { if(forge.util.isArray(iv) && iv.length > 4) {
964 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) { // convert iv byte array into byte buffer
965 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) { var tmp = iv;
966 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) { iv = forge.util.createBuffer();
967 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) { for(var i = 0; i < tmp.length; ++i) {
968 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) { iv.putByte(tmp[i]);
969 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) { }
970 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) { }
971 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) { if(!forge.util.isArray(iv)) {
972 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) { // convert iv byte buffer into 32-bit integer array
973 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) { iv = [iv.getInt32(), iv.getInt32(), iv.getInt32(), iv.getInt32()];
974 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) { }
975  
976 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) { return iv;
977 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) {}
978  
979 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) {function inc32(block) {
980 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) { // increment last 32 bits of block only
981 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) { block[block.length - 1] = (block[block.length - 1] + 1) & 0xFFFFFFFF;
982 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) {}
983  
984 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) {function from64To32(num) {
985 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) { // convert 64-bit number to two BE Int32s
986 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) { return [(num / 0x100000000) | 0, num & 0xFFFFFFFF];
987 < this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {< this.blockSize && !(finish && input.length() >< this._ints; ++i) {< this._ints; ++i) {<< 2)) {< 2)) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {< this._ints; ++i) {<< (bits - 1)) << shft;< (bits - 1)) << shft;<< shft;< shft;<< bits;< bits;< half) {< i; ++j) {< size; ++i) {< tmp.length; ++i) {}