ZGlmZiAtLWdpdCBhL05PVElDRSBiL05PVElDRQppbmRleCBkODU3YmEzLi4xNTJiZTIwIDEwMDY0NAotLS0gYS9OT1RJQ0UKKysrIGIvTk9USUNFCkBAIC03Miw2ICs3MiwxNiBAQAogT0YgQU5ZIEtJTkQsIGVpdGhlciBleHByZXNzIG9yIGltcGxpZWQ7IG5vdCBldmVuIHRoZSBpbXBsaWVkIHdhcnJhbnR5CiBvZiBNRVJDSEFOVEFCSUxJVFkgb3IgRklUTkVTUyBGT1IgQSBQQVJUSUNVTEFSIFBVUlBPU0UuCiAKKyAgID09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KKyAgID09ICBOT1RJQ0UgZmlsZSBjb3JyZXNwb25kaW5nIHRvIHRoZSBzZWN0aW9uIDQgZCBvZiAgICAgICAgICAgICAgICAgICAgPT0KKyAgID09ICB0aGUgQXBhY2hlIExpY2Vuc2UsIFZlcnNpb24gMi4wLCAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgPT0KKyAgID09ICBpbiB0aGlzIGNhc2UgZm9yIEFkZGl0aW9uYWwgQ29kZWNzIGNvZGUuICAgICAgICAgICAgICAgICAgICAgICAgICAgPT0KKyAgID09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KKworQWRkaXRpb25hbCBDb2RlY3MKK1RoZXNlIGZpbGVzIGFyZSBDb3B5cmlnaHQgMjAwMy0yMDEwIFZpc3VhbE9uLCBidXQgcmVsZWFzZWQgdW5kZXIKK3RoZSBBcGFjaGUyIExpY2Vuc2UuCisKICAgPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQogICA9PSAgTk9USUNFIGZpbGUgY29ycmVzcG9uZGluZyB0byB0aGUgc2VjdGlvbiA0IGQgb2YgIC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A9PSBudWxsKSB7CisgICAgICAgICAgICAgICAgbGlzdCA9IG5ldyBBcnJheUxpc3Q8T25BY3Rpdml0eVBhdXNlZExpc3RlbmVyPigpOworICAgICAgICAgICAgICAgIG1PblBhdXNlTGlzdGVuZXJzLnB1dChhY3Rpdml0eSwgbGlzdCk7CisgICAgICAgICAgICB9CisgICAgICAgICAgICBsaXN0LmFkZChsaXN0ZW5lcik7CisgICAgICAgIH0KKyAgICB9CisKICAgICBwdWJsaWMgZmluYWwgQWN0aXZpdHlJbmZvIHJlc29sdmVBY3Rpdml0eUluZm8oSW50ZW50IGludGVudCkgewogICAgICAgICBBY3Rpdml0eUluZm8gYUluZm8gPSBpbnRlbnQucmVzb2x2ZUFjdGl2aXR5SW5mbygKICAgICAgICAgICAgICAgICBtSW5pdGlhbEFwcGxpY2F0aW9uLmdldFBhY2thZ2VNYW5hZ2VyKCksIFBhY2thZ2VNYW5hZ2VyLkdFVF9TSEFSRURfTElCUkFSWV9GSUxFUyk7CkBAIC0yNDQyLDYgKzI0NTcsMTcgQEAKICAgICAgICAgICAgIH0KICAgICAgICAgfQogICAgICAgICByLnBhdXNlZCA9IHRydWU7CisKKyAgICAgICAgLy8gTm90aWZ5IGFueSBvdXRzdGFuZGluZyBvbiBwYXVzZWQgbGlzdGVuZXJzCisgICAgICAgIEFycmF5TGlzdDxPbkFjdGl2aXR5UGF1c2VkTGlzdGVuZXI+IGxpc3RlbmVyczsKKyAgICAgICAgc3luY2hyb25pemVkIChtT25QYXVzZUxpc3RlbmVycykgeworICAgICAgICAgICAgbGlzdGVuZXJzID0gbU9uUGF1c2VMaXN0ZW5lcnMucmVtb3ZlKHIuYWN0aXZpdHkpOworICAgICAgICB9CisgICAgICAgIGludCBzaXplID0gKGxpc3RlbmVycyAhPSBudWxsID8gbGlzdGVuZXJzLnNpemUoKSA6IDApOworICAgICAgICBmb3IgKGludCBpID0gMDsgaSA8IHNpemU7IGkrKykgeworICAgICAgICAgICAgbGlzdGVuZXJzLmdldCh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QganVzdCBjb250YWlucwpAQCAtMTk3LDggKzIxMyw3IEBACiAgICAgLy8gYXR0ZW1wdERlYWRTZXJ2aWNlUmVjb3ZlcnkoKSB3aGVuIE5GQyBjcmFzaGVzIC0gd2UgYWNjZXB0IGEgYmVzdCBlZmZvcnQKICAgICAvLyByZWNvdmVyeQogICAgIHByaXZhdGUgc3RhdGljIElOZmNBZGFwdGVyIHNTZXJ2aWNlOwotCi0gICAgcHJpdmF0ZSBmaW5hbCBDb250ZXh0IG1Db250ZXh0OworICAgIHByaXZhdGUgc3RhdGljIElOZmNUYWcgc1RhZ1NlcnZpY2U7CiAKICAgICAvKioKICAgICAgKiBIZWxwZXIgdG8gY2hlY2sgaWYgdGhpcyBkZXZpY2UgaGFzIEZFQVRVUkVfTkZDLCBidXQgd2l0aG91dCB1c2luZwpAQCAtMjM1LDYgKzI1MCwxMiBAQAogICAgICAgICAgICAgICAgIExvZy5lKFRBRywgImNvdWxkIG5vdCByZXRyaWV2ZSBORkMgc2VydmljZSIpOwogICAgICAgICAgICAgICAgIHJldHVybiBudWxsOwogICAgICAgICAgICAgfQorICAgICAgICAgICAgdHJ5IHsKKyAgICAgICAgICAgICAgICBzVGFnU2VydmljZSA9IHNTZXJ2aWNlLmdldE5mY1RhZ0ludGVyZmFjZSgpOworICAgICAgICAgICAgfSBjYXRjaCAoUmVtb3RlRXhjZXB0aW9uIGUpIHsKKyAgICAgICAgICAgICAgICBMb2cuZShUQUcsICJjb3VsZCBub3QgcmV0cmlldmUgTkZDIFRhZyBzZXJ2aWNlIik7CisgICAgICAgICAgICAgICAgcmV0dXJuIG51bGw7CisgICAgICAgICAgICB9CiAgICAgICAgIH0KICAgICAgICAgcmV0dXJuIHNTZXJ2aWNlOwogICAgIH0KQEAgLTI4OSw3ICszMTAsNiBAQAogICAgICAgICBpZiAoc2V0dXBTZXJ2aWNlKCkgPT0gbnVsbCkgewogICAgICAgICAgICAgdGhyb3cgbmV3IFVuc3VwcG9ydGVkT3BlcmF0aW9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RlbnQgaW50ZW50LAorICAgICAgICAgICAgSW50ZW50RmlsdGVyLi4uIGZpbHRlcnMpIHsKKyAgICAgICAgaWYgKGFjdGl2aXR5ID09IG51bGwgfHwgaW50ZW50ID09IG51bGwgfHwgZmlsdGVycyA9PSBudWxsKSB7CisgICAgICAgICAgICB0aHJvdyBuZXcgTnVsbFBvaW50ZXJFeGNlcHRpb24oKTsKKyAgICAgICAgfQorICAgICAgICBpZiAoIWFjdGl2aXR5LmlzUmVzdW1lZCgpKSB7CisgICAgICAgICAgICB0aHJvdyBuZXcgSWxsZWdhbFN0YXRlRXhjZXB0aW9uKCJGb3JlZ29ydW5kIGRpc3BhdGNoaW5nIGNhbiBvbmxseSBiZSBlbmFibGVkICIgKworICAgICAgICAgICAgICAgICAgICAid2hlbiB5b3VyIGFjdGl2aXR5IGlzIHJlc3VtZWQiKTsKKyAgICAgICAgfQorICAgICAgICB0cnkgeworICAgICAgICAgICAgQWN0aXZpdHlUaHJlYWQuY3VycmVudEFjdGl2aXR5VGhyZWFkKCkucmVnaXN0ZXJPbkFjdGl2aXR5UGF1c2VkTGlzdGVuZXIoYWN0aXZpdHksCisgICAgICAgICAgICAgICAgICAgIG5ldyBGb3JlZ3JvdW5kRGlzcGF0Y2hQYXVzZWRMaXN0ZW5lcigpKTsKKyAgICAgICAgICAgIHNTZXJ2aWNlLmVuYWJsZUZvcmVncm91bmREaXNwYXRjaChhY3Rpdml0eS5nZXRDb21wb25lbnROYW1lKCksIGludGVudCwgZmlsdGVycyk7CisgICAgICAgIH0gY2F0Y2ggKFJlbW90ZUV4Y2VwdGlvbiBlKSB7CisgICAgICAgICAgICBhdHRlbXB0RGVhZFNlcnZpY2VSZWNvdmVyeShlKTsKKyAgICAgICAgfQorICAgIH0KKworICAgIC8qKgorICAgICAqIERpc2FibGVzIGZvcmVncm91bmQgYWN0aXZpdHkgZGlzcGF0Y2hpbmcgc2V0dXAgd2l0aAorICAgICAqIHtAbGluayAjZW5hYmxlRm9yZWdyb3V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sKICAgICAgICAgfQogICAgIH0KQEAgLTE4MywyMSArMTYxLDIxIEBACiAgICAgcHVibGljIHZvaWQgcmVjb25uZWN0KCkgdGhyb3dzIElPRXhjZXB0aW9uIHsKICAgICAgICAgaWYgKCFtSXNDb25uZWN0ZWQpIHsKICAgICAgICAgICAgIHRocm93IG5ldyBJbGxlZ2FsU3RhdGVFeGNlcHRpb24oIlRlY2hub2xvZ3kgbm90IGNvbm5lY3RlZCB5ZXQiKTsKLSAgICAgICAgfSBlbHNlIHsKLSAgICAgICAgICAgIHRyeSB7Ci0gICAgICAgICAgICAgICAgaW50IGVycm9yQ29kZSA9IG1UYWdTZXJ2aWNlLnJlY29ubmVjdChtVGFnLmdldFNlcnZpY2VIYW5kbGUoKSk7CisgICAgICAgIH0KIAotICAgICAgICAgICAgICAgIGlmIChlcnJvckNvZGUgIT0gRXJyb3JDb2Rlcy5TVUNDRVNTKSB7Ci0gICAgICAgICAgICAgICAgICAgIG1Jc0Nvbm5lY3RlZCA9IGZhbHNlOwotICAgICAgICAgICAgICAgICAgICBtVGFnLnNldFRlY2hub2xvZ3lEaXNjb25uZWN0ZWQoKTsKLSAgICAgICAgICAgICAgICAgICAgdGhyb3cgbmV3IElPRXhjZXB0aW9uKCk7Ci0gICAgICAgICAgICAgICAgfQotICAgICAgICAgICAgfSBjYXRjaCAoUmVtb3RlRXhjZXB0aW9uIGUpIHsKKyAgICAgICAgdHJ5IHsKKyAgICAgICAgICAgIGludCBlcnJvckNvZGUgPSBtVGFnU2VydmljZS5yZWNvbm5lY3QobVRhZy5nZXRTZXJ2aWNlSGFuZGxlKCkpOworCisgICAgICAgICAgICBpZiAoZXJyb3JDb2RlICE9IEVycm9yQ29kZXMuU1VDQ0VTUykgewogICAgICAgICAgICAgICAgIG1Jc0Nvbm5lY3RlZCA9IGZhbHNlOwogICAgICAgICAgICAgICAgIG1UYWcuc2V0VGVjaG5vbG9neURpc2Nvbm5lY3RlZCgpOwotICAgICAgICAgICAgICAgIGF0dGVtcHREZWFkU2VydmljZVJlY292ZXJ5KGUpOwotICAgICAgICAgICAgICAgIHRocm93IG5ldyBJT0V4Y2VwdGlvbigiTkZDIHNlcnZpY2UgZGllZCIpOworICAgICAgICAgICAgICAgIHRocm93IG5ldyBJT0V4Y2VwdGlvbigpOwogICAgICAgICAgICAgfQorICAgICAgICB9IGNhdGNoIChSZW1vdGVFeGNlcHRpb24gZSkgeworICAgICAgICAgICAgbUlzQ29ubmVjdGVkID0gZmFsc2U7CisgICAgICAgICAgICBtVGFnLnNldFRlY2hub2xvZ3lEaXNjb25uZWN0ZWQoKTsKKyAgICAgICAgICAgIExvZy5lKFRBRywgIk5GQyBzZXJ2aWNlIGRlYWQiLCBlKTsKKyAgICAgICAgICAgIHRocm93IG5ldyBJT0V4Y2VwdGlvbigiTkZDIHNlcnZpY2UgZGllZCIpOwogICAgICAgICB9CiAgICAgfQogCkBAIC0yMTksMTMgKzE5NywyOSBAQAogICAgICAgICAgICAgICovCiAgICAgICAgICAgICBtVGFnU2VydmljZS5yZWNvbm5lY3QobVRhZy5nZXRTZXJ2aWNlSGFuZGxlKCkpOwogICAgICAgICB9IGNhdGNoIChSZW1vdGVFeGNlcHRpb24gZSkgewotICAgICAgICAgICAgYXR0ZW1wdERlYWRTZXJ2aWNlUmVjb3ZlcnkoZSk7CisgICAgICAgICAgICBMb2cuZShUQUcsICJORkMgc2VydmljZSBkZWFkIiwgZSk7CiAgICAgICAgIH0gZmluYWxseSB7CiAgICAgICAgICAgICBtSXNDb25uZWN0ZWQgPSBmYWxzZTsKICAgICAgICAgICAgIG1UYWcuc2V0VGVjaG5vbG9neURpc2Nvbm5lY3RlZCgpOwogICAgICAgICB9CiAgICAgfQogCisgICAgLyoqIGludGVybmFsIHRyYW5zY2VpdmUgKi8KKyAgICAvKnBhY2thZ2UqLyBieXRlW10gdHJhbnNjZWl2ZShieXRlW10gZGF0YSwgYm9vbGVhbiByYXcpIHRocm93cyBJT0V4Y2VwdGlvbiB7CisgICAgICAgI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IGRlYWQiLCBlKTsKICAgICAgICAgfQogICAgIH0KIApAQCAtMjIxLDcgKzIyNCwyMiBAQAogICAgIH0KIAogICAgIC8qKgotICAgICAqIFNldCB0aGUgQ0MgZmllbGQgdG8gaW5kaWNhdGUgdGhpcyB0YWcgaXMgcmVhZC1vbmx5CisgICAgICogSW5kaWNhdGVzIHdoZXRoZXIgYSB0YWcgY2FuIGJlIG1hZGUgcmVhZC1vbmx5IHdpdGgKKyAgICAgKiB7QGxpbmsgI21ha2VSZWFkb25seSgpfQorICAgICAqLworICAgIHB1YmxpYyBib29sZWFuIGNhbk1ha2VSZWFkb25seSgpIHsKKyAgICAgICAgaWYgKG1OZGVmVHlwZSA9PSBORkNfRk9SVU1fVFlQRV8xIHx8IG1OZGVmVHlwZSA9PSBORkNfRk9SVU1fVFlQRV8yKSB7CisgICAgICAgICAgICByZXR1cm4gdHJ1ZTsKKyAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgIHJldHVybiBmYWxzZTsKKyAgICAgICAgfQorICAgIH0KKworICAgIC8qKgorICAgICAqIFNldHMgdGhlIENDIGZpZWxkIHRvIGluZGljYXRlIHRoaXMgdGFnIGlzIHJlYWQtb25seQorICAgICAqIGFuZCBwZXJtYW5lbnRseSBzZXRzIHRoZSBsb2NrIGJpdHMgdG8gcHJldmVudCBhbnkgZnVydGhlciBOREVGCisgICAgICogbW9kaWZpY2F0aW9ucy4KKyAgICAgKiBUaGlzIGlzIGEgb25lLXdheSBwcm9jZXNzIGFuZCBjYW4gbm90IGJlIHJldmVydGVkIQogICAgICAqIEB0aHJvd3MgSU9FeGNlcHRpb24KICAgICAgKi8KICAgICBwdWJsaWMgYm9vbGVhbiBtYWtlUmVhZG9ubHkoKSB0aHJvd3MgSU9FeGNlcHRpb24gewpAQCAtMjQxLDIyICsyNTksMTEgQEAKICAgICAgICAgICAgICAgICAgICAgdGhyb3cgbmV3IElPRXhjZXB0aW9uKCk7CiAgICAgICAgICAgICB9CiAgICAgICAgIH0g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pY2UuamF2YSBiL2NvcmUvamF2YS9hbmRyb2lkL3NlcnZpY2Uvd2FsbHBhcGVyL1dhbGxwYXBlclNlcnZpY2UuamF2YQppbmRleCA1MmIwNjQzLi5hODU5ZTNjIDEwMDY0NAotLS0gYS9jb3JlL2phdmEvYW5kcm9pZC9zZXJ2aWNlL3dhbGxwYXBlci9XYWxscGFwZXJTZXJ2aWNlLmphdmEKKysrIGIvY29yZS9qYXZhL2FuZHJvaWQvc2VydmljZS93YWxscGFwZXIvV2FsbHBhcGVyU2VydmljZS5qYXZhCkBAIC01MTcsOCArNTE3LDExIEBACiAgICAgICAgICAgICAgICAgICAgICAgICBtTGF5b3V0LndpbmRvd0FuaW1hdGlvbnMgPQogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb20uYW5kcm9pZC5pbnRlcm5hbC5SLnN0eWxlLkFuaW1hdGlvbl9XYWxscGFwZXI7CiAgICAgICAgICAgICAgICAgICAgICAgICBtSW5wdXRDaGFubmVsID0gbmV3IElucHV0Q2hhbm5lbCgpOwotICAgICAgICAgICAgICAgICAgICAgICAgbVNlc3Npb24uYWRkKG1XaW5kb3csIG1MYXlvdXQsIFZpZXcuVklTSUJMRSwgbUNvbnRlbnRJbnNldHMsCi0gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1JbnB1dENoYW5uZWwpOworICAgICAgICAgICAgICAgICAgICAgICAgaWYgKG1TZXNzaW9uLmFkZChtV2luZG93LCBtTGF5b3V0LCBWaWV3LlZJU0lCTEUsIG1Db250ZW50SW5zZXRzLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBtSW5wdXRDaGFubmVsKSA8IDApIHsKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICBMb2cudyhUQUcsICJGYWlsZWQgdG8gYWRkIHdpbmRvdyB3aGlsZSB1cGRhdGluZyB3YWxscGFwZXIgc3VyZmFjZS4iKTsKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm47CisgICAgICAgIC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yB2b2lkIG9uUmVjZWl2ZShDb250ZXh0IGNvbnRleHQsIEludGVudCBpbnRlbnQpIHsKLSAgICAgICAgICAgICAgICBpZiAobUxpdmUgJiYgaW50ZW50LmdldEFjdGlvbigpLmVxdWFscygKLSAgICAgICAgICAgICAgICAgICAgICAgICAgICBJbnRlbnQuQUNUSU9OX1RJTUVaT05FX0NIQU5HRUQpKSB7Ci0gICAgICAgICAgICAgICAgICAgIG1DYWxlbmRhciA9IENhbGVuZGFyLmdldEluc3RhbmNlKCk7Ci0gICAgICAgICAgICAgICAgfQotICAgICAgICAgICAgICAgIC8vIFBvc3QgYSBydW5uYWJsZSB0byBhdm9pZCBibG9ja2luZyB0aGUgYnJvYWRjYXN0LgotICAgICAgICAgICAgICAgIG1IYW5kbGVyLnBvc3QobmV3IFJ1bm5hYmxlKCkgewotICAgICAgICAgICAgICAgICAgICAgICAgcHVibGljIHZvaWQgcnVuKCkgewotICAgICAgICAgICAgICAgICAgICAgICAgICAgIHVwZGF0ZVRpbWUoKTsKKyAgICBwcml2YXRlIEJyb2FkY2FzdFJlY2VpdmVyIG1JbnRlbnRSZWNlaXZlcjsKKworICAgIHByaXZhdGUgc3RhdGljIGNsYXNzIFRpbWVDaGFuZ2VkUmVjZWl2ZXIgZXh0ZW5kcyBCcm9hZGNhc3RSZWNlaXZlciB7CisgICAgICAgIHByaXZhdGUgV2Vha1JlZmVyZW5jZTxEaWdpdGFsQ2xvY2s+IG1DbG9jazsKKyAgICAgICAgcHJpdmF0ZSBDb250ZXh0IG1Db250ZXh0OworCisgICAgICAgIHB1YmxpYyBUaW1lQ2hhbmdlZFJlY2VpdmVyKERpZ2l0YWxDbG9jayBjbG9jaykgeworICAgICAgICAgICAgbUNsb2NrID0gbmV3IFdlYWtSZWZlcmVuY2U8RGlnaXRhbENsb2NrPihjbG9jayk7CisgICAgICAgICAgICBtQ29udGV4dCA9IGNsb2NrLmdldENvbnRleHQoKTsKKyAgICAgICAgfQorCisgICAgICAgIEBPdmVycmlkZQorICAgICAgICBwdWJsaWMgdm9pZCBvblJlY2VpdmUoQ29udGV4dCBjb250ZXh0LCBJbnRlbnQgaW50ZW50KSB7CisgICAgICAgICAgICAvLyBQb3N0IGEgcnVubmFibGUgdG8gYXZvaWQgYmxvY2tpbmcgdGhlIGJyb2FkY2FzdC4KKyAgICAgICAgICAgIGZpbmFsIGJvb2xlYW4gdGltZXpvbmVDaGFuZ2VkID0KKyAgICAgICAgICAgICAgICAgICAgaW50ZW50LmdldEFjdGlvbigpLmVxdWFscyhJbnRlbnQuQUNUSU9OX1RJTUVaT05FX0NIQU5HRUQpOworICAgICAgICAgICAgZmluYWwgRGlnaXRhbENsb2NrIGNsb2NrID0gbUNsb2NrLmdldCgpOworICAgICAgICAgICAgaWYgKGNsb2NrICE9IG51bGwpIHsKKyAgICAgICAgICAgICAgICBjbG9jay5tSGFuZGxlci5wb3N0KG5ldyBSdW5uYWJsZSgpIHsKKyAgICAgICAgICAgICAgICAgICAgcHVibGljIHZvaWQgcnVuKCkgeworICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHRpbWV6b25lQ2hhbmdlZCkgeworICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNsb2NrLm1DYWxlbmRhciA9IENhbGVuZGFyLmdldEluc3RhbmNlKCk7CiAgICAgICAgICAgICAgICAgICAgICAgICB9CisgICAgICAgICAgICAgICAgICAgICAgICBjbG9jay51cGRhdGVUaW1lKCk7CisgICAgICAgICAgICAgICAgICAgIH0KICAgICAgICAgICAgICAgICB9KTsKKyAgICAgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICAgICAgbUNvbnRleHQudW5yZWdpc3RlclJlY2VpdmVyKHRoaXMpOwogICAgICAgICAgICAgfQotICAgICAgICB9OworICAgICAgICB9CisgICAgfTsKIAogICAgIHN0YXRpYyBjbGFzcyBBbVBtIHsKICAgICAgICAgcHJpdmF0ZSBUZXh0VmlldyBtQW1QbTsKQEAgLTk5LDE0ICsxMTUsMjMgQEAKICAgICAgIC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gICAgICAgICAgICAgIG1Db250ZXh0LmdldENvbnRlbnRSZXNvbHZlcigpLnVucmVnaXN0ZXJDb250ZW50T2JzZXJ2ZXIodGhpcyk7CisgICAgICAgICAgICB9CiAgICAgICAgIH0KICAgICB9CiAKQEAgLTEzOSwxMSArMTY0LDExIEBACiAgICAgcHJvdGVjdGVkIHZvaWQgb25BdHRhY2hlZFRvV2luZG93KCkgewogICAgICAgICBzdXBlci5vbkF0dGFjaGVkVG9XaW5kb3coKTsKIAotICAgICAgICBpZiAobUF0dGFjaGVkKSByZXR1cm47Ci0gICAgICAgIG1BdHRhY2hlZCA9IHRydWU7CisgICAgICAgIG1BdHRhY2hlZCsrOwogCi0gICAgICAgIGlmIChtTGl2ZSkgewotICAgICAgICAgICAgLyogbW9uaXRvciB0aW1lIHRpY2tzLCB0aW1lIGNoYW5nZWQsIHRpbWV6b25lICovCisgICAgICAgIC8qIG1vbml0b3IgdGltZSB0aWNrcywgdGltZSBjaGFuZ2VkLCB0aW1lem9uZSAqLworICAgICAgICBpZiAobUludGVudFJlY2VpdmVyID09IG51bGwpIHsKKyAgICAgICAgICAgIG1JbnRlbnRSZWNlaXZlciA9IG5ldyBUaW1lQ2hhbmdlZFJlY2VpdmVyKHRoaXMpOwogICAgICAgICAgICAgSW50ZW50RmlsdGVyIGZpbHRlciA9IG5ldyBJbnRlbnRGaWx0ZXIoKTsKICAgICAgICAgICAgIGZpbHRlci5hZGRBY3Rpb24oSW50ZW50LkFDVElPTl9USU1FX1RJQ0spOwogICAgICAgICAgICAgZmlsdGVyLmFkZEFjdGlvbihJbnRlbnQuQUNUSU9OX1RJTUVfQ0hBTkdFRCk7CkBAIC0xNTIsOSArMTc3LDExIEBACiAgICAgICAgIH0KIAogICAgICAgICAvKiBtb25pdG9yIDEyLzI0LWhvdXIgZGlzcGxheSBwcmVmZXJlbmNlICovCi0gICAgICAgIG1Gb3JtYXRDaGFuZ2VPYnNlcnZlciA9IG5ldyBGb3JtYXRDaGFuZ2VPYnNlcnZlcigpOwotICAgICAgICBtQ29udGV4dC5nZXRDb250ZW50UmVzb2x2ZXIoKS5yZWdpc3RlckNvbnRlbnRPYnNlcnZlcigKLSAgICAgICAgICAgICAgICBTZXR0aW5ncy5TeXN0ZW0uQ09OVEVOVF9VUkksIHRydWUsIG1Gb3JtYXRDaGFuZ2VPYnNlcnZlcik7CisgICAgICAgIGlmIChtRm9ybWF0Q2hhbmdlT2JzZXJ2ZXIgPT0gbnVsbCkgeworICAgICAgICAgICAgbUZvcm1hdENoYW5nZU9ic2VydmVyID0gbmV3IEZvcm1hdENoYW5nZU9ic2VydmVyKHRoaXMpOworICAgICAgICAgICAgbUNvbnRleHQuZ2V0Q29udGVudFJlc29sdmVyKCkucmVnaXN0ZXJDb250ZW50T2JzZXJ2ZXIoCisgICAgICAgICAgICAgICAgICAgIFNldHRpbmdzLlN5c3RlbS5DT05URU5UX1VSSSwgdHJ1ZSwgbUZvcm1hdENoYW5nZU9ic2VydmVyKTsKKyAgICAgICAgfQogCiAgICAgICAgIHVwZGF0ZVRpbWUoKTsKICAgICB9CkBAIC0xNjMsMTYgKzE5MCwxOSBAQAogICAgIHByb3RlY3RlZCB2b2lkIG9uRGV0YWNoZWRGcm9tV2luZG93KCkgewogICAgICAgICBzdXBlci5vbkRldGFjaGVkRnJvbVdpbmRvdygpOwogCi0gICAgICAgIGlmICghbUF0dGFjaGVkKSByZXR1cm47Ci0gICAgICAgIG1BdHRhY2hlZCA9IGZhbHNlOworICAgICAgICBtQXR0YWNoZWQtLTsKIAotICAgICAgICBpZiAobUxpdmUpIHsKKyAgICAgICAgaWYgKG1JbnRlbnRSZWNlaXZlciAhPSBudWxsKSB7CiAgICAgICAgICAgICBtQ29udGV4dC51bnJlZ2lzdGVyUmVjZWl2ZXIobUludGVudFJlY2VpdmVyKTsKICAgICAgICAgfQotICAgICAgICBtQ29udGV4dC5nZXRDb250ZW50UmVzb2x2ZXIoKS51bnJlZ2lzdGVyQ29udGVudE9ic2VydmVyKAotICA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RQYXRoKCk7CisgICAgICAgICAgICB9IGVsc2UgaWYgKHNjaGVtZS5lcXVhbHMoQ29udGVudFJlc29sdmVyLlNDSEVNRV9DT05URU5UKSkgeworICAgICAgICAgICAgICAgIFN0cmluZ1tdIHByb2plY3Rpb24gPSBuZXcgU3RyaW5nW10ge01lZGlhU3RvcmUuTWVkaWFDb2x1bW5zLkRBVEF9OworICAgICAgICAgICAgICAgIEN1cnNvciBjdXJzb3IgPSBudWxsOworICAgICAgICAgICAgICAgIHRyeSB7CisgICAgICAgICAgICAgICAgICAgIGN1cnNvciA9IG1Db250ZXh0LmdldENvbnRlbnRSZXNvbHZlcigpLnF1ZXJ5KHVyaSwgcHJvamVjdGlvbiwgbnVsbCwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICBudWxsLCBudWxsKTsKKyAgICAgICAgICAgICAgICAgICAgaWYgKG51bGwgPT0gY3Vyc29yIHx8IDAgPT0gY3Vyc29yLmdldENvdW50KCkgfHwgIWN1cnNvci5tb3ZlVG9GaXJzdCgpKSB7CisgICAgICAgICAgICAgICAgICAgICAgICB0aHJvdyBuZXcgSWxsZWdhbEFyZ3VtZW50RXhjZXB0aW9uKCJHaXZlbiBVcmkgY291bGQgbm90IGJlIGZvdW5kIiArCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICIgaW4gbWVkaWEgc3RvcmUiKTsKKyAgICAgICAgICAgICAgICAgICAgfQorICAgICAgICAgICAgICAgICAgICBpbnQgcGF0aEluZGV4ID0gY3Vyc29yLmdldENvbHVtbkluZGV4T3JUaHJvdyhNZWRpYVN0b3JlLk1lZGlhQ29sdW1ucy5EQVRBKTsKKyAgICAgICAgICAgICAgICAgICAgcGF0aCA9IGN1cnNvci5nZXRTdHJpbmcocGF0aEluZGV4KTsKKyAgICAgICAgICAgICAgICB9IGNhdGNoIChTUUxpdGVFeGNlcHRpb24gZSkgeworICAgICAgICAgICAgICAgICAgICB0aHJvdyBuZXcgSWxsZWdhbEFyZ3VtZW50RXhjZXB0aW9uKCJHaXZlbiBVcmkgaXMgbm90IGZvcm1hdHRlZCBpbiBhIHdheSAiICsKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAic28gdGhhdCBpdCBjYW4gYmUgZm91bmQgaW4gbWVkaWEgc3RvcmUuIik7CisgICAgICAgICAgICAgICAgfSBmaW5hbGx5IHsKKyAgICAgICAgICAgICAgICAgICAgaWYgKG51bGwgIT0gY3Vyc29yKSB7CisgICAgICAgICAgICAgICAgICAgICAgICBjdXJzb3IuY2xvc2UoKTsKKyAgICAgICAgICAgICAgICAgICAgfQorICAgICAgICAgICAgICAgIH0KKyAgICAgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICAgICAgdGhyb3cgbmV3IElsbGVnYWxBcmd1bWVudEV4Y2VwdGlvbigiR2l2ZW4gVXJpIHNjaGVtZSBpcyBub3Qgc3VwcG9ydGVkIik7CiAgICAgICAgICAgICB9Ci0gICAgICAgICAgICBpZiAobnVsbCA9PSBjdXJzb3IgfHwgMCA9PSBjdXJzb3IuZ2V0Q291bnQoKSB8fCAhY3Vyc29yLm1vdmVUb0ZpcnN0KCkpIHsKLSAgICAgICAgICAgICAgICB0aHJvdyBuZXcgSWxsZWdhbEFyZ3VtZW50RXhjZXB0aW9uKCJHaXZlbiBVcmkgY291bGQgbm90IGJlIGZvdW5kIGluIG1lZGlhIHN0b3JlIik7Ci0gICAgICAgICAgICB9Ci0gICAgICAgICAgICBpbnQgcGF0aEluZGV4ID0gY3Vyc29yLmdldENvbHVtbkluZGV4T3JUaHJvdyhNZWRpYVN0b3JlLk1lZGlhQ29sdW1ucy5EQVRBKTsKLSAgICAgICAgICAgIHBhdGggPSBjdXJzb3IuZ2V0U3RyaW5nKHBhdGhJbmRleCk7Ci0gICAgICAgICAgICBjdXJzb3IuY2xvc2UoKTsKLSAgICAgICAgfSBlbHNlIHsKLSAgICAgICAgICAgIHRocm93IG5ldyBJbGxlZ2FsQXJndW1lbnRFeGNlcHRpb24oIkdpdmVuIF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UEVfSU1BR0UsICAgICAgIG1pbWVfZ3JvdXBfaW1hZ2UsICAgICAgICBzaXplb2YobWltZV9ncm91cF9pbWFnZSktMX0sCisgICAge01JTUVUWVBFX1ZJREVPLCAgICAgICBtaW1lX2dyb3VwX3ZpZGVvLCAgICAgICAgc2l6ZW9mKG1pbWVfZ3JvdXBfdmlkZW8pLTF9LAorICAgIHtNSU1FVFlQRV9MQVNULCAgICAgICAgTlVMTCwgICAgICAgICAgICAgICAgICAgIDB9IC8vIE11c3QgYmUgbGFzdCBlbnRyeQorfTsKKworLy8gTGlzdCBvZiBhbGwgbWltZXR5cGVzIHRoYXQgc2hvdWxkIGJlIGNvbnZlcnRlZC4KK3N0YXRpYyBzdHJ1Y3QgTWltZVR5cGVMaXN0IG1pbWVUeXBlTGlzdFtdID0geworICAgIC8vIE1wMyBtaW1lIHR5cGVzCisgICAge01JTUVUWVBFX0FVRElPLCAibXAzIiwgICAgICAgICAgc2l6ZW9mKCJtcDMiKS0xLCAgICAgICAgIG1pbWVfdHlwZV9hdWRpb19tcGVnfSwKKyAgICB7TUlNRVRZUEVfQVVESU8sICJ4LW1wZWciLCAgICAgICBzaXplb2YoIngtbXBlZyIpLTEsICAgICAgbWltZV90eXBlX2F1ZGlvX21wZWd9LAorICAgIHtNSU1FVFlQRV9BVURJTywgIngtbXAzIiwgICAgICAgIHNpemVvZigieC1tcDMiKS0xLCAgICAgICBtaW1lX3R5cGVfYXVkaW9fbXBlZ30sCisgICAge01JTUVUWVBFX0FVRElPLCAibXBnIiwgICAgICAgICAgc2l6ZW9mKCJtcGciKS0xLCAgICAgICAgIG1pbWVfdHlwZV9hdWRpb19tcGVnfSwKKyAgICB7TUlNRVRZUEVfQVVESU8sICJtcGczIiwgICAgICAgICBzaXplb2YoIm1wZyIpLTEsICAgICAgICAgbWltZV90eXBlX2F1ZGlvX21wZWd9LAorICAgIHtNSU1FVFlQRV9BVURJTywgIngtbXBnIiwgICAgICAgIHNpemVvZigieC1tcGciKS0xLCA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3AiLCAgICAgICAgICBzaXplb2YoIjNncCIpLTEsICAgICAgICAgbWltZV90eXBlX3ZpZGVvXzNncHB9LAorCisgICAgLy8gTXVzdCBiZSBsYXN0IGVudHJ5CisgICAge01JTUVUWVBFX0xBU1QsICBOVUxMLCAgICAgICAgICAgMCwgICAgICAgICAgICAgICAgICAgICAgIE5VTEx9Cit9OworCisvKioKKyAqIE1heSBjb252ZXJ0IHRoZSBtaW1ldHlwZSBpZiB0aGVyZSBpcyBhIHdlbGwga25vd24KKyAqIHJlcGxhY2VtZW50IG1pbWV0eXBlIG90aGVyd2lzZSB0aGUgb3JpZ2luYWwgbWltZXR5cGUKKyAqIGlzIHJldHVybmVkLgorICoKKyAqIEBwYXJhbSBtaW1lVHlwZSAtIG1pbWV0eXBlIGluIGxvd2VyIGNhc2UgdG8gY29udmVydC4KKyAqCisgKiBAcmV0dXJuIG1pbWV0eXBlIG9yIG51bGwuCisgKi8KK1N0cmluZzggTWltZVR5cGVVdGlsOjpjb252ZXJ0TWltZVR5cGUoU3RyaW5nOCYgbWltZVR5cGUpIHsKKyAgICBTdHJpbmc4IHJlc3VsdCA9IG1pbWVUeXBlOworICAgIGNvbnN0IGNoYXIqIHBUbXA7CisgICAgY29uc3QgY2hhciogcE1pbWVUeXBlOworICAgIHN0cnVjdCBNaW1lR3JvdXAqIHBHcm91cDsKKyAgICBzdHJ1Y3QgTWltZVR5cGVMaXN0KiBwTWltZUl0ZW07CisgICAgaW50IGxlbjsKKworICAgIHBNaW1lVHlwZSA9IG1pbWVUeXBlLnN0cmluZygpOworICAgIGlmIChOVUxMICE9IHBNaW1lVHlwZSkgeworICAgICAgICAvKiBDaGVjayB3aGljaCBncm91cCB0aGUgbWltZXR5cGUgaXMgKi8KKyAgICAgICAgcEdyb3VwID0gbWltZUdyb3VwOworCisgICAgICAgIHdoaWxlIChNSU1FVFlQRV9MQVNUICE9IHBHcm91cC0+dHlwZSkgeworICAgICAgICAgICAgaWYgKDAgPT0gc3RybmNtcChwTWltZVR5cGUsIHBHcm91cC0+cEdyb3VwLCBwR3JvdXAtPnNpemUpKSB7CisgICAgICAgICAgICAgICAgYnJlYWs7CisgICAgICAgICAgICB9CisgICAgICAgICAgICBwR3JvdXArKzsKKyAgICAgICAgfQorCisgICAgICAgIC8qIEdvIHRocm91Z2ggdGhlIG1pbWV0eXBlIGxpc3QuIE9ubHkgY2hlY2sgaXRlbXMgb2YgdGhlIGNvcnJlY3QgZ3JvdXAgKi8KKyAgICAgICAgaWYgKE1JTUVUWVBFX0xBU1QgIT0gcEdyb3VwLT50eXBlKSB7CisgICAgICAgICAgICBwTWltZUl0ZW0gPSBtaW1lVHlwZUxpc3Q7CisgICAgICAgICAgICBsZW4gPSBzdHJsZW4gKHBNaW1lVHlwZStwR3JvdXAtPnNpemUpOworCisgICAgICAgICAgICB3aGlsZSAoTUlNRVRZUEVfTEFTVCAhPSBwTWltZUl0ZW0tPnR5cGUpIHsKKyAgICAgICAgICAgICAgICBpZiAoKGxlbiA9PSBwTWltZUl0ZW0tPnNpemUpICYmCisgICAgICAgICAgICAgICAgICAgICgwID09IHN0cmNtcChwTWltZVR5cGUrcEdyb3VwLT5zaXplLCBwTWltZUl0ZW0tPnBNaW1lRXh0KSkpIHsKKyAgICAgICAgICAgICAgICAgICAgcmVzdWx0ID0gU3RyaW5nOChwTWltZUl0ZW0tPnBNaW1lVHlwZSk7CisgICAgICAgICAgICAgICAgICAgIGJyZWFrOworICAgICAgICAgICAgICAgIH0KKyAgICAgICAgICAgICAgICBwTWltZUl0ZW0rKzsKKyAgICAgICAgICAgIH0KKyAgICAgICAgfQorICAgICAgICBMT0dJKCJjb252ZXJ0TWltZVR5cGUgZ290IG1pbWV0eXBlICVzLCBjb252ZXJ0ZWQgaW50byBtaW1ldHlwZSAlcyIsCisgICAgICAgICAgICAgcE1pbWVUeXBlLCByZXN1bHQuc3RyaW5nKCkpOworICAgIH0KKworICAgIHJldHVybiByZXN1bHQ7Cit9Cit9OwpkaWZmIC0tZ2l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aW9uIHNlc3Npb24KKyAqIEBwYXJhbSBwbGF5YmFja1N0YXR1cyBQbGF5YmFjayBhY3Rpb24gKFBsYXliYWNrOjpTVEFSVCwgUGxheWJhY2s6OlNUT1AsIFBsYXliYWNrOjpQQVVTRSkKKyAqIEBwYXJhbSBwb3NpdGlvbiBQb3NpdGlvbiBpbiB0aGUgZmlsZSAoaW4gbWlsbGlzZWNvbmRzKSB3aGVyZSB0aGUgc3RhcnQgb2NjdXJzLgorICogICAgIE9ubHkgdmFsaWQgdG9nZXRoZXIgd2l0aCBQbGF5YmFjazo6U1RBUlQuCisgKiBAcmV0dXJuIHN0YXR1c190CisgKiAgICAgUmV0dXJucyBEUk1fTk9fRVJST1IgZm9yIHN1Y2Nlc3MsIERSTV9FUlJPUl9VTktOT1dOIGZvciBmYWlsdXJlCisgKi8KKyNpZmRlZiBVU0VfNjRCSVRfRFJNX0FQSQorc3RhdHVzX3Qgb25TZXRQbGF5YmFja1N0YXR1cyhpbnQgdW5pcXVlSWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgIERlY3J5cHRIYW5kbGUqIGRlY3J5cHRIYW5kbGUsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGludCBwbGF5YmFja1N0YXR1cywKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaW50NjRfdCBwb3NpdGlvbik7CisjZWxzZQorc3RhdHVzX3Qgb25TZXRQbGF5YmFja1N0YXR1cyhpbnQgdW5pcXVlSWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgIERlY3J5cHRIYW5kbGUqIGRlY3J5cHRIYW5kbGUsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGludCBwbGF5YmFja1N0YXR1cywKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaW50IHBvc2l0aW9uKTsKKyNlbmRpZgorCisvKioKKyAqICBWYWxpZGF0ZXMgd2hldGhlciBhbiBhY3Rpb24gb24gdGhlIERSTSBjb250ZW50IGlzIGFsbG93Z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0ZWQKKyAqIGZvciBldmVyeSBjb252ZXJzaW9uLgorICovCitjbGFzcyBDb252ZXJ0U2Vzc2lvbiB7CisgICAgcHVibGljIDoKKyAgICAgICAgaW50IHVuaXF1ZUlkOworICAgICAgICBGd2RMb2NrQ29udl9PdXRwdXRfdCBvdXRwdXQ7CisKKyAgICAgICAgQ29udmVydFNlc3Npb24oKSB7CisgICAgICAgICAgICB1bmlxdWVJZCA9IDA7CisgICAgICAgICAgICBtZW1zZXQoJm91dHB1dCwgMCwgc2l6ZW9mKEZ3ZExvY2tDb252X091dHB1dF90KSk7CisgICAgICAgIH0KKworICAgICAgICB2aXJ0dWFsIH5Db252ZXJ0U2Vzc2lvbigpIHt9Cit9OworCisvKioKKyAqIFNlc3Npb24gQ2xhc3MgZm9yIEZvcndhcmQgTG9jayBkZWNvZGVyLiBBbiBvYmplY3Qgb2YgdGhpcyBjbGFzcyBpcyBjcmVhdGVkCisgKiBmb3IgZXZlcnkgZGVjb2Rpbmcgc2Vzc2lvbi4KKyAqLworY2xhc3MgRGVjb2RlU2Vzc2lvbiB7CisgICAgcHVibGljIDoKKyAgICAgICAgaW50IGZpbGVEZXNjOworICAgICAgICBvZmZfdCBvZmZzZXQ7CisKKyAgICAgICAgRGVjb2RlU2Vzc2lvbigpIHsKKyAgICAgICAgICAgIGZpbGVEZXNjID0gLTE7CisgICAgICAgICAgICBvZmZzZXQgPSAwOworICAgICAgICB9CisKKyAgICAgICAgRGVjb2RlU2Vzc2lvbihpbnQgZmQpIHsKKyAgICAgICAgICAgIGZpbGVEZXNjID0gZmQ7CisgICAgICAgICAgICBvZmZzZXQgPSAwOworICAgICAgICB9CisKKyAgICAgICAgdmlydHVhbCB+RGVjb2RlU2Vzc2lvbigpIHt9Cit9OworCisvKioKKyAqIFNlc3Npb24gTWFwIFRhYmxlcyBmb3IgQ29udmVyc2lvbiBhbmQgRGVjb2Rpbmcgb2YgZm9yd2FyZCBsb2NrIGZpbGVzLgorICovCitTZXNzaW9uTWFwP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GlvbiIpOworCisgICAgY29udmVydFNlc3Npb25NYXAuZGVzdHJveU1hcCgpOworICAgIGRlY29kZVNlc3Npb25NYXAuZGVzdHJveU1hcCgpOworfQorCitpbnQgRndkTG9ja0VuZ2luZTo6Z2V0Q29udmVydGVkU3RhdHVzKEZ3ZExvY2tDb252X1N0YXR1c190IHN0YXR1cykgeworICAgIGludCByZXRTdGF0dXMgPSBEcm1Db252ZXJ0ZWRTdGF0dXM6OlNUQVRVU19FUlJPUjsKKworICAgIHN3aXRjaChzdGF0dXMpIHsKKyAgICAgICAgY2FzZSBGd2RMb2NrQ29udl9TdGF0dXNfT0s6CisgICAgICAgICAgICByZXRTdGF0dXMgPSBEcm1Db252ZXJ0ZWRTdGF0dXM6OlNUQVRVU19PSzsKKyAgICAgICAgICAgIGJyZWFrOworICAgICAgICBjYXNlIEZ3ZExvY2tDb252X1N0YXR1c19TeW50YXhFcnJvcjoKKyAgICAgICAgY2FzZSBGd2RMb2NrQ29udl9TdGF0dXNfSW52YWxpZEFyZ3VtZW50OgorICAgICAgICBjYXNlIEZ3ZExvY2tDb252X1N0YXR1c19VbnN1cHBvcnRlZEZpbGVGb3JtYXQ6CisgICAgICAgIGNhc2UgRndkTG9ja0NvbnZfU3RhdHVzX1Vuc3VwcG9ydGVkQ29udGVudFRyYW5zZmVyRW5jb2Rpbmc6CisgICAgICAgICAgICBMT0dEKCJGd2RMb2NrRW5naW5lIGdldENvbnZlcnRlZFN0YXR1czogZmlsZSBjb252ZXJzaW9uIEVycm9yICVkLiAiIFwKKyAgICAgICAgICAgICAgICAgICJSZXR1cm5pbmcgU1RBVFVTX0lOUFVUREFUQV9FUlJPUiIsIHN0YXR1cyk7CisgICAgICAgICAgICByZXRTdGF0dXMgPSBEcm1Db252ZXJ0ZWRTdGF0dXM6OlNUQVRVU19JTlBVVERBVEFfRVJST1I7CisgICAgICAgICAgICBicmVhazsKKyAgICAgICAgZGVmYXVsdDoKKyAgICAgICAgICAgIExPR0QoIkZ3ZExvY2tFbmdpbmUgZ2V0Q29udmVydGVkU3RhdHVzOiBmaWxlIGNvbnZlcnNpb24gRXJyb3IgJWQuICIgXAorICAgICAgICAgICAgICAgICAgIlJldHVybmluZyBTVEFUVVNfRVJST1IiLCBzdGF0dXMpOworICAgICAgICAgICAgcmV0U3RhdHVzID0gRHJtQ29udmVydGVkU3RhdHVzOjpTVEFUVVNfRVJST1I7CisgICAgICAgICAgICBicmVhazsKKyAgICB9CisKKyAgICByZXR1cm4gcmV0U3RhdHVzOworfQorCitEcm1Db25zdHJhaW50cyogRndkTG9ja0VuZ2luZTo6b25HZXRDb25zdHJhaW50cyhpbnQgdW5pcXVlSWQsIGNvbnN0IFN0cmluZzgqIHBhdGgsIGludCBhY3Rpb24pIHsKKyAgICBEcm1Db25zdHJhaW50cyogZHJtQ29uc3RyYWludHMgPSBOVUxMOworCisgICAgTE9HRCgiRndkTG9ja0VuZ2luZTo6b25HZXRDb25zdHJhaW50cyIpOworCisgICAgaWYgKE5VTEwgIT0gcGF0aCAmJgorICAgICAgICAoUmlnaHRzU3RhdHVzOjpSSUdIVFNfVkFMSUQgPT0gb25DaGVja1JpZ2h0c1N0YXR1cyh1bmlxdWVJZCwgKnBhdGgsIGFjdGlvbikpKSB7CisgICAgICAgIC8vIFJldHVybiB0aGUgZW1wdHkgY29uc3RyYWludHMgdG8gc2hvdyBubyBlcnJvciBjb25kaXRpb24uCisgICAgICAgIGRybUNvbnN0cmFpbnRzID0gbmV3IERybUNvbnN0cmFpbnRzKCk7CisgICAgfQorCisgICAgcmV0dXJuIGRybUNvbnN0cmFpbnRzOworfQorCitEcm1NZXRhZGF0YSogRndkTG9ja0VuZ2luZTo6b25HZXRNZXRhZGF0YShpbnQgdW5pcXVlSWQsIGNvbnN0IFN0cmluZzgqIHBhdGgpIHsKKyAgICBEcm1NZXRhZGF0YSogZHJtTWV0YWRhdGEgPSBOVUxMOworCisgICAgTE9HRCgiRndkTG9ja0VuZ2luZTo6b25HZXRNZXRhZGF0YSIp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ORToKKyAgICAgICAgICAgIGNhc2UgQWN0aW9uOjpPVVRQVVQ6CisgICAgICAgICAgICBjYXNlIEFjdGlvbjo6UFJFVklFVzoKKyAgICAgICAgICAgIGNhc2UgQWN0aW9uOjpFWEVDVVRFOgorICAgICAgICAgICAgY2FzZSBBY3Rpb246OkRJU1BMQVk6CisgICAgICAgICAgICAgICAgcmVzdWx0ID0gUmlnaHRzU3RhdHVzOjpSSUdIVFNfVkFMSUQ7CisgICAgICAgICAgICAgICAgYnJlYWs7CisKKyAgICAgICAgICAgIGNhc2UgQWN0aW9uOjpUUkFOU0ZFUjoKKyAgICAgICAgICAgIGRlZmF1bHQ6CisgICAgICAgICAgICAgICAgcmVzdWx0ID0gUmlnaHRzU3RhdHVzOjpSSUdIVFNfSU5WQUxJRDsKKyAgICAgICAgICAgICAgICBicmVhazsKKyAgICAgICAgfQorICAgIH0KKworICAgIHJldHVybiByZXN1bHQ7Cit9CisKK3N0YXR1c190IEZ3ZExvY2tFbmdpbmU6Om9uQ29uc3VtZVJpZ2h0cyhpbnQgdW5pcXVlSWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgRGVjcnlwdEhhbmRsZSogZGVjcnlwdEhhbmRsZSwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpbnQgYWN0aW9uLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJvb2wgcmVzZXJ2ZSkgeworICAgIC8vIE5vIHJpZ2h0cyBjb25zdW1wdGlvbgorICAgIExPR0QoIkZ3ZExvY2tFbmdpbmU6Om9uQ29uc3VtZVJpZ2h0cyIpOworICAgIHJldHVybiBEUk1fTk9fRVJST1I7Cit9CisKK2Jvb2wgRndkTG9ja0VuZ2luZTo6b25WYWxpZGF0ZUFjdGlvbihpbnQgdW5pcXVlSWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc3QgU3RyaW5nOCYgcGF0aCwKKyA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252ZXJ0TWltZVR5cGUoY29udGVudFR5cGUpOworICAgICAgICB9CisKKyAgICAgICAgRndkTG9ja0ZpbGVfY2xvc2UoZmlsZURlc2MpOworICAgIH0KKworICAgIHJldHVybiBtaW1lU3RyaW5nOworfQorCitpbnQgRndkTG9ja0VuZ2luZTo6b25HZXREcm1PYmplY3RUeXBlKGludCB1bmlxdWVJZCwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc3QgU3RyaW5nOCYgcGF0aCwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc3QgU3RyaW5nOCYgbWltZVR5cGUpIHsKKyAgICBTdHJpbmc4IG1pbWVTdHIgPSBTdHJpbmc4KG1pbWVUeXBlKTsKKworICAgIExPR0QoIkZ3ZExvY2tFbmdpbmU6Om9uR2V0RHJtT2JqZWN0VHlwZSIpOworCisgICAgbWltZVN0ci50b0xvd2VyKCk7CisKKyAgICAvKiBDaGVja3Mgd2hldGhlcgorICAgICogMS4gcGF0aCBhbmQgbWltZSB0eXBlIGJvdGggYXJlIG5vdCBlbXB0eSBzdHJpbmdzIChtZWFuaW5nIHVuYXZhaWxhYmxlKSBlbHNlIGNvbnRlbnQgaXMgdW5rbm93bgorICAgICogMi4gaWYgb25lIG9mIHRoZW0gaXMgZW1wdHkgc3RyaW5nIGFuZCBpZiBvdGhlciBpcyBrbm93biB0aGVuIGl0cyBhIERSTSBDb250ZW50IE9iamVjdC4KKyAgICAqIDMuIGlmIGJvdGggb2YgdGhlbSBhcmUgYXZhaWxhYmxlLCB0aGVuIGJvdGggbWF5IGJlIG9mIGtub3duIHR5cGUKKyAgICAqICAgIChyZWdhcmRsZXNzIG9mIHRoZSByZWxhdGlvbiBiZXR3ZWVuIHRoZW0gdG8gbWFrZSBpdCBjb21wYXRpYmxlIHdpdGggb3RoZXIgRFJNIEVuZ2luZXMpCisgICAgKi8KKyAgICBpZiAoKCgwID09IHBhdGgubGVuZ3RoKCkpIHx8IG9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0aW9uKSB7CisjZWxzZQorc3RhdHVzX3QgRndkTG9ja0VuZ2luZTo6b25TZXRQbGF5YmFja1N0YXR1cyhpbnQgdW5pcXVlSWQsIERlY3J5cHRIYW5kbGUqIGRlY3J5cHRIYW5kbGUsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGludCBwbGF5YmFja1N0YXR1cywgaW50IHBvc2l0aW9uKSB7CisjZW5kaWYKKyAgICAvLyBOb3QgdXNlZAorICAgIExPR0QoIkZ3ZExvY2tFbmdpbmU6Om9uU2V0UGxheWJhY2tTdGF0dXMiKTsKKyAgICByZXR1cm4gRFJNX05PX0VSUk9SOworfQorCitzdGF0dXNfdCBGd2RMb2NrRW5naW5lOjpvbk9wZW5Db252ZXJ0U2Vzc2lvbihpbnQgdW5pcXVlSWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGludCBjb252ZXJ0SWQpIHsKKyAgICBzdGF0dXNfdCByZXN1bHQgPSBEUk1fRVJST1JfVU5LTk9XTjsKKyAgICBMT0dEKCJGd2RMb2NrRW5naW5lOjpvbk9wZW5Db252ZXJ0U2Vzc2lvbiIpOworICAgIGlmICghY29udmVydFNlc3Npb25NYXAuaXNDcmVhdGVkKGNvbnZlcnRJZCkpIHsKKyAgICAgICAgQ29udmVydFNlc3Npb24gKm5ld1Nlc3Npb24gPSBuZXcgQ29udmVydFNlc3Npb24oKTsKKyAgICAgICAgaWYgKEZ3ZExvY2tDb252X1N0YXR1c19PSyA9PQorICAgICAgICAgICAgRndkTG9ja0NvbnZfT3BlblNlc3Npb24oJihuZXdTZXNzaW9uLT51bmlxdWVJZCksICYobmV3U2Vzc2lvbi0+b3V0cHV0KSkpIHsKKyAgICAgICAgICAgIGNvbnZlcnRTZXNzaW9uTWFwLmFkZFZhbHVlKGNvbnZlcnRJZCwgbmV3U2Vzc2lvbik7CisgICAgICAgICAgICByZXN1bHQgPSBEUk1fTk9fRVJST1I7CisgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICBMT0dEKCJGd2RMb2NrRW5naW5lOjpvbk9wZW5Db252ZXJ0U2Vzc2lvbiAtLSBGd2RMb2NrQ29udl9PcGVuU2Vzc2lvbiBmYWlsZWQuIik7CisgICAgICAgICAgICBkZWxldGUgbmV3U2Vzc2lvbjsKKyAgICAgICAgfQorICAgIH0KKyAgICByZXR1cm4gcmVzdWx0OworfQorCitEcm1Db252ZXJ0ZWRTdGF0dXMqIEZ3ZExvY2tFbmdpbmU6Om9uQ29udmVydERhdGEoaW50IHVuaXF1ZUlkLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGludCBjb252ZXJ0SWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc3QgRHJtQnVmZmVyKiBpbnB1dERhdGEpIHsKKyAgICBGd2RMb2NrQ29udl9TdGF0dXNfdCByZXRTdGF0dXMgPSBGd2RMb2NrQ29udl9TdGF0dXNfSW52YWxpZEFyZ3VtZW50OworICAgIERybUJ1ZmZlciAqY29udlJlc3VsdCA9IG5ldyBEcm1CdWZmZXIoTlVMTCwgMCk7CisgICAgaW50IG9mZnNldCA9IC0xOworCisgICAgaWYgKE5VTEwgIT0gaW5wdXREYXRhICYmIGNvbnZlcnRTZXNzaW9uTWFwLmlzQ3JlYXRlZChjb252ZXJ0SWQpKSB7CisgICAgICAgIENvbnZlcnRTZXNzaW9uICpjb252U2Vzc2lvbiA9IGNvbnZlcnRTZXNzaW9uTWFwLmdldFZhbHVlKGNvbnZlcnRJZCk7CisKKyAgICAgICAgaWYgKE5VTEwgIT0gY29udlNlc3Npb24pIHsKKyAgICAgICAgICAgIHJldFN0YXR1cyA9IEZ3ZExvY2tDb252X0NvbnZlcnREYXRhKGNvbnZTZXNzaW9uLT51bmlxdWVJZCwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlucHV0RGF0YS0+ZGF0YSwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlucHV0RGF0YS0+bGVuZ3RoLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgJihjb252U2Vzc2lvbi0+b3V0cHV0KSk7CisKKyAgICAgICAgICAgIGlmIChGd2RMb2NrQ29udl9TdGF0dXNfT0sgPT0gcmV0U3RhdHVzKSB7CisgICAgICAgICAgICAgICAgLy8gcmV0dXJuIGJ5dGVzIGZyb20gY29udmVyc2lvbiBpZiBhdmFpbGFibGUKKyAgICAgICAgICAgICAgICBpZiAoY29udlNlc3Npb24tPm91dHB1dC5mcm9tQ29udmVydERhdGEubnVtQnl0ZXMgPiAwKSB7CisgICAgICAgICAgICAgICAgICAgIGNvbnZSZXN1bHQtPmRhdGEgPSBuZXcgY2hhcltjb252U2Vzc2lvbi0+b3V0cHV0LmZyb21Db252ZXJ0RGF0YS5udW1CeXRlc107CisKKyAgICAgICAgICAgICAgICAgICAgaWYgKE5VTEwgIT0gY29udlJlc3VsdC0+ZGF0YSkgeworICAgICAgICAgICAgICAgICAgICAgICAgY29udlJlc3VsdC0+bGVuZ3RoID0gY29udlNlc3Npb24tPm91dHB1dC5mcm9tQ29udmVydERhdGEubnVtQnl0ZXM7CisgICAgICAgICAgICAgICAgICAgICAgICBtZW1jcHkoY29udlJlc3VsdC0+ZGF0YSwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAoY2hhciAqKWNvbnZTZXNzaW9uLT5vdXRwdXQuZnJvbUNvbnZlcnREYXRhLnBCdWZmZXIsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29udlJlc3VsdC0+bGVuZ3RoKTsKKyAgICAgICAgICAgICAgICAgICAgfQorICAgICAgICAgICAgICAgIH0KKyAgICAgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICAgICAgb2Zmc2V0ID0gY29udlNlc3Npb24tPm91dHB1dC5mcm9tQ29udmVydERhdGEuZXJyb3JQb3M7CisgICAgICAgICAgICB9CisgICAgICAgIH0KKyAgICB9CisgICAgcmV0dXJuIG5ldyBEcm1Db252ZXJ0ZWRTdGF0dXMoZ2V0Q29udmVydGVkU3RhdHVzKHJldFN0YXR1cyksIGNvbnZSZXN1bHQsIG9mZnNldCk7Cit9CisKK0RybUNvbnZlcnRlZFN0YXR1cyogRndkTG9ja0VuZ2luZTo6b25DbG9zZUNvbnZlcnRTZXNzaW9uKGludCB1bmlxdWVJZCwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGludCBjb252ZXJ0SWQpIHsKKyAgICBGd2RMb2NrQ29udl9TdGF0dXNfdCByZXRTdGF0dXMgPSBGd2RMb2NrQ29udl9TdGF0dXNfSW52YWxpZEFyZ3VtZW50OworICAgIERybUJ1ZmZlciAqY29udlJlc3VsdCA9IG5ldyBEcm1CdWZmZXIoTlVMTCwgMCk7CisgICAgaW50IG9mZnNldCA9IC0xOworCisgICAgTE9HRCgiRndkTG9ja0VuZ2luZTo6b25DbG9zZUNvbnZlcnRTZXNzaW9uIik7CisKKyAgICBpZiAoY29udmVydFNlc3Npb25NYXAuaXNDcmVhdGVkKGNvbnZlcnRJZCkpIHsKKyAgICAgICAgQ29udmVydFNlc3Npb24gKmNvbnZTZXNzaW9uID0gY29udmVydFNlc3Npb25NYXAuZ2V0VmFsdWUoY29udmVydElkKTsKKworICAgICAgICBpZiAoTlVMTCAhPSBjb252U2Vzc2lvbikgeworICAgICAgICAgICAgcmV0U3RhdHVzID0gRndkTG9ja0NvbnZfQ2xvc2VTZXNzaW9uKGNvbnZTZXNzaW9uLT51bmlxdWVJZCwgJihjb252U2Vzc2lvbi0+b3V0cHV0KSk7CisKKyAgICAgICAgICAgIGlmIChGd2RMb2NrQ29udl9TdGF0dXNfT0sgPT0gcmV0U3RhdHVzKSB7CisgICAgICAgICAgICAgICAgb2Zmc2V0ID0gY29udlNlc3Npb24tPm91dHB1dC5mcm9tQ2xvc2VTZXNzaW9uLmZpbGVPZmZzZXQ7CisgICAgICAgICAgICAgICAgY29udlJlc3VsdC0+ZGF0YSA9IG5ldyBjaGFyW0ZXRF9MT0NLX1NJR05BVFVSRVNfU0laRV07CisKKyAgICAgICAgICAgICAgICBpZiAoTlVMTCAhPSBjb252UmVzdWx0LT5kYXRhKSB7CisgICAgICAgICAgICAgICAgICAgICAgY29udlJlc3VsdC0+bGVuZ3RoID0gRldEX0xPQ0tfU0lHTkFUVVJFU19TSVpFOworICAgICAgICAgICAgICAgICAgICAgIG1lbWNweShjb252UmVzdWx0LT5kYXRhLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAoY2hhciAqKWNvbnZTZXNzaW9uLT5vdXRwdXQuZnJvbUNsb3NlU2Vzc2lvbi5zaWduYXR1cmVzLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb252UmVzdWx0LT5sZW5ndGgpOworICAgICAgICAgICAgICAgIH0KKyAgICAgICAgICAgIH0KKyAgICAgICAgfQorICAgICAgICBjb252ZXJ0U2Vzc2lvbk1hcC5yZW1vdmVWYWx1ZShjb252ZXJ0SWQpOworICAgIH0KKyAgICByZXR1cm4gbmV3IERybUNvbnZlcnRlZFN0YXR1cyhnZXRDb252ZXJ0ZWRTdGF0dXMocmV0U3RhdHVzKSwgY29udlJlc3VsdCwgb2Zmc2V0KTsKK30KKworI2lmZGVmIFVTRV82NEJJVF9EUk1fQVBJCitzdGF0dXNfdCBGd2RMb2NrRW5naW5lOjpvbk9wZW5EZWNyeXB0U2Vzc2lvbihpbnQgdW5pcXVlSWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBEZWNyeXB0SGFuZGxlKiBkZWNyeXB0SGFuZGxlLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaW50IGZkLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgb2ZmNjRfdCBvZmZzZXQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBvZmY2NF90IGxlbmd0aCkgeworI2Vsc2UKK3N0YXR1c190IEZ3ZExvY2tFbmdpbmU6Om9uT3BlbkRlY3J5cHRTZXNzaW9uKGludCB1bmlxdWVJZCwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIERlY3J5cHRIYW5kbGUqIGRlY3J5cHRIYW5kbGUsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpbnQgZmQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpbnQgb2Zmc2V0LAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaW50IGxlbmd0aCkgeworI2VuZGlmCisgICAgc3RhdHVzX3QgcmVzdWx0ID0gRFJNX0VSUk9SX0NBTk5PVF9IQU5ETEU7CisgICAgaW50IGZpbGVEZXNjID0gLTE7CisKKyAgICBMT0dEKCJGd2RMb2NrRW5naW5lOjpvbk9wZW5EZWNyeXB0U2Vzc2lvbiIpOworCisgICAgaWYgKCgtMSA8IGZkKSAmJgorICAgICAgICAoTlVMTCAhPSBkZWNyeXB0SGFuZGxlKSAmJgorICAgICAgICAoIWRlY29kZVNlc3Npb25NYXAuaXNDcmVhdGVkKGRlY3J5cHRIYW5kbGUtPmRlY3J5cHRJZCkpKSB7CisgICAgICAgIGZpbGVEZXNjID0gZHVwKGZkKTsKKyAgICB9IGVsc2UgeworICAgICAgICBMT0dEKCJGd2RMb2NrRW5naW5lOjpvbk9wZW5EZWNyeXB0U2Vzc2lvbiBwYXJhbWV0ZXIgZXJyb3IiKTsKKyAgICAgICAgcmV0dXJuIHJlc3VsdDsKKyAgICB9CisKKyAgICBpZiAoLTEgPCBmaWxlRGVzYyAmJgorICAgICAgICAtMSA8IDo6bHNlZWsoZmlsZURlc2MsIG9m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gZGVjcnlwdEhhbmRsZS0+ZGVjcnlwdEluZm8gPSBOVUxMOworICAgICAgICAgICAgcmVzdWx0ID0gRFJNX05PX0VSUk9SOworICAgICAgICB9IGVsc2UgeworICAgICAgICAgICAgTE9HRCgiRndkTG9ja0VuZ2luZTo6b25PcGVuRGVjcnlwdFNlc3Npb24gSW50ZWdyaXR5IENoZWNrIGZhaWxlZCBmb3IgdGhlIGZkIik7CisgICAgICAgICAgICBGd2RMb2NrRmlsZV9kZXRhY2goZmlsZURlc2MpOworICAgICAgICAgICAgOjpjbG9zZShmaWxlRGVzYyk7CisgICAgICAgICAgICBkZWxldGUgZGVjb2RlU2Vzc2lvbjsKKyAgICAgICAgfQorICAgIH0KKworICAgIExPR0QoIkZ3ZExvY2tFbmdpbmU6Om9uT3BlbkRlY3J5cHRTZXNzaW9uIEV4aXQuIHJlc3VsdCA9ICVkIiwgcmVzdWx0KTsKKworICAgIHJldHVybiByZXN1bHQ7Cit9CisKK3N0YXR1c190IEZ3ZExvY2tFbmdpbmU6Om9uT3BlbkRlY3J5cHRTZXNzaW9uKGludCB1bmlxdWVJZCwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIERlY3J5cHRIYW5kbGUqIGRlY3J5cHRIYW5kbGUsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb25zdCBjaGFyKiB1cmkpIHsKKyAgICBzdGF0dXNfdCByZXN1bHQgPSBEUk1fRVJST1JfQ0FOTk9UX0hBTkRMRTsKKyAgICBjb25zdCBjaGFyIGZpbGVUYWcgW10gPSAiZmlsZTovLyI7CisKKyAgICBpZiAoTlVMTCAhPSBkZWNyeXB0SGFuZGxlICYmIE5VTEwgIT0gdXJpICYmIHN0cmxlbih1cmkpID4gc2l6ZW9mKGZpbGVUYWcpKSB7CisgICAgICAgIFN0cmluZzggdXJpVGFnID0gU3RyaW5nOCh1cmkpOworICAgICAgICB1cmlUYWcudG9Mb3dlcigpOworCisgICAgICAgIGlmICgwID09IHN0cm5jbXAodXJpVGFnLnN0cmluZygpLCBmaWxlVGFnLCBzaXplb2YoZmlsZVRhZykgLSAxKSkgeworICAgICAgICAgICAgY29uc3QgY2hhciAqZmlsZVBhdGggPSBzdHJjaHIodXJpICsgc2l6ZW9mKGZpbGVUYWcpIC0gMSwgJy8nKTsKKyAgICAgICAgICAgIGlmIChOVUxMICE9IGZpbGVQYXRoICYmIG9uQ2FuSGFuZGxlKHVuaXF1ZUlkLCBTdHJpbmc4KGZpbGVQYXRoKSkpIHsKKyAgICAgICAgICAgICAgICBpbnQgZmQgPSBvcGVuKGZpbGVQYXRoLCBPX1JET05MWSk7CisKKyAgICAgICAgICAgICAgICBpZiAoLTEgPCBmZCkgeworICAgICAgICAgICAgICAgICAgICAvLyBvZmZzZXQgaXMgYWx3YXlzIDAgYW5kIGxlbmd0aCBpcyBub3QgdXNlZC4gc28gYW55IHBvc2l0aXZlIHNpemUuCisgICAgICAgICAgICAgICAgICAgIHJlc3VsdCA9IG9uT3BlbkRlY3J5cHRTZXNzaW9uKHVuaXF1ZUlkLCBkZWNyeXB0SGFuZGxlLCBmZCwgMCwgMSk7CisKKyAgICAgICAgICAgICAgICAgICAgLy8gZmQgaXMgZHVwbGljYXRlZCBhbHJlYWR5IGlmIHN1Y2Nlc3MuIGNsb3NpbmcgdGhlIGZpbGUKKyAgICAgICAgICAgICAgICAgICAgY2xvc2UoZmQpOworICAgICAgICAgICAgICAgIH0KKyAgICAgICAgICAgIH0KKyAgICAgICAgfQorICAgIH0KKworICAgIHJldHVybiByZXN1bHQ7Cit9CisKK3N0YXR1c190IEZ3ZExvY2tFbmdpbmU6Om9uQ2xvc2VEZWNyeXB0U2Vzc2lvbihpbnQgdW5pcXVlSWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgRGVjcnlwdEhhbmRsZSogZGVjcnlwdEhhbmRsZSkgeworICAgIHN0YXR1c190IHJlc3VsdCA9IERSTV9FUlJPUl9VTktOT1dOOworICAgIExPR0QoIkZ3ZExvY2tFbmdpbmU6Om9uQ2xvc2VEZWNyeXB0U2Vzc2lvbiIpOworCisgICAgaWYgKE5VTEwgIT0gZGVjcnlwdEhhbmRsZSAmJiBkZWNvZGVTZXNzaW9uTWFwLmlzQ3JlYXRlZChkZWNyeXB0SGFuZGxlLT5kZWNyeXB0SWQpKSB7CisgICAgICAgIERlY29kZVNlc3Npb24qIHNlc3Npb24gPSBkZWNvZGVTZXNzaW9uTWFwLmdldFZhbHVlKGRlY3J5cHRIYW5kbGUtPmRlY3J5cHRJZCk7CisgICAgICAgIGlmIChOVUxMICE9IHNlc3Npb24gJiYgc2Vzc2lvbi0+ZmlsZURlc2MgPiAtMSkgeworICAgICAgICAgICAgRndkTG9ja0ZpbGVfZGV0YWNoKHNlc3Npb24tPmZpbGVEZXNjKTsKKyAgICAgICAgICAgIDo6Y2xvc2Uoc2Vzc2lvbi0+ZmlsZURlc2MpOworICAgICAgICAgICAgZGVjb2RlU2Vzc2lvbk1hcC5yZW1vdmVWYWx1ZShkZWNyeXB0SGFuZGxlLT5kZWNyeXB0SWQpOworICAgICAgICAgICAgcmVzdWx0ID0gRFJNX05PX0VSUk9SOworICAgICAgICB9CisgICAgfQorCisgICAgTE9HRCgiRndkTG9ja0VuZ2luZTo6b25DbG9zZURlY3J5cHRTZXNzaW9uIEV4aXQiKTsKKyAgICByZXR1cm4gcmVzdWx0OworfQorCitzdGF0dXNfdCBGd2RMb2NrRW5naW5lOjpvbkluaXRpYWxpemVEZWNyeXB0VW5pdChpbnQgdW5pcXVlSWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBEZWNyeXB0SGFuZGxlKiBkZWNyeXB0SGFuZGxlLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaW50IGRlY3J5cHRVbml0SWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb25zdCBEcm1CdWZmZXIqIGhlYWRlckluZm8pIHsKKyAgICBMT0dEKCJGd2RMb2NrRW5naW5lOjpvbkluaXRpYWxpemVEZWNyeXB0VW5pdCIpOworICAgIHJldHVybiBEUk1fRVJST1JfVU5LTk9XTjsKK30KKworc3RhdHVzX3QgRndkTG9ja0VuZ2luZTo6b25EZWNyeXB0KGludCB1bmlxdWVJZCwgRGVjcnlwdEhhbmRsZSogZGVjcnlwdEhhbmRsZSwgaW50IGRlY3J5cHRVbml0SWQsCisgICAgICAgICAgICBjb25zdCBEcm1CdWZmZXIqIGVuY0J1ZmZlciwgRHJtQnVmZmVyKiogZGVjQnVmZmVyLCBEcm1CdWZmZXIqIElWKSB7CisgICAgTE9HRCgiRndkTG9ja0VuZ2luZTo6b25EZWNyeXB0Iik7CisgICAgcmV0dXJuIERSTV9FUlJPUl9VTktOT1dOOworfQorCitzdGF0dXNfdCBGd2RMb2NrRW5naW5lOjpvbkRlY3J5cHQoaW50IHVuaXF1ZUlkLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIERlY3J5cHRIYW5kbGUqIGRlY3J5cHRIYW5kbGUsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaW50IGRlY3J5cHRVbml0SWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc3QgRHJtQnVmZmVyKiBlbmNCdWZmZXIsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgRHJtQnVmZmVyKiogZGVjQnVmZmVyKSB7CisgICAgTE9HRCgiRndkTG9ja0VuZ2luZTo6b25EZWNyeXB0Iik7CisgICAgcmV0dXJuIERSTV9FUlJPUl9VTktOT1dOOworfQorCitzdGF0dXNfdCBGd2RMb2NrRW5naW5lOjpvbkZpbmFsaXplRGVjcnlwdFVuaXQoaW50IHVuaXF1ZUlkLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIERlY3J5cHRIYW5kbGUqIGRlY3J5cHRIYW5kbGUsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaW50IGRlY3J5cHRVbml0SWQpIHsKKyAgICBMT0dEKCJGd2RMb2NrRW5naW5lOjpvbkZpbmFsaXplRGVjcnlwdFVuaXQiKTsKKyAgICByZXR1cm4gRFJNX0VSUk9SX1VOS05PV047Cit9CisKK3NzaXplX3QgRndkTG9ja0VuZ2luZTo6b25SZWFkKGludCB1bmlxdWVJZCwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIERlY3J5cHRIYW5kbGUqIGRlY3J5cHRIYW5kbGUsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2b2lkKiBidWZmZXIsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpbnQgbnVtQnl0ZXMpIHsKKyAgICBzc2l6ZV90IHNpemUgPSAtMTsKKworICAgIGlmIChOVUxMICE9IGRlY3J5cHRIYW5kbGUgJiYKKyAgICAgICBkZWNvZGVTZXNzaW9uTWFwLmlzQ3JlYXRlZChkZWNyeXB0SGFuZGxlLT5kZWNyeXB0SWQpICYmCisgICAgICAgIE5VTEwgIT0gYnVmZmVyICYmCisgICAgICAgIG51bUJ5dGVzID4gLTEpIHsKKyAgICAgICAgRGVjb2RlU2Vzc2lvbiogc2Vzc2lvbiA9IGRlY29kZVNlc3Npb25NYXAuZ2V0VmFsdWUoZGVjcnlwdEhhbmRsZS0+ZGVjcnlwdElkKTsKKyAgICAgICAgaWYgKE5VTEwgIT0gc2Vzc2lvbiAmJiBzZXNzaW9uLT5maWxlRGVzYyA+IC0xKSB7CisgICAgICAgICAgICBzaXplID0gRndkTG9ja0ZpbGVfcmVhZChzZXNzaW9uLT5maWxlRGVzYywgYnVmZmVyLCBudW1CeXRlcyk7CisKKyAgICAgICAgICAgIGlmICgwID4gc2l6ZSkgeworICAgICAgICAgICAgICAgIHNlc3Npb24tPm9mZnNldCA9ICgob2ZmX3QpLTE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KKyAgICByZXR1cm4gb2ZmdmFsOworfQorCisjaWZkZWYgVVNFXzY0QklUX0RSTV9BUEkKK3NzaXplX3QgRndkTG9ja0VuZ2luZTo6b25QcmVhZChpbnQgdW5pcXVlSWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgRGVjcnlwdEhhbmRsZSogZGVjcnlwdEhhbmRsZSwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2b2lkKiBidWZmZXIsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc3NpemVfdCBudW1CeXRlcywKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBvZmY2NF90IG9mZnNldCkgeworI2Vsc2UKK3NzaXplX3QgRndkTG9ja0VuZ2luZTo6b25QcmVhZChpbnQgdW5pcXVlSWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgRGVjcnlwdEhhbmRsZSogZGVjcnlwdEhhbmRsZSwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB2b2lkKiBidWZmZXIsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc3NpemVfdCBudW1CeXRlcywKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBvZmZfdCBvZmZzZXQpIHsKKyNlbmRpZgorICAgIHNzaXplX3QgYnl0ZXNSZWFkID0gLTE7CisKKyAgICBEZWNvZGVTZXNzaW9uKiBkZWNvZGVyU2Vzc2lvbiA9IE5VTEw7CisKKyAgICBpZiAoKE5VTEwgIT0gZGVjcnlwdEhhbmRsZSkgJiYKKyAgICAgICAgKE5VTEwgIT0gKGRlY29kZXJTZXNzaW9uID0gZGVjb2RlU2Vzc2lvbk1hcC5nZXRWYWx1ZShkZWNyeXB0SGFuZGxlLT5kZWNyeXB0SWQpKSkgJiYKKyAgICAgICAgKE5VTEwgIT0gYnVmZmVyKSAmJgorICAgICAgICAobnVtQnl0ZXMgPiAtMSkgJiYKKyAgICAgICAgKG9mZnNldCA+IC0xKSkgeworICAgICAg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gJy8nICYmIGkgPiAwKSB7CisgICAgICAgICAgICAgICAgcGFydGlhbFBhdGhbaV0gPSAnXDAnOworICAgICAgICAgICAgICAgIGlmIChta2RpcihwYXJ0aWFsUGF0aCwgbW9kZSkgIT0gMCAmJiBlcnJubyAhPSBFRVhJU1QpIHsKKyAgICAgICAgICAgICAgICAgICAgcmVzdWx0ID0gRkFMU0U7CisgICAgICAgICAgICAgICAgICAgIGJyZWFrOworICAgICAgICAgICAgICAgIH0KKyAgICAgICAgICAgIH0KKyAgICAgICAgICAgIHBhcnRpYWxQYXRoW2ldID0gcGF0aFtpXTsKKyAgICAgICAgfQorICAgICAgICBmcmVlKHBhcnRpYWxQYXRoKTsKKyAgICB9CisgICAgcmV0dXJuIHJlc3VsdDsKK30KKworLyoqCisgKiBJbml0aWFsaXplcyB0aGUgcm91bmQga2V5cyB1c2VkIGZvciBlbmNyeXB0aW9uIGFuZCBkZWNyeXB0aW9uIG9mIHNlc3Npb24ga2V5cy4gRmlyc3QgY3JlYXRlcyBhCisgKiBkZXZpY2UtdW5pcXVlIGtleS1lbmNyeXB0aW9uIGtleSBpZiBub25lIGV4aXN0cyB5ZXQuCisgKi8KK3N0YXRpYyB2b2lkIEZ3ZExvY2tHbHVlX0luaXRpYWxpemVSb3VuZEtleXMoKSB7CisgICAgdW5zaWduZWQgY2hhciBrZXlFbmNyeXB0aW9uS2V5W0tFWV9TSVpFXTsKKyAgICBpbnQgZmlsZURlc2MgPSBvcGVuKHN0cktleUZpbGVuYW1lLCBPX1JET05MWSk7CisgICAgaWYgKGZpbGVEZXNjID49IDApIHsKKyAgICAgICAgaWYgKHJlYWQoZmlsZURlc2MsIGtleUVuY3J5cHRpb25LZXksIEtFWV9TSVpFKSA9PSBLRVlfU0laRSkgeworICAgICAgICAgICAgaXNJbml0aWFsaXplZCA9IFRSVUU7CisgICAgICAgIH0KKyAgICAgICAgKHZvaWQpY2xvc2UoZmlsZURlc2MpOworICAgIH0gZWxzZSBpZiAoZXJybm8gPT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xlbmd0aCwgJmVuY3J5cHRpb25Sb3VuZEtleXMsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgaW5pdFZlY3RvciwgQUVTX0VOQ1JZUFQpOworICAgICAgICAgICAgcmVzdWx0ID0gVFJVRTsKKyAgICAgICAgfQorICAgIH0KKyAgICByZXR1cm4gcmVzdWx0OworfQorCitpbnQgRndkTG9ja0dsdWVfRGVjcnlwdEtleShjb25zdCB2b2lkICpwRW5jcnlwdGVkS2V5LAorICAgICAgICAgICAgICAgICAgICAgICAgICAgc2l6ZV90IGVuY3J5cHRlZEtleUxlbmd0aCwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgIHZvaWQgKnBEZWNyeXB0ZWRLZXksCisgICAgICAgICAgICAgICAgICAgICAgICAgICBzaXplX3QgZGVjcnlwdGVkS2V5TGVuZ3RoKSB7CisgICAgaW50IHJlc3VsdCA9IEZBTFNFOworICAgIGFzc2VydChlbmNyeXB0ZWRLZXlMZW5ndGggPT0gRndkTG9ja0dsdWVfR2V0RW5jcnlwdGVkS2V5TGVuZ3RoKGRlY3J5cHRlZEtleUxlbmd0aCkpOworICAgIGlmIChGd2RMb2NrR2x1ZV9Jbml0aWFsaXplS2V5RW5jcnlwdGlvbigpKSB7CisgICAgICAgIHNpemVfdCBkYXRhTGVuZ3RoID0gZW5jcnlwdGVkS2V5TGVuZ3RoIC0gQUVTX0JMT0NLX1NJWkU7CisgICAgICAgIHVuc2lnbmVkIGNoYXIgKnBEYXRhID0gbWFsbG9jKGRhdGFMZW5ndGgpOworICAgICAgICBpZiAocERhdGEgIT0gTlVMTCkgeworICAgICAgICAgICAgdW5zaWduZWQgY2hhciBpbml0VmVjdG9yW0FFU19CTE9DS19TSVpFXTsKKyAgICAgICAgICAgIG1lbWNweShwRGF0YSwgcEVuY3J5cHRlZEtleSwgZGF0YUxlbmd0aCk7CisgICAgICAgICAgICBtZW1jcHkoaW5pdFZlY3RvciwgKGNvbnN0IHVuc2lnbmVkIGNoYXIgKilwRW5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gICAgICAgICAgICBBRVNfZW5jcnlwdChwRGF0YS0+dmFsdWUsIHBEYXRhLT5rZXksICZwRGF0YS0+c2Vzc2lvblJvdW5kS2V5cyk7CisgICAgICAgICAgICBpZiAoQUVTX3NldF9lbmNyeXB0X2tleShwRGF0YS0+a2V5LCBLRVlfU0laRV9JTl9CSVRTLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgJnBTZXNzaW9uLT5lbmNyeXB0aW9uUm91bmRLZXlzKSAhPSAwKSB7CisgICAgICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX1Byb2dyYW1FcnJvcjsKKyAgICAgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICAgICAgLy8gRW5jcnlwdCB0aGUgMTYtYnl0ZSB2YWx1ZSB7MSwgMCwgLi4uLCAwfSB0byBwcm9kdWNlIHRoZSBzaWduaW5nIGtleS4KKyAgICAgICAgICAgICAgICArK3BEYXRhLT52YWx1ZVswXTsKKyAgICAgICAgICAgICAgICBBRVNfZW5jcnlwdChwRGF0YS0+dmFsdWUsIHBEYXRhLT5rZXksICZwRGF0YS0+c2Vzc2lvblJvdW5kS2V5cyk7CisgICAgICAgICAgICAgICAgSE1BQ19DVFhfaW5pdCgmcFNlc3Npb24tPnNpZ25pbmdDb250ZXh0KTsKKyAgICAgICAgICAgICAgICBITUFDX0luaXRfZXgoJnBTZXNzaW9uLT5zaWduaW5nQ29udGV4dCwgcERhdGEtPmtleSwgS0VZX1NJWkUsIEVWUF9zaGExKCksIE5VTEwpOworICAgICAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19PSzsKKyAgICAgICAgICAgIH0KKyAgICAgICAgfQorICAgICAgICBtZW1zZXQocERhdGEsIDAsIHNpemVvZiBwRGF0YSk7IC8vIFplcm8gb3V0IGtleSBkYXRhLgorICAgICAgICBmcmVlKHBEYXRhKTsKKyAgICB9CisgICAgcmV0dXJuIHN0YXR1czsKK30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gKgorICogQHJldHVybiBBIHN0YXR1cyBjb2RlLgorICovCitzdGF0aWMgRndkTG9ja0NvbnZfU3RhdHVzX3QgRndkTG9ja0NvbnZfTWF0Y2hPcGVuRGVsaW1pdGVyKEZ3ZExvY2tDb252X1Nlc3Npb25fdCAqcFNlc3Npb24sCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGludCBjaCkgeworICAgIEZ3ZExvY2tDb252X1N0YXR1c190IHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19PSzsKKyAgICBzd2l0Y2ggKHBTZXNzaW9uLT5zY2FubmVyU3RhdGUpIHsKKyAgICBjYXNlIEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c0ZpcnN0RGFzaDoKKyAgICAgICAgaWYgKGNoID09ICctJykgeworICAgICAgICAgICAgcFNlc3Npb24tPnNjYW5uZXJTdGF0ZSA9IEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c1NlY29uZERhc2g7CisgICAgICAgIH0gZWxzZSBpZiAoY2ggPT0gJ1xyJykgeworICAgICAgICAgICAgcFNlc3Npb24tPnNjYW5uZXJTdGF0ZSA9IEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c0xGOworICAgICAgICB9IGVsc2UgeworICAgICAgICAgICAgcFNlc3Npb24tPnNjYW5uZXJTdGF0ZSA9IEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c0NSOworICAgICAgICB9CisgICAgICAgIGJyZWFrOworICAgIGNhc2UgRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzU2Vjb25kRGFzaDoKKyAgICAgICAgaWYgKGNoID09ICctJykgeworICAgICAgICAgICAgLy8gVGhlIGRlbGltaXRlciBzdGFydHMgd2l0aCAiXHJcbi0tIiAodGhlIG9wZW4gZGVsaW1pdGVyIG1heSBvbWl0IHRoZSBpbml0aWFsICJcclxuIikuCisgICAgICAgICAgICAvLyBUaGUgcmVzdCBpcyB0aGUgdXNlci1kZWZpbmVkIGJvdW5kYXJ5IHRoYXQgc2hvdWxkIGNvbWUgbmV4dC4KKyAgICAgICAgICAgIHBTZXNzaW9uLT5kZWxpbWl0ZXJbMF0gPSAnXHInOworICAgICAgICAgICAgcFNlc3Npb24tPmRlbGltaXRlclsxXSA9ICdcbic7CisgICAgICAgICAgICBwU2Vzc2lvbi0+ZGVsaW1pdGVyWzJdID0gJy0nOworICAgICAgICAgICAgcFNlc3Npb24tPmRlbGltaXRlclszXSA9ICctJzsKKyAgICAgICAgICAgIHBTZXNzaW9uLT5kZWxpbWl0ZXJMZW5ndGggPSA0OworICAgICAgICAgICAgcFNlc3Npb24tPnNjYW5uZXJTdGF0ZSA9IEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c0JvdW5kYXJ5OworICAgICAgICB9IGVsc2UgaWYgKGNoID09ICdccicpIHsKKyAgICAgICAgICAgIHBTZXNzaW9uLT5zY2FubmVyU3RhdGUgPSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNMRjsKKyAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgIHBTZXNzaW9uLT5zY2FubmVyU3RhdGUgPSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNDUjsKKyAgICAgICAgfQorICAgICAgICBicmVhazsKKyAgICBjYXNlIEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c0NSOgorICAgICAgICBpZiAoY2ggPT0gJ1xyJykgeworICAgICAgICAgICAgcFNlc3Npb24tPnNjYW5uZXJTdGF0ZSA9IEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c0xGOworICAgICAgICB9CisgICAgICAgIGJyZWFrOworICAgIGNhc2UgRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzTEY6CisgICAgICAgIGlmIChjaCA9PSAnXG4nKSB7CisgICAgICAgICAgIC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lclN0YXRlX1dhbnRzQ29udGVudFR5cGVTdGFydDsKKyAgICAgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX1N5bnRheEVycm9yOworICAgICAgICAgICAgfQorICAgICAgICB9IGVsc2UgaWYgKHN0cmNtcChwU2Vzc2lvbi0+bWltZUhlYWRlck5hbWUucHRyICsgc3RybGVuQ29udGVudCwgc3RyVHJhbnNmZXJFbmNvZGluZykgPT0gMCkgeworICAgICAgICAgICAgaWYgKHBTZXNzaW9uLT5jb250ZW50VHJhbnNmZXJFbmNvZGluZyA9PQorICAgICAgICAgICAgICAgICAgICBGd2RMb2NrQ29udl9Db250ZW50VHJhbnNmZXJFbmNvZGluZ19VbmRlZmluZWQpIHsKKyAgICAgICAgICAgICAgICBwU2Vzc2lvbi0+c2Nhbm5lclN0YXRlID0gRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzQ29udGVudFRyYW5zZmVyRW5jb2RpbmdTdGFydDsKKyAgICAgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX1N5bnRheEVycm9yOworICAgICAgICAgICAgfQorICAgICAgICB9IGVsc2UgeworICAgICAgICAgICAgcFNlc3Npb24tPnNjYW5uZXJTdGF0ZSA9IEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c0NSOworICAgICAgICB9CisgICAgfSBlbHNlIHsKKyAgICAgICAgcFNlc3Npb24tPnNjYW5uZXJTdGF0ZSA9IEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c0NSOworICAgIH0KKyAgICByZXR1cm4gc3RhdHVzOworfQorCisvKioKKyAqIEFwcGxpZXMgZGVmYXVsdHMgdG8gbWlzc2luZyBNSU1FIGhlYWRlciB2YWx1ZXMuCisgKgorICogQHBhcmFtW2luLG91dF0gcFNlc3Npb24gQSByZWZlcmVuY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IEEgc3RhdHVzIGNvZGUuCisgKi8KK3N0YXRpYyBGd2RMb2NrQ29udl9TdGF0dXNfdCBGd2RMb2NrQ29udl9NYXRjaE1pbWVIZWFkZXJzKEZ3ZExvY2tDb252X1Nlc3Npb25fdCAqcFNlc3Npb24sCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpbnQgY2gsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBGd2RMb2NrQ29udl9PdXRwdXRfdCAqcE91dHB1dCkgeworICAgIEZ3ZExvY2tDb252X1N0YXR1c190IHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19PSzsKKyAgICBzd2l0Y2ggKHBTZXNzaW9uLT5zY2FubmVyU3RhdGUpIHsKKyAgICBjYXNlIEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c01pbWVIZWFkZXJOYW1lU3RhcnQ6CisgICAgICAgIGlmIChGd2RMb2NrQ29udl9Jc01pbWVIZWFkZXJOYW1lQ2hhcihjaCkpIHsKKyAgICAgICAgICAgIHBTZXNzaW9uLT5taW1lSGVhZGVyTmFtZS5sZW5ndGggPSAwOworICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RyaW5nQXBwZW5kKCZwU2Vzc2lvbi0+bWltZUhlYWRlck5hbWUsIHRvbG93ZXIoY2gpKTsKKyAgICAgICAgICAgIGlmIChzdGF0dXMgPT0gRndkTG9ja0NvbnZfU3RhdHVzX09LKSB7CisgICAgICAgICAgICAgICAgcFNlc3Npb24tPnNjYW5uZXJTdGF0ZSA9IEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c01pbWVIZWFkZXJOYW1lOworICAgICAgICAgICAgfQorICAgICAgICB9IGVsc2UgaWYgKGNoID09ICdccicpIHsKKyAgICAgICAgICAgIHBTZXNzaW9uLT5zY2FubmVyU3RhdGUgPSBGd2RMb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IZWFkZXJOYW1lKHBTZXNzaW9uKTsKKyAgICAgICAgfSBlbHNlIGlmICghRndkTG9ja0NvbnZfSXNXaGl0ZXNwYWNlKGNoKSkgeworICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX1N5bnRheEVycm9yOworICAgICAgICB9CisgICAgICAgIGJyZWFrOworICAgIGNhc2UgRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzQ29udGVudFR5cGVTdGFydDoKKyAgICAgICAgaWYgKEZ3ZExvY2tDb252X0lzTWltZUhlYWRlclZhbHVlQ2hhcihjaCkpIHsKKyAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0cmluZ0FwcGVuZCgmcFNlc3Npb24tPmNvbnRlbnRUeXBlLCB0b2xvd2VyKGNoKSk7CisgICAgICAgICAgICBpZiAoc3RhdHVzID09IEZ3ZExvY2tDb252X1N0YXR1c19PSykgeworICAgICAgICAgICAgICAgIHBTZXNzaW9uLT5zY2FubmVyU3RhdGUgPSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNDb250ZW50VHlwZTsKKyAgICAgICAgICAgIH0KKyAgICAgICAgfSBlbHNlIGlmICghRndkTG9ja0NvbnZfSXNXaGl0ZXNwYWNlKGNoKSkgeworICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX1N5bnRheEVycm9yOworICAgICAgICB9CisgICAgICAgIGJyZWFrOworICAgIGNhc2UgRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzQ29udGVudFR5cGU6CisgICAgICAgIGlmIChGd2RMb2NrQ29udl9Jc01pbWVIZWFkZXJWYWx1ZUNoYXIoY2gpKSB7CisgICAgICAgICAgICBzdGF0dXMgPSBGd2RMb2NrQ29udl9TdHJpbmdBcHBlbmQoJnBTZXNzaW9uLT5jb250ZW50VHlwZSwgdG9sb3dlcihjaCkpOworICAgICAgICB9IGVsc2UgaWYgKGNoID09ICc7JykgeworICAgICAgICAgICAgcFNlc3Npb24tPnNjYW5uZXJTdGF0ZSA9IEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c0NSOworICAgICAgICB9IGVsc2UgaWYgKGNoID09ICdccicpIHsKKyAgICAgICAgICAgIHBTZXNzaW9uLT5zY2FubmVyU3RhdGUgPSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNMRjsKKyAgICAgICAgfSBlbHNlIGlmIChGd2RMb2NrQ29udl9Jc1doaXRlc3BhY2UoY2gpKSB7CisgICAgICAgICAgICBwU2Vzc2lvbi0+c2Nhbm5lclN0YXRlID0gRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzTWltZUhlYWRlclZhbHVlRW5kOworICAgICAgICB9IGVsc2UgeworICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX1N5bnRheEVycm9yOworICAgICAgICB9CisgICAgICAgIGJyZWFrOworICAgIGNhc2UgRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzQ29udGVudFRyYW5zZmVyRW5jb2RpbmdTdGFydDoKKyAgICAgICAgaWYgKGNoID09ICdiJyB8fCBjaCA9PSAnQicpIHsKKyAgICAgICAgICAgIHBTZXNzaW9uLT5zY2FubmVyU3RhdGUgPSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNfQV9PUl9JOworICAgICAgICB9IGVsc2UgaWYgKGNoID09ICc3JyB8fCBjaCA9PSAnOCcpIHsKKyAgICAgICAgICAgIHBTZXNzaW9uLT5zY2FubmVyU3RhdGUgPSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNfQjsKKyAgICAgICAgfSBlbHNlIGlmICghRndkTG9ja0NvbnZfSXNXaGl0ZXNwYWNlKGNoKSkgeworICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX1Vuc3VwcG9ydGVkQ29udGVudFRyYW5zZmVyRW5jb2Rpbmc7CisgICAgICAgIH0KKyAgICAgICAgYnJlYWs7CisgICAgY2FzZSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNfQV9PUl9JOgorICAgICAgICBpZiAoY2ggPT0gJ2knIHx8IGNoID09ICdJJykgeworICAgICAgICAgICAgcFNlc3Npb24tPnNjYW5uZXJTdGF0ZSA9IEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c19OOworICAgICAgICB9IGVsc2UgaWYgKGNoID09ICdhJyB8fCBjaCA9PSAnQScpIHsKKyAgICAgICAgICAgIHBTZXNzaW9uLT5zY2FubmVyU3RhdGUgPSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNfUzsKKyAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19VbnN1cHBvcnRlZENvbnRlbnRUcmFuc2ZlckVuY29kaW5nOworICAgICAgICB9CisgICAgICAgIGJyZWFrOworICAgIGNhc2UgRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzX046CisgICAgICAgIGlmIChjaCA9PSAnbicgfHwgY2ggPT0gJ04nKSB7CisgICAgICAgICAgICBwU2Vzc2lvbi0+c2Nhbm5lclN0YXRlID0gRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzX0E7CisgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICBzdGF0dXMgPSBGd2RMb2NrQ29udl9TdGF0dXNfVW5zdXBwb3J0ZWRDb250ZW50VHJhbnNmZXJFbmNvZGluZzsKKyAgICAgICAgfQorICAgICAgICBicmVhazsKKyAgICBjYXNlIEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c19BOgorICAgICAgICBpZiAoY2ggPT0gJ2EnIHx8IGNoID09ICdBJykgeworICAgICAgICAgICAgcFNlc3Npb24tPnNjYW5uZXJTdGF0ZSA9IEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c19SOworICAgICAgICB9IGVsc2UgeworICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX1Vuc3VwcG9ydGVkQ29udGVudFRyYW5zZmVyRW5jb2Rpbmc7CisgICAgICAgIH0KKyAgICAgICAgYnJlYWs7CisgICAgY2FzZSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNfUjoKKyAgICAgICAgaWYgKGNoID09ICdyJyB8fCBjaCA9PSAnUicpIHsKKyAgICAgICAgICAgIHBTZXNzaW9uLT5zY2FubmVyU3RhdGUgPSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNfWTsKKyAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19VbnN1cHBvcnRlZENvbnRlbnRUcmFuc2ZlckVuY29kaW5nOworICAgICAgICB9CisgICAgICAgIGJyZWFrOworICAgIGNhc2UgRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzX1k6CisgICAgICAgIGlmIChjaCA9PSAneScgfHwgY2ggPT0gJ1knKSB7CisgICAgICAgICAgICBwU2Vzc2lvbi0+Y29udGVudFRyYW5zZmVyRW5jb2RpbmcgPSBGd2RMb2NrQ29udl9Db250ZW50VHJhbnNmZXJFbmNvZGluZ19CaW5hcnk7CisgICAgICAgICAgICBwU2Vzc2lvbi0+c2Nhbm5lclN0YXRlID0gRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzQ29udGVudFRyYW5zZmVyRW5jb2RpbmdFbmQ7CisgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICBzdGF0dXMgPSBGd2RMb2NrQ29udl9TdGF0dXNfVW5zdXBwb3J0ZWRDb250ZW50VHJhbnNmZXJFbmNvZGluZzsKKyAgICAgICAgfQorICAgICAgICBicmVhazsKKyAgICBjYXNlIEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c19TOgorICAgICAgICBpZiAoY2ggPT0gJ3MnIHx8IGNoID09ICdTJykgeworICAgICAgICAgICAgcFNlc3Npb24tPnNjYW5uZXJTdGF0ZSA9IEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c19FOworICAgICAgICB9IGVsc2UgeworICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX1Vuc3VwcG9ydGVkQ29udGVudFRyYW5zZmVyRW5jb2Rpbmc7CisgICAgICAgIH0KKyAgICAgICAgYnJlYWs7CisgICAgY2FzZSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNfRToKKyAgICAgICAgaWYgKGNoID09ICdlJyB8fCBjaCA9PSAnRScpIHsKKyAgICAgICAgICAgIHBTZXNzaW9uLT5zY2FubmVyU3RhdGUgPSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNfNjsKKyAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19VbnN1cHBvcnRlZENvbnRlbnRUcmFuc2ZlckVuY29kaW5nOworICAgICAgICB9CisgICAgICAgIGJyZWFrOworICAgIGNhc2UgRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzXzY6CisgICAgICAgIGlmIChjaCA9PSAnNicpIHsKKyAgICAgICAgICAgIHBTZXNzaW9uLT5zY2FubmVyU3RhdGUgPSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNfNDsKKyAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19VbnN1cHBvcnRlZENvbnRlbnRUcmFuc2ZlckVuY29kaW5nOworICAgICAgICB9CisgICAgICAgIGJyZWFrOworICAgIGNhc2UgRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzXzQ6CisgICAgICAgIGlmI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WVIZWFkZXJOYW1lU3RhcnQ7CisgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICBzdGF0dXMgPSBGd2RMb2NrQ29udl9TdGF0dXNfU3ludGF4RXJyb3I7CisgICAgICAgIH0KKyAgICAgICAgYnJlYWs7CisgICAgY2FzZSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNNaW1lSGVhZGVyc0VuZDoKKyAgICAgICAgaWYgKGNoID09ICdcbicpIHsKKyAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X0FwcGx5RGVmYXVsdHMocFNlc3Npb24pOworICAgICAgICAgICAgaWYgKHN0YXR1cyA9PSBGd2RMb2NrQ29udl9TdGF0dXNfT0spIHsKKyAgICAgICAgICAgICAgICBzdGF0dXMgPSBGd2RMb2NrQ29udl9WZXJpZnlDb250ZW50VHlwZShwU2Vzc2lvbik7CisgICAgICAgICAgICB9CisgICAgICAgICAgICBpZiAoc3RhdHVzID09IEZ3ZExvY2tDb252X1N0YXR1c19PSykgeworICAgICAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1dyaXRlSGVhZGVyKHBTZXNzaW9uLCBwT3V0cHV0KTsKKyAgICAgICAgICAgIH0KKyAgICAgICAgICAgIGlmIChzdGF0dXMgPT0gRndkTG9ja0NvbnZfU3RhdHVzX09LKSB7CisgICAgICAgICAgICAgICAgaWYgKHBTZXNzaW9uLT5jb250ZW50VHJhbnNmZXJFbmNvZGluZyA9PQorICAgICAgICAgICAgICAgICAgICAgICAgRndkTG9ja0NvbnZfQ29udGVudFRyYW5zZmVyRW5jb2RpbmdfQmluYXJ5KSB7CisgICAgICAgICAgICAgICAgICAgIHBTZXNzaW9uLT5wYXJzZXJTdGF0ZSA9IEZ3ZExvY2tDb252X1BhcnNlclN0YXRlX1dhbnRzQmluYXJ5RW5jb2RlZERhdGE7CisgICAgICAgICAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgICAgICAgICAgcFNlc3Npb24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mVyU3RhdGVfV2FudHNGaXJzdERhc2g6CisgICAgICAgIGlmIChjaCA9PSAnLScpIHsKKyAgICAgICAgICAgIHBTZXNzaW9uLT5zY2FubmVyU3RhdGUgPSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNTZWNvbmREYXNoOworICAgICAgICB9IGVsc2UgeworICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX1N5bnRheEVycm9yOworICAgICAgICB9CisgICAgICAgIGJyZWFrOworICAgIGNhc2UgRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzU2Vjb25kRGFzaDoKKyAgICAgICAgaWYgKGNoID09ICctJykgeworICAgICAgICAgICAgcFNlc3Npb24tPnBhcnNlclN0YXRlID0gRndkTG9ja0NvbnZfUGFyc2VyU3RhdGVfRG9uZTsKKyAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19TeW50YXhFcnJvcjsKKyAgICAgICAgfQorICAgICAgICBicmVhazsKKyAgICBkZWZhdWx0OgorICAgICAgICBzdGF0dXMgPSBGd2RMb2NrQ29udl9TdGF0dXNfUHJvZ3JhbUVycm9yOworICAgICAgICBicmVhazsKKyAgICB9CisgICAgcmV0dXJuIHN0YXR1czsKK30KKworLyoqCisgKiBDaGVja3Mgd2hldGhlciBhIGdpdmVuIGNoYXJhY3RlciBpcyB2YWxpZCBpbiBiYXNlNjQtZW5jb2RlZCBkYXRhLgorICoKKyAqIEBwYXJhbVtpbl0gY2ggVGhlIGNoYXJhY3RlciB0byBjaGVjay4KKyAqCisgKiBAcmV0dXJuIEEgQm9vbGVhbiB2YWx1ZSBpbmRpY2F0aW5nIHdoZXRoZXIgdGhlIGdpdmVuIGNoYXJhY3RlciBpcyB2YWxpZCBpbiBiYXNlNjQtZW5jb2RlZCBkYXRhLgorICovCitzdGF0aWMgaW50IEZ3ZExvY2tDb252X0lzQmFzZTY0Q2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udl9TY2FubmVyU3RhdGVfV2FudHNGaXJzdERhc2g6CisgICAgICAgIGlmIChjaCA9PSAnLScpIHsKKyAgICAgICAgICAgIHBTZXNzaW9uLT5zY2FubmVyU3RhdGUgPSBGd2RMb2NrQ29udl9TY2FubmVyU3RhdGVfV2FudHNTZWNvbmREYXNoOworICAgICAgICB9IGVsc2UgeworICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX1N5bnRheEVycm9yOworICAgICAgICB9CisgICAgICAgIGJyZWFrOworICAgIGNhc2UgRndkTG9ja0NvbnZfU2Nhbm5lclN0YXRlX1dhbnRzU2Vjb25kRGFzaDoKKyAgICAgICAgaWYgKGNoID09ICctJykgeworICAgICAgICAgICAgcFNlc3Npb24tPnBhcnNlclN0YXRlID0gRndkTG9ja0NvbnZfUGFyc2VyU3RhdGVfRG9uZTsKKyAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19TeW50YXhFcnJvcjsKKyAgICAgICAgfQorICAgICAgICBicmVhazsKKyAgICBkZWZhdWx0OgorICAgICAgICBzdGF0dXMgPSBGd2RMb2NrQ29udl9TdGF0dXNfUHJvZ3JhbUVycm9yOworICAgICAgICBicmVhazsKKyAgICB9CisgICAgcmV0dXJuIHN0YXR1czsKK30KKworLyoqCisgKiBQdXNoZXMgYSBzaW5nbGUgY2hhcmFjdGVyIGludG8gdGhlIGNvbnZlcnRlcidzIHN0YXRlIG1hY2hpbmUuCisgKgorICogQHBhcmFtW2luLG91dF0gcFNlc3Npb24gQSByZWZlcmVuY2UgdG8gYSBjb252ZXJ0ZXIgc2Vzc2lvbi4KKyAqIEBwYXJhbVtpbl0gY2ggQSBjaGFyYWN0ZXIuCisgKiBAcGFyYW1baW4sb3V0XSBwT3V0cHV0IFRoZSBvdXRwdXQgZnJvbSB0aGUgY29udmVyc2lvbiBwcm9jZXNzLgorICoKKyAqIEByZXR1cm4gQSBzdGF0dXMgY29kZS4KKyAqLworc3RhdGljIEZ3ZExvY2tDb252X1N0YXR1c190IEZ3ZExvY2tDb252X1B1c2hDaGFyKEZ3ZExvY2tDb252X1Nlc3Npb25fdCAqcFNlc3Npb24sCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaW50IGNoLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIEZ3ZExvY2tDb252X091dHB1dF90ICpwT3V0cHV0KSB7CisgICAgRndkTG9ja0NvbnZfU3RhdHVzX3Qgc3RhdHVzOworICAgICsrcFNlc3Npb24tPm51bUNoYXJzQ29uc3VtZWQ7CisgICAgc3dpdGNoIChwU2Vzc2lvbi0+cGFyc2VyU3RhdGUpIHsKKyAgICBjYXNlIEZ3ZExvY2tDb252X1BhcnNlclN0YXRlX1dhbnRzT3BlbkRlbGltaXRlcjoKKyAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfTWF0Y2hPcGVuRGVsaW1pdGVyKHBTZXNzaW9uLCBjaCk7CisgICAgICAgIGJyZWFrOworICAgIGNhc2UgRndkTG9ja0NvbnZfUGFyc2VyU3RhdGVfV2FudHNNaW1lSGVhZGVyczoKKyAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfTWF0Y2hNaW1lSGVhZGVycyhwU2Vzc2lvbiwgY2gsIHBPdXRwdXQpOworICAgICAgICBicmVhazsKKyAgICBjYXNlIEZ3ZExvY2tDb252X1BhcnNlclN0YXRlX1dhbnRzQmluYXJ5RW5jb2RlZERhdGE6CisgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X01hdGNoQmluYXJ5RW5jb2RlZERhdGEocFNlc3Npb24sIGNoLCBwT3V0cHV0KTsKKyAgICAgICAgYnJlYWs7CisgICAgY2FzZSBGd2RMb2NrQ29udl9QYXJzZXJTdGF0ZV9XYW50c0Jhc2U2NEVuY29kZWREYXRhOgorICAgICAgICBzdGF0dXMgPSBGd2RMb2NrQ29udl9NYXRjaEJhc2U2NEVuY29kZWREYXRhKHBTZXNzaW9uLCBjaCwgcE91dHB1dCk7CisgICAgICAgIGJyZWFrOworICAgIGNhc2UgRndkTG9ja0NvbnZfUGFyc2VyU3RhdGVfRG9uZToKKyAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX09LOworICAgICAgICBicmVhazsKKyAgICBkZWZhdWx0OgorICAgICAgICBzdGF0dXMgPSBGd2RMb2NrQ29udl9TdGF0dXNfUHJvZ3JhbUVycm9yOworICAgICAgICBicmVhazsKKyAgICB9CisgICAgcmV0dXJuIHN0YXR1czsKK30KKworRndkTG9ja0NvbnZfU3RhdHVzX3QgRndkTG9ja0NvbnZfT3BlblNlc3Npb24oaW50ICpwU2Vzc2lvbklkLCBGd2RMb2NrQ29udl9PdXRwdXRfdCAqcE91dHB1dCkgeworICAgIEZ3ZExvY2tDb252X1N0YXR1c190IHN0YXR1czsKKyAgICBpZiAocFNlc3Npb25JZCA9PSBOVUxMIHx8IHBPdXRwdXQgPT0gTlVMTCkgeworICAgICAgICBzdGF0dXMgPSBGd2RMb2NrQ29udl9TdGF0dXNfSW52YWxpZEFyZ3VtZW50OworICAgIH0gZWxzZSB7CisgICAgICAgICpwU2Vzc2lvbklkID0gRndkTG9ja0NvbnZfQWNxdWlyZVNlc3Npb24oKTsKKyAgICAgICAgaWYgKCpwU2Vzc2lvbklkIDwgMCkgeworICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX1Rvb01hbnlTZXNzaW9uczsKKyAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgIEZ3ZExvY2tDb252X1Nlc3Npb25fdCAqcFNlc3Npb24gPSBzZXNzaW9uUHRyc1sqcFNlc3Npb25JZF07CisgICAgICAgICAgICBwU2Vzc2lvbi0+ZW5jcnlwdGVkU2Vzc2lvbktleUxlbmd0aCA9IEZ3ZExvY2tHbHVlX0dldEVuY3J5cHRlZEtleUxl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ICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwU2Vzc2lvbi0+cEVuY3J5cHRlZFNlc3Npb25LZXksCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgcFNlc3Npb24tPmVuY3J5cHRlZFNlc3Npb25LZXlMZW5ndGgpKSB7CisgICAgICAgICAgICAgICAgICAgICAgICBzdGF0dXMgPSBGd2RMb2NrQ29udl9TdGF0dXNfS2V5RW5jcnlwdGlvbkZhaWxlZDsKKyAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgICAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X0Rlcml2ZUtleXMocFNlc3Npb24pOworICAgICAgICAgICAgICAgICAgICB9CisgICAgICAgICAgICAgICAgICAgIGlmIChzdGF0dXMgPT0gRndkTG9ja0NvbnZfU3RhdHVzX09LKSB7CisgICAgICAgICAgICAgICAgICAgICAgICBtZW1zZXQocFNlc3Npb24tPnNlc3Npb25LZXksIDAsIEtFWV9TSVpFKTsgLy8gWmVybyBvdXQga2V5IGRhdGEuCisgICAgICAgICAgICAgICAgICAgICAgICBtZW1jcHkocFNlc3Npb24tPmNvdW50ZXIsIHBTZXNzaW9uLT5wRW5jcnlwdGVkU2Vzc2lvbktleSwgQUVTX0JMT0NLX1NJWkUpOworICAgICAgICAgICAgICAgICAgICAgICAgcFNlc3Npb24tPnBhcnNlclN0YXRlID0gRndkTG9ja0NvbnZfUGFyc2VyU3RhdGVfV2FudHNPcGVuRGVsaW1pdGVyOworICAgICAgICAgICAgICAgICAgICAgICAgcFNlc3Npb24tPnNjYW5uZXJTdGF0ZSA9IEZ3ZExvY2tDb252X1NjYW5uZXJTdGF0ZV9XYW50c0ZpcnN0RGFzaDsKKyAgICAgICAgICAgICAgICAgICAgICAgIHBTZXNzaW9uLT5udW1DaGFyc0NvbnN1bWVkID0gMDsKKyAgICAgICAgICAgICAgICAgICAgICAgIHBTZXNzaW9uLT5kZWxpbWl0ZXJNYXRjaFBvcyA9IDA7CisgICAgICAgICAgICAgICAgICAgICAgICBwU2Vzc2lvbi0+bWltZUhlYWRlck5hbWUgPSBudWxsU3RyaW5nOworICAgICAgICAgICAgICAgICAgICAgICAgcFNlc3Npb24tPmNvbnRlbnRUeXBlID0gbnVsbFN0cmluZzsKKyAgICAgICAgICAgICAgICAgICAgICAgIHBTZXNzaW9uLT5jb250ZW50VHJhbnNmZXJFbmNvZGluZyA9CisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIEZ3ZExvY2tDb252X0NvbnRlbnRUcmFuc2ZlckVuY29kaW5nX1VuZGVmaW5lZDsKKyAgICAgICAgICAgICAgICAgICAgICAgIHBTZXNzaW9uLT5rZXlTdHJlYW1JbmRleCA9IC0xOworICAgICAgICAgICAgICAgICAgICAgICAgcE91dHB1dC0+ZnJvbUNvbnZlcnREYXRhLnBCdWZmZXIgPSBOVUxMOworICAgICAgICAgICAgICAgICAgICAgICAgcE91dHB1dC0+ZnJvbUNvbnZlcnREYXRhLmVycm9yUG9zID0gSU5WQUxJRF9PRkZTRVQ7CisgICAgICAgICAgICAgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICAgICAgICAgICAgICBmcmVlKHBTZXNzaW9uLT5wRW5jcnlwdGVkU2Vzc2lvbktleSk7CisgICAgICAgICAgICAgICAgICAgIH0KKyAgICAgICAgICAgICAgICB9CisgICAgICAgICAgICB9CisgICAgICAgICAgICBpZiAoc3RhdHVzICE9IEZ3ZExvY2tDb252X1N0YXR1c19PSykgeworICAgICAgICAgICAgICAgIEZ3ZExvY2tDb252X1JlbGVhc2VTZXNzaW9uKCpwU2Vzc2lvbklkKTsKKyAgICAgICAgICAgICAgICAqcFNlc3Npb25JZCA9IC0xOworICAgICAgICAgICAgfQorICAgICAgICB9CisgICAgfQorICAgIHJldHVybiBzdGF0dXM7Cit9CisKK0Z3ZExvY2tDb252X1N0YXR1c190IEZ3ZExvY2tDb252X0NvbnZlcnREYXRhKGludCBzZXNzaW9uSWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb25zdCB2b2lkICpwQnVmZmVyLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2l6ZV90IG51bUJ5dGVzLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgRndkTG9ja0NvbnZfT3V0cHV0X3QgKnBPdXRwdXQpIHsKKyAgICBGd2RMb2NrQ29udl9TdGF0dXNfdCBzdGF0dXM7CisgICAgaWYgKCFGd2RMb2NrQ29udl9Jc1ZhbGlkU2Vzc2lvbihzZXNzaW9uSWQpIHx8IHBCdWZmZXIgPT0gTlVMTCB8fCBwT3V0cHV0ID09IE5VTEwpIHsKKyAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX0ludmFsaWRBcmd1bWVudDsKKyAgICB9IGVsc2UgeworICAgICAgICBzaXplX3QgaTsKKyAgICAgICAgRndkTG9ja0NvbnZfU2Vzc2lvbl90ICpwU2Vzc2lvbiA9IHNlc3Npb25QdHJzW3Nlc3Npb25JZF07CisgICAgICAgIHBTZXNzaW9uLT5kYXRhT2Zmc2V0ID0gMDsKKyAgICAgICAgcFNlc3Npb24tPm51bURhdGFCeXRlcyA9IDA7CisgICAgICAgIHBPdXRwdXQtPmZyb21Db252ZXJ0RGF0YS5udW1CeXRlcyA9IDA7CisgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19PSzsKKworICAgICAgICBmb3IgKGkgPSAwOyBpIDwgbnVtQnl0ZXM7ICsraSkgeworICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfUHVzaENoYXIocFNlc3Npb24sICgoY2hhciAqKXBCdWZmZXIpW2ldLCBwT3V0cHV0KTsKKyAgICAgICAgICAgIGlmIChzdGF0dXMgIT0gRndkTG9ja0NvbnZfU3RhdHVzX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nbmluZ0NvbnRleHQsIE5VTEwsIEtFWV9TSVpFLCBOVUxMLCBOVUxMKTsKKyAgICAgICAgICAgICAgICBITUFDX1VwZGF0ZSgmcFNlc3Npb24tPnNpZ25pbmdDb250ZXh0LCBwU2Vzc2lvbi0+dG9wSGVhZGVyLCBUT1BfSEVBREVSX1NJWkUpOworICAgICAgICAgICAgICAgIEhNQUNfVXBkYXRlKCZwU2Vzc2lvbi0+c2lnbmluZ0NvbnRleHQsICh1bnNpZ25lZCBjaGFyICopcFNlc3Npb24tPmNvbnRlbnRUeXBlLnB0ciwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICBwU2Vzc2lvbi0+Y29udGVudFR5cGUubGVuZ3RoKTsKKyAgICAgICAgICAgICAgICBITUFDX1VwZGF0ZSgmcFNlc3Npb24tPnNpZ25pbmdDb250ZXh0LCBwU2Vzc2lvbi0+cEVuY3J5cHRlZFNlc3Npb25LZXksCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgcFNlc3Npb24tPmVuY3J5cHRlZFNlc3Npb25LZXlMZW5ndGgpOworICAgICAgICAgICAgICAgIEhNQUNfVXBkYXRlKCZwU2Vzc2lvbi0+c2lnbmluZ0NvbnRleHQsIHBPdXRwdXQtPmZyb21DbG9zZVNlc3Npb24uc2lnbmF0dXJlcywKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICBzaWduYXR1cmVTaXplKTsKKyAgICAgICAgICAgICAgICBITUFDX0ZpbmFsKCZwU2Vzc2lvbi0+c2lnbmluZ0NvbnRleHQsICZwT3V0cHV0LT5mcm9tQ2xvc2VTZXNzaW9uLgorICAgICAgICAgICAgICAgICAgICAgICAgICAgc2lnbmF0dXJlc1tzaWduYXR1cmVTaXplXSwgJnNpZ25hdHVyZVNpemUpOworICAgICAgICAgICAgICAgIGlmIChzaWduYXR1cmVTaXplICE9IFNIQTFfSEFTSF9TSVpFKSB7CisgICAgICAgICAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19Qcm9ncmFtRXJyb3I7CisgICAgICAgICAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgICAgICAgICAgcE91dHB1dC0+ZnJvbUNsb3NlU2Vzc2lvbi5maWxlT2Zmc2V0ID0gVE9QX0hFQURFUl9TSVpFICsKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICBwU2Vzc2lvbi0+Y29udGVudFR5cGUubGVuZ3RoICsgcFNlc3Npb24tPmVuY3J5cHRlZFNlc3Npb25LZXlMZW5ndGg7CisgICAgICAgICAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19PSzsKKyAgICAgICAgICAgICAgICB9CisgICAgICAgICAgICB9CisgICAgICAgICAgICBwT3V0cHV0LT5mcm9tQ2xvc2VTZXNzaW9uLmVycm9yUG9zID0gSU5WQUxJRF9PRkZTRVQ7CisgICAgICAgIH0KKyAgICAgICAgZnJlZShwU2Vzc2lvbi0+bWltZUhlYWRlck5hbWUucHRyKTsKKyAgICAgICAgZnJlZShwU2Vzc2lvbi0+Y29udGVudFR5cGUucHRyKTsKKyAgICAgICAgZnJlZShwU2Vzc2lvbi0+cEVuY3J5cHRlZFNlc3Npb25LZXkpOworICAgICAgICBITUFDX0NUWF9jbGVhbnVwKCZwU2Vzc2lvbi0+c2lnbmluZ0NvbnRleHQpOworICAgICAgICBGd2RMb2NrQ29udl9SZWxlYXNlU2Vzc2lvbihzZXNzaW9uSWQpOworICAgIH0KKyAgICByZXR1cm4gc3RhdHVzOworfQorCitGd2RMb2NrQ29udl9TdGF0dXNfdCBGd2RMb2NrQ29udl9Db252ZXJ0T3BlbkZpbGUoaW50IGlucHV0RmlsZURlc2MsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgRndkTG9ja0NvbnZfUmVhZEZ1bmNfdCAqZnBSZWFkRnVuYywKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpbnQgb3V0cHV0RmlsZURlc2MsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgRndkTG9ja0NvbnZfV3JpdGVGdW5jX3QgKmZwV3JpdGVGdW5jLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIEZ3ZExvY2tDb252X0xTZWVrRnVuY190ICpmcExTZWVrRnVuYywKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBvZmY2NF90ICpwRXJyb3JQb3MpIHsKKyAgICBGd2RMb2NrQ29udl9TdGF0dXNfdCBzdGF0dXM7CisgICAgaWYgKHBFcnJvclBvcyAhPSBOVUxMKSB7CisgICAgICAgICpwRXJyb3JQb3MgPSBJTlZBTElEX09GRlNFVDsKKyAgICB9CisgICAgaWYgKGZwUmVhZEZ1bmMgPT0gTlVMTCB8fCBmcFdyaXRlRnVuYyA9PSBOVUxMIHx8IGZwTFNlZWtGdW5jID09IE5VTEwgfHwgaW5wdXRGaWxlRGVzYyA8IDAgfHwKKyAgICAgICAgb3V0cHV0RmlsZURlc2MgPCAwKSB7CisgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19JbnZhbGlkQXJndW1lbnQ7CisgICAgfSBlbHNlIHsKKyAgICAgICAgY2hhciAqcFJlYWRCdWZmZXIgPSBtYWxsb2MoUkVBRF9CVUZGRVJfU0laRSk7CisgICAgICAgIGlmIChwUmVhZEJ1ZmZlciA9PSBOVUxMKSB7CisgICAgICAgICAgICBzdGF0dXMgPSBGd2RMb2NrQ29udl9TdGF0dXNfT3V0T2ZNZW1vcnk7CisgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICBpbnQgc2Vzc2lvbklkOworICAgICAgICAgICAgRndkTG9ja0NvbnZfT3V0cHV0X3Qgb3V0cHV0OworICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfT3BlblNlc3Npb24oJnNlc3Npb25JZCwgJm91dHB1dCk7CisgICAgICAgICAgICBpZiAoc3RhdHVzID09IEZ3ZExvY2tDb252X1N0YXR1c19PSykgeworICAgICAgICAgICAgICAgIHNzaXplX3QgbnVtQnl0ZXNSZWFkOworICAgICAgICAgICAgICAgIEZ3ZExvY2tDb252X1N0YXR1c190IGNsb3NlU3RhdHVzOworICAgICAgICAgICAgICAgIHdoaWxlICgobnVtQnl0ZXNSZWFkID0KKyAgICAgICAgICAgICAgICAgICAgICAgIGZwUmVhZEZ1bmMoaW5wdXRGaWxlRGVzYywgcFJlYWRCdWZmZXIsIFJFQURfQlVGRkVSX1NJWkUpKSA+IDApIHsKKyAgICAgICAgICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfQ29udmVydERhdGEoc2Vzc2lvbklkLCBwUmVhZEJ1ZmZlciwgKHNpemVfdCludW1CeXRlc1JlYWQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICZvdXRwdXQpOworICAgICAgICAgICAgICAgICAgICBpZiAoc3RhdHVzID09IEZ3ZExvY2tDb252X1N0YXR1c19PSykgeworICAgICAgICAgICAgICAgICAgICAgICAgaWYgKG91dHB1dC5mcm9tQ29udmVydERhdGEucEJ1ZmZlciAhPSBOVUxMICYmCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgb3V0cHV0LmZyb21Db252ZXJ0RGF0YS5udW1CeXRlcyA+IDApIHsKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICBzc2l6ZV90IG51bUJ5dGVzV3JpdHRlbiA9IGZwV3JpdGVGdW5jKG91dHB1dEZpbGVEZXNjLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgb3V0cHV0LmZyb21Db252ZXJ0RGF0YS5wQnVmZmVyLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgb3V0cHV0LmZyb21Db252ZXJ0RGF0YS5udW1CeXRlcyk7CisgICAgICAgICAgICAgICAgICAgICAgICAgICAgaWYgKG51bUJ5dGVzV3JpdHRlbiAhPSAoc3NpemVfdClvdXRwdXQuZnJvbUNvbnZlcnREYXRhLm51bUJ5dGVzKSB7CisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19GaWxlV3JpdGVFcnJvcjsKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgYnJlYWs7CisgICAgICAgICAgICAgICAgICAgICAgICAgICAgfQorICAgICAgICAgICAgICAgICAgICAgICAgfQorICAgICAgICAgICAgICAgICAgICB9IGVsc2UgeworICAgICAgICAgICAgICAgICAgICAgICAgaWYgKHN0YXR1cyA9PSBGd2RMb2NrQ29udl9TdGF0dXNfU3ludGF4RXJyb3IgJiYgcEVycm9yUG9zICE9IE5VTEwpIHsKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAqcEVycm9yUG9zID0gb3V0cHV0LmZyb21Db252ZXJ0RGF0YS5lcnJvclBvczsKKyAgICAgICAgICAgICAgICAgICAgICAgIH0KKyAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrOworICAgICAgICAgICAgICAgICAgICB9CisgICAgICAgICAgICAgICAgfSAvLyBlbmQgd2hpbGUKKyAgICAgICAgICAgICAgICBpZiAobnVtQnl0ZXNSZWFkIDwgMCkgeworICAgICAgICAgICAgICAgICAgICBzdGF0dXMgPSBGd2RMb2NrQ29udl9TdGF0dXNfRmlsZVJlYWRFcnJvcjsKKyAgICAgICAgICAgICAgICB9CisgICAgICAgICAgICAgICAgY2xvc2VTdGF0dXMgPSBGd2RMb2NrQ29udl9DbG9zZVNlc3Npb24oc2Vzc2lvbklkLCAmb3V0cHV0KTsKKyAgICAgICAgICAgICAgICBpZiAoc3RhdHVzID09IEZ3ZExvY2tDb252X1N0YXR1c19PSykgeworICAgICAgICAgICAgICAgICAgICBpZiAoY2xvc2VTdGF0dXMgIT0gRndkTG9ja0NvbnZfU3RhdHVzX09LKSB7CisgICAgICAgICAgICAgICAgICAgICAgICBpZiAoY2xvc2VTdGF0dXMgPT0gRndkTG9ja0NvbnZfU3RhdHVzX1N5bnRheEVycm9yICYmIHBFcnJvclBvcyAhPSBOVUxMKSB7CisgICAgICAgICAgICAgICAgICAgICAgICAgICAgKnBFcnJvclBvcyA9IG91dHB1dC5mcm9tQ2xvc2VTZXNzaW9uLmVycm9yUG9zOworICAgICAgICAgICAgICAgICAgICAgICAgfQorICAgICAgICAgICAgICAgICAgICAgICAgc3RhdHVzID0gY2xvc2VTdGF0dXM7CisgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoZnBMU2Vla0Z1bmMob3V0cHV0RmlsZURlc2MsIG91dHB1dC5mcm9tQ2xvc2VTZXNzaW9uLmZpbGVPZmZzZXQsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgU0VFS19TRVQpIDwgMCkgeworICAgICAgICAgICAgICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX0ZpbGVTZWVrRXJyb3I7CisgICAgICAgICAgICAgICAgICAgIH0gZWxzZSBpZiAoZnBXcml0ZUZ1bmMob3V0cHV0RmlsZURlc2MsIG91dHB1dC5mcm9tQ2xvc2VTZXNzaW9uLnNpZ25hdHVyZXMsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgRldEX0xPQ0tfU0lHTkFUVVJFU19TSVpFKSAhPSBGV0RfTE9DS19TSUdOQVRVUkVTX1NJWkUpIHsKKyAgICAgICAgICAgICAgICAgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19GaWxlV3JpdGVFcnJvcjsKKyAgICAgICAgICAgICAgICAgICAgfQorICAgICAgICAgICAgICAgIH0KKyAgICAgICAgICAgIH0KKyAgICAgICAgICAgIGZyZWUocFJlYWRCdWZmZXIpOworICAgICAgICB9CisgICAgfQorICAgIHJldHVybiBzdGF0dXM7Cit9CisKK0Z3ZExvY2tDb252X1N0YXR1c190IEZ3ZExvY2tDb252X0NvbnZlcnRGaWxlKGNvbnN0IGNoYXIgKnBJbnB1dEZpbGVuYW1lLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc3QgY2hhciAqcE91dHB1dEZpbGVuYW1lLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgb2ZmNjRfdCAqcEVycm9yUG9zKSB7CisgICAgRndkTG9ja0NvbnZfU3RhdHVzX3Qgc3RhdHVzOworICAgIGlmIChwRXJyb3JQb3MgIT0gTlVMTCkgeworICAgICAgICAqcEVycm9yUG9zID0gSU5WQUxJRF9PRkZTRVQ7CisgICAgfQorICAgIGlmIChwSW5wdXRGaWxlbmFtZSA9PSBOVUxMIHx8IHBPdXRwdXRGaWxlbmFtZSA9PSBOVUxMKSB7CisgICAgICAgIHN0YXR1cyA9IEZ3ZExvY2tDb252X1N0YXR1c19JbnZhbGlkQXJndW1lbnQ7CisgICAgfSBlbHNlIHsKKyAgICAgICAgaW50IGlucHV0RmlsZURlc2MgPSBvcGVuKHBJbnB1dEZpbGVuYW1lLCBPX1JET05MWSk7CisgICAgICAgIGlmIChpbnB1dEZpbGVEZXNjIDwgMCkgeworICAgICAgICAgICAgc3RhdHVzID0gRndkTG9ja0NvbnZfU3RhdHVzX0ZpbGVOb3RGb3VuZDsKKyAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgIGludCBvdXRwdXRGaWxlRGVzYyA9IG9wZW4ocE91dHB1dEZpbGVuYW1lLCBPX0NSRUFUIHwgT19UUlVOQyB8IE9fV1JPTkxZLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBTX0lSVVNSIHwgU19JV1VTUiB8IFNfSVJHUlAgfCBTX0lST1RIKTsKKyAgICAgICAgICAgIGlmIChvdXRwdXRGaWxlRGVz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J0ZWRDb250ZW50VHJhbnNmZXJFbmNvZGluZworICogQHJldHZhbCBGd2RMb2NrQ29udl9TdGF0dXNfUmFuZG9tTnVtYmVyR2VuZXJhdGlvbkZhaWxlZAorICogQHJldHZhbCBGd2RMb2NrQ29udl9TdGF0dXNfS2V5RW5jcnlwdGlvbkZhaWxlZAorICogQHJldHZhbCBGd2RMb2NrQ29udl9TdGF0dXNfRGF0YUVuY3J5cHRpb25GYWlsZWQKKyAqIEByZXR2YWwgRndkTG9ja0NvbnZfU3RhdHVzX0ludGVncml0eVByb3RlY3Rpb25GYWlsZWQKKyAqIEByZXR2YWwgRndkTG9ja0NvbnZfU3RhdHVzX1Rvb01hbnlTZXNzaW9ucworICovCitGd2RMb2NrQ29udl9TdGF0dXNfdCBGd2RMb2NrQ29udl9Db252ZXJ0T3BlbkZpbGUoaW50IGlucHV0RmlsZURlc2MsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgRndkTG9ja0NvbnZfUmVhZEZ1bmNfdCAqZnBSZWFkRnVuYywKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpbnQgb3V0cHV0RmlsZURlc2MsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgRndkTG9ja0NvbnZfV3JpdGVGdW5jX3QgKmZwV3JpdGVGdW5jLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIEZ3ZExvY2tDb252X0xTZWVrRnVuY190ICpmcExTZWVrRnVuYywKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBvZmY2NF90ICpwRXJyb3JQb3MpOworCisvKioKKyAqIENvbnZlcnRzIGFuIE9NQSBEUk0gdjEgRm9yd2FyZCBMb2NrIGZpbGUgdG8gdGhlIGludGVybmFsIEZvcndhcmQgTG9jayBmaWxlIGZvcm1hdCBpbiBwdWxsI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CisgICAgaWYgKGZpbGVEZXNjIDwgMCkgeworICAgICAgICBlcnJubyA9IEVCQURGOworICAgIH0gZWxzZSB7CisgICAgICAgIGludCBpOworICAgICAgICBwdGhyZWFkX211dGV4X2xvY2soJnNlc3Npb25BY3F1aXNpdGlvbk11dGV4KTsKKyAgICAgICAgZm9yIChpID0gMDsgaSA8IE1BWF9OVU1fU0VTU0lPTlM7ICsraSkgeworICAgICAgICAgICAgaW50IGNhbmRpZGF0ZVNlc3Npb25JZCA9IChmaWxlRGVzYyArIGkpICUgTUFYX05VTV9TRVNTSU9OUzsKKyAgICAgICAgICAgIGlmIChzZXNzaW9uUHRyc1tjYW5kaWRhdGVTZXNzaW9uSWRdID09IE5VTEwpIHsKKyAgICAgICAgICAgICAgICBzZXNzaW9uUHRyc1tjYW5kaWRhdGVTZXNzaW9uSWRdID0gbWFsbG9jKHNpemVvZiAqKnNlc3Npb25QdHJzKTsKKyAgICAgICAgICAgICAgICBpZiAoc2Vzc2lvblB0cnNbY2FuZGlkYXRlU2Vzc2lvbklkXSAhPSBOVUxMKSB7CisgICAgICAgICAgICAgICAgICAgIHNlc3Npb25QdHJzW2NhbmRpZGF0ZVNlc3Npb25JZF0tPmZpbGVEZXNjID0gZmlsZURlc2M7CisgICAgICAgICAgICAgICAgICAgIHNlc3Npb25QdHJzW2NhbmRpZGF0ZVNlc3Npb25JZF0tPnBDb250ZW50VHlwZSA9IE5VTEw7CisgICAgICAgICAgICAgICAgICAgIHNlc3Npb25QdHJzW2NhbmRpZGF0ZVNlc3Npb25JZF0tPnBFbmNyeXB0ZWRTZXNzaW9uS2V5ID0gTlVMTDsKKyAgICAgICAgICAgICAgICAgICAgc2Vzc2lvbklkID0gY2FuZGlkYXRlU2Vzc2lvbklkOworICAgICAgICAgICAgICAgIH0KKyAgICAgICAgICAgICAgICBicmVhazsKKyAgICAgICAgICAgIH0KKyAgICAgICAgfQorICAgICAgICBwdGhyZWFkX211dGV4X3VubG9jaygmc2Vzc2lvbkFjcXVpc2l0aW9uTXV0ZXgpOworICAgICAgICBpZiAoaSA9PSBNQVhfTlVNX1NFU1NJT05TKSB7CisgICAgICAgICAgICBlcnJubyA9IEVORklMRTsKKyAgICAgICAgfQorICAgIH0KKyAgICByZXR1cm4gc2Vzc2lvbklkOworfQorCisvKioKKyAqIEZpbmRzIHRoZSBmaWxlIHNlc3Npb24gYXNzb2NpYXRlZCB0byB0aGUgZ2l2ZW4gZmlsZSBkZXNjcmlwdG9yLgorICoKKyAqIEBwYXJhbVtpbl0gZmlsZURlc2MgQSBmaWxlIGRlc2NyaXB0b3IuCisgKgorICogQHJldHVybiBBIHNlc3Npb24gSUQuCisgKi8KK3N0YXRpYyBpbnQgRndkTG9ja0ZpbGVfRmluZFNlc3Npb24oaW50IGZpbGVEZXNjKSB7CisgICAgaW50IHNlc3Npb25JZCA9IC0xOworICAgIGlmIChmaWxlRGVzYyA8IDApIHsKKyAgICAgICAgZXJybm8gPSBFQkFERjsKKyAgICB9IGVsc2UgeworICAgICAgICBpbnQgaTsKKyAgICAgICAgcHRocmVhZF9tdXRleF9sb2NrKCZzZXNzaW9uQWNxdWlzaXRpb25NdXRleCk7CisgICAgICAgIGZvciAoaSA9IDA7IGkgPCBNQVhfTlVNX1NFU1NJT05TOyArK2kpIHsKKyAgICAgICAgICAgIGludCBjYW5kaWRhdGVTZXNzaW9uSWQgPSAoZmlsZURlc2MgKyBpKSAlIE1BWF9OVU1fU0VTU0lPTlM7CisgICAgICAgICAgICBpZiAoc2Vzc2lvblB0cnNbY2FuZGlkYXRlU2Vzc2lvbklkXSAhPSBOVUxMICYmCisgICAgICAgICAgICAgICAgc2Vzc2lvblB0cnNbY2FuZGlkYXRlU2Vzc2lvbklkXS0+ZmlsZURlc2MgPT0gZmlsZURlc2MpIHsKKyAgICAgICAgICAgICAgICBzZXNzaW9uSWQgPSBjYW5kaWRhdGVTZXNzaW9uSWQ7CisgICAgICAgICAgICAgICAgYnJlYWs7CisgICAgICAgICAgICB9CisgICAgICAg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pICE9IDApIHsKKyAgICAgICAgICAgICAgICByZXN1bHQgPSBGQUxTRTsKKyAgICAgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICAgICAgLy8gRW5jcnlwdCB0aGUgMTYtYnl0ZSB2YWx1ZSB7MCwgMCwgLi4uLCAwfSB0byBwcm9kdWNlIHRoZSBlbmNyeXB0aW9uIGtleS4KKyAgICAgICAgICAgICAgICBtZW1zZXQocERhdGEtPnZhbHVlLCAwLCBLRVlfU0laRSk7CisgICAgICAgICAgICAgICAgQUVTX2VuY3J5cHQocERhdGEtPnZhbHVlLCBwRGF0YS0+a2V5LCAmcERhdGEtPnNlc3Npb25Sb3VuZEtleXMpOworICAgICAgICAgICAgICAgIGlmIChBRVNfc2V0X2VuY3J5cHRfa2V5KHBEYXRhLT5rZXksIEtFWV9TSVpFX0lOX0JJVFMsCisgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgJnBTZXNzaW9uLT5lbmNyeXB0aW9uUm91bmRLZXlzKSAhPSAwKSB7CisgICAgICAgICAgICAgICAgICAgIHJlc3VsdCA9IEZBTFNFOworICAgICAgICAgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICAgICAgICAgIC8vIEVuY3J5cHQgdGhlIDE2LWJ5dGUgdmFsdWUgezEsIDAsIC4uLiwgMH0gdG8gcHJvZHVjZSB0aGUgc2lnbmluZyBrZXkuCisgICAgICAgICAgICAgICAgICAgICsrcERhdGEtPnZhbHVlWzBdOworICAgICAgICAgICAgICAgICAgICBBRVNfZW5jcnlwdChwRGF0YS0+dmFsdWUsIHBEYXRhLT5rZXksICZwRGF0YS0+c2Vzc2lvblJvdW5kS2V5cyk7CisgICAgICAgICAgICAgICAgICAgIEhNQUNfQ1RYX2luaXQoJnBTZXNzaW9uLT5zaWduaW5nQ29udGV4dCk7CisgICAgICAgICAgICAgICAgICAgIEhNQUNfSW5pdF9leCgmcFNlc3Npb24tPnNpZ25pbmdDb250ZXh0LCBwRGF0YS0+a2V5LCBLRVlfU0laRSwgRVZQX3NoYTEoKSwgTlVMTCk7CisgICAgICAgICAgICAgICAgfQorICAgICAgICAgICAgfQorICAgICAgICB9CisgICAgICAgIGlmICghcmVzdWx0KSB7CisgICAgICAgICAgICBlcnJubyA9IEVOT1NZUzsKKyAgICAgICAgfQorICAgICAgICBtZW1zZXQocERhdGEsIDAsIHNpemVvZiBwRGF0YSk7IC8vIFplcm8gb3V0IGtleSBkYXRhLgorICAgICAgICBmcmVlKHBEYXRhKTsKKyAgICB9CisgICAgcmV0dXJuIHJlc3VsdDsKK30KKworLyoqCisgKiBDYWxjdWxhdGVzIHRoZSBjb3VudGVyLCB0cmVhdGVkIGFzIGEgMTYtYnl0ZSBsaXR0bGUtZW5kaWFuIG51bWJlciwgdXNlZCB0byBnZW5lcmF0ZSB0aGUga2V5c3RyZWFtCisgKiBmb3IgdGhlIGdpdmVuIGJsb2NrLgorICoKKyAqIEBwYXJhbVtpbl0gcE5vbmNlIEEgcmVmZXJlbmNlIHRvIHRoZSBub25jZS4KKyAqIEBwYXJhbVtpbl0gYmxvY2tJbmRleCBUaGUgaW5kZXggbnVtYmVyIG9mIHRoZSBibG9jay4KKyAqIEBwYXJhbVtvdXRdIHBDb3VudGVyIEEgcmVmZXJlbmNlIHRvIHRoZSBjb3VudGVyLgorICovCitzdGF0aWMgdm9pZCBGd2RMb2NrRmlsZV9DYWxjdWxhdGVDb3VudGVyKGNvbnN0IHVuc2lnbmVkIGNoYXIgKnBOb25jZSwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdWludDY0X3QgYmxvY2tJbmRleCwKKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdW5zaWduZWQgY2hhciAqcENvdW50ZXIpIHsKKyAgICB1bnNpZ25lZCBjaGFyIGNhcnJ5ID0gMDsKKyAgICBzaXplX3QgaSA9IDA7CisgICAgZm9yICg7IGkgPCBzaXplb2YgYmxvY2tJbmRleDsgKytpKSB7C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ICAgICAgICAgICAgIGlmIChwU2Vzc2lvbi0+cEVuY3J5cHRlZFNlc3Npb25LZXkgIT0gTlVMTCAmJgorICAgICAgICAgICAgICAgICAgICAgICAgcmVhZChmaWxlRGVzYywgcFNlc3Npb24tPnBFbmNyeXB0ZWRTZXNzaW9uS2V5LAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICBwU2Vzc2lvbi0+ZW5jcnlwdGVkU2Vzc2lvbktleUxlbmd0aCkgPT0KKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKHNzaXplX3QpcFNlc3Npb24tPmVuY3J5cHRlZFNlc3Npb25LZXlMZW5ndGggJiYKKyAgICAgICAgICAgICAgICAgICAgICAgIHJlYWQoZmlsZURlc2MsIHBTZXNzaW9uLT5kYXRhU2lnbmF0dXJlLCBTSEExX0hBU0hfU0laRSkgPT0KKyAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgU0hBMV9IQVNIX1NJWkUgJiYKKyAgICAgICAgICAgICAgICAgICAgICAgIHJlYWQoZmlsZURlc2MsIHBTZXNzaW9uLT5oZWFkZXJTaWduYXR1cmUsIFNIQTFfSEFTSF9TSVpFKSA9PQorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBTSEExX0hBU0hfU0laRSkgeworICAgICAgICAgICAgICAgICAgICBpc1N1Y2Nlc3MgPSBGd2RMb2NrRmlsZV9EZXJpdmVLZXlzKHBTZXNzaW9uKTsKKyAgICAgICAgICAgICAgICB9CisgICAgICAgICAgICB9CisgICAgICAgIH0KKyAgICAgICAgaWYgKGlzU3VjY2VzcykgeworICAgICAgICAgICAgcFNlc3Npb24tPmRhdGFPZmZzZXQgPSBwU2Vzc2lvbi0+Y29udGVudFR5cGVMZW5ndGggKworICAgICAgICAgICAgICAgICAgICBwU2Vzc2lvbi0+ZW5jcnlwdGVkU2Vzc2lvbktleUxlbmd0aCArIFRPUF9IRUFERVJfU0laRSArIDIgKiBTSEExX0hBU0hfU0laRTsKKyAgICAgICAgICAg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KyAgICAgICAgICAgIGJyZWFrOworICAgICAgICBkZWZhdWx0OgorICAgICAgICAgICAgZXJybm8gPSBFSU5WQUw7CisgICAgICAgICAgICBuZXdGaWxlUG9zID0gSU5WQUxJRF9PRkZTRVQ7CisgICAgICAgICAgICBicmVhazsKKyAgICAgICAgfQorICAgICAgICBpZiAobmV3RmlsZVBvcyAhPSBJTlZBTElEX09GRlNFVCkgeworICAgICAgICAgICAgaWYgKG5ld0ZpbGVQb3MgPCBwU2Vzc2lvbi0+ZGF0YU9mZnNldCkgeworICAgICAgICAgICAgICAgIC8vIFRoZSBuZXcgZmlsZSBwb3NpdGlvbiBpcyBpbGxlZ2FsIGZvciBhbiBpbnRlcm5hbCBGb3J3YXJkIExvY2sgZmlsZS4gUmVzdG9yZSB0aGUKKyAgICAgICAgICAgICAgICAvLyBvcmlnaW5hbCBmaWxlIHBvc2l0aW9uLgorICAgICAgICAgICAgICAgICh2b2lkKWxzZWVrNjQocFNlc3Npb24tPmZpbGVEZXNjLCBwU2Vzc2lvbi0+ZGF0YU9mZnNldCArIHBTZXNzaW9uLT5maWxlUG9zLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgU0VFS19TRVQpOworICAgICAgICAgICAgICAgIGVycm5vID0gRUlOVkFMOworICAgICAgICAgICAgICAgIG5ld0ZpbGVQb3MgPSBJTlZBTElEX09GRlNFVDsKKyAgICAgICAgICAgIH0gZWxzZSB7CisgICAgICAgICAgICAgICAgLy8gVGhlIHJldHVybiB2YWx1ZSBzaG91bGQgYmUgdGhlIGZpbGUgcG9zaXRpb24gdGhhdCBsc2VlazY0KCkgd291bGQgaGF2ZSByZXR1cm5lZAorICAgICAgICAgICAgICAgIC8vIGZvciB0aGUgZW1iZWRkZWQgY29udGVudCBmaWxlLgorICAgICAgICAgICAgICAgIHBTZXNzaW9uLT5maWxlUG9zID0gbmV3RmlsZVBvcyAtIHBTZXNzaW9uLT5kYXRhT2Zmc2V0OworICAgICAgICAgICAgICAgIG5ld0Zpb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pFXTsKKyAgICAgICAgfSAqcERhdGEgPSBtYWxsb2Moc2l6ZW9mICpwRGF0YSk7CisgICAgICAgIGlmIChwRGF0YSA9PSBOVUxMKSB7CisgICAgICAgICAgICByZXN1bHQgPSBGQUxTRTsKKyAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgIEZ3ZExvY2tGaWxlX1Nlc3Npb25fdCAqcFNlc3Npb24gPSBzZXNzaW9uUHRyc1tzZXNzaW9uSWRdOworICAgICAgICAgICAgaWYgKGxzZWVrNjQocFNlc3Npb24tPmZpbGVEZXNjLCBwU2Vzc2lvbi0+ZGF0YU9mZnNldCwgU0VFS19TRVQpICE9CisgICAgICAgICAgICAgICAgICAgIHBTZXNzaW9uLT5kYXRhT2Zmc2V0KSB7CisgICAgICAgICAgICAgICAgcmVzdWx0ID0gRkFMU0U7CisgICAgICAgICAgICB9IGVsc2UgeworICAgICAgICAgICAgICAgIHNzaXplX3QgbnVtQnl0ZXNSZWFkOworICAgICAgICAgICAgICAgIHNpemVfdCBzaWduYXR1cmVTaXplID0gU0hBMV9IQVNIX1NJWkU7CisgICAgICAgICAgICAgICAgd2hpbGUgKChudW1CeXRlc1JlYWQgPQorICAgICAgICAgICAgICAgICAgICAgICAgcmVhZChwU2Vzc2lvbi0+ZmlsZURlc2MsIHBEYXRhLT5idWZmZXIsIFNJR19DQUxDX0JVRkZFUl9TSVpFKSkgPiAwKSB7CisgICAgICAgICAgICAgICAgICAgIEhNQUNfVXBkYXRlKCZwU2Vzc2lvbi0+c2lnbmluZ0NvbnRleHQsIHBEYXRhLT5idWZmZXIsIChzaXplX3QpbnVtQnl0ZXNSZWFkKTsKKyAgICAgICAgICAgICAgICB9CisgICAgICAgICAgICAgICAgaWYgKG51bUJ5dGVzUmVhZCA8IDApIHsKKyAgICAgICAgICAgICAgICAgICAgcmVzdWx0ID0gRkFMU0U7CisgICAgICAgICAgICAgICAgfSBlbHNlIHsKKyAgICAgICAgICAgICAgICAgICAgSE1BQ19GaW5hbCgmcFNlc3Npb24tPnNpZ25pbmdDb250ZXh0LCBwRGF0YS0+c2lnbmF0dXJlLCAmc2lnbmF0dXJlU2l6ZSk7CisgICAgICAgICAgICAgICAgICAgIGFzc2VydChzaWduYXR1cmVTaXplID09IFNIQTFfSEFTSF9TSVpFKTsKKyAgICAgICAgICAgICAgICAgICAgcmVzdWx0ID0gbWVtY21wKHBEYXRhLT5zaWduYXR1cmUsIHBTZXNzaW9uLT5kYXRhU2lnbmF0dXJlLCBzaWduYXR1cmVTaXplKSA9PSAwOworICAgICAgICAgICAgICAgIH0KKyAgICAgICAgICAgICAgICBITUFDX0luaXRfZXgoJnBTZXNzaW9uLT5zaWduaW5nQ29udGV4dCwgTlVMTCwgS0VZX1NJWkUsIE5VTEwsIE5VTEwpOworICAgICAgICAgICAgICAgICh2b2lkKWxzZWVrNjQocFNlc3Npb24tPmZpbGVEZXNjLCBwU2Vzc2lvbi0+ZGF0YU9mZnNldCArIHBTZXNzaW9uLT5maWxlUG9zLAorICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgU0VFS19TRVQpOworICAgICAgICAgICAgfQorICAgICAgICAgICAgZnJlZShwRGF0YSk7CisgICAgICAgIH0KKyAgICB9CisgICAgcmV0dXJuIHJlc3VsdDsKK30KKworaW50IEZ3ZExvY2tGaWxlX0NoZWNrSGVhZGVySW50ZWdyaXR5KGludCBmaWxlRGVzYykgeworICAgIGludCByZXN1bHQ7CisgICAgaW50IHNlc3Npb25JZCA9IEZ3ZExvY2tGaWxlX0ZpbmRTZXNzaW9uKGZpbGVEZXNjKTsKKyAgICBpZiAoc2Vzc2lvbklkIDwgMCkgeworICAgICAgICByZXN1bHQgPSBGQUxTRTsKKyAgICB9IGVsc2UgeworICAgICAgICBGd2RMb2NrRmlsZV9TZXNzaW9uX3QgKnBTZXNzaW9uID0gc2Vzc2lvblB0cnNbc2Vzc2lvbklkXTsKKyAgICAgICAgdW5zaWduZWQgY2hhciBzaWduYXR1cmVbU0hBMV9IQVNIX1NJ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bS9hbmRyb2lkL2ludGVybmFsL3BvbGljeS9pbXBsL0tleWd1YXJkVmlld01hbmFnZXIuamF2YQorKysgYi9wb2xpY3kvc3JjL2NvbS9hbmRyb2lkL2ludGVybmFsL3BvbGljeS9pbXBsL0tleWd1YXJkVmlld01hbmFnZXIuamF2YQpAQCAtMjI5LDggKzIyOSw4IEBACiAgICAgICAgICAgICAgICAgbUtleWd1YXJkSG9zdC5wb3N0RGVsYXllZChuZXcgUnVubmFibGUoKSB7CiAgICAgICAgICAgICAgICAgICAgIHB1YmxpYyB2b2lkIHJ1bigpIHsKICAgICAgICAgICAgICAgICAgICAgICAgIHN5bmNocm9uaXplZCAoS2V5Z3VhcmRWaWV3TWFuYWdlci50aGlzKSB7Ci0gICAgICAgICAgICAgICAgICAgICAgICAgICAgbUtleWd1YXJkSG9zdC5yZW1vdmVWaWV3KGxhc3RWaWV3KTsKICAgICAgICAgICAgICAgICAgICAgICAgICAgICBsYXN0Vmlldy5jbGVhblVwKCk7CisgICAgICAgICAgICAgICAgICAgICAgICAgICAgbUtleWd1YXJkSG9zdC5yZW1vdmVWaWV3KGxhc3RWaWV3KTsKICAgICAgICAgICAgICAgICAgICAgICAgIH0KICAgICAgICAgICAgICAgICAgICAgfQogICAgICAgICAgICAgICAgIH0sIDUwMCk7CmRpZmYgLS1naXQgYS9wb2xpY3kvc3JjL2NvbS9hbmRyb2lkL2ludGVybmFsL3BvbGljeS9pbXBsL0xvY2tQYXR0ZXJuS2V5Z3VhcmRWaWV3LmphdmEgYi9wb2xpY3kvc3JjL2NvbS9hbmRyb2lkL2ludGVybmFsL3BvbGljeS9pbXBsL0xvY2tQYXR0ZXJuS2V5Z3VhcmRWaWV3LmphdmEKaW5kZXggODIyYmU0Ni4uODg2Yjg1ZiAxMDA2NDQKLS0tIGEvcG9saWN5L3NyYy9jb20vYW5kcm9pZC9pbnRlcm5hbC9wb2xpY3kvaW1wbC9Mb2NrUGF0dGVybktleWd1YXJkVmlldy5qYXZhCisrKyBi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