修改异常信息
This commit is contained in:
@@ -14,7 +14,7 @@ public class SydSM3 implements ISM3 {
|
||||
|
||||
public void update(byte[] pcData) {
|
||||
if (is_finished) {
|
||||
throw new SydApiException(0);
|
||||
throw new SydApiException(0x8007);
|
||||
}
|
||||
if (null == pcData || 0 == pcData.length) {
|
||||
pcData = new byte[0];
|
||||
@@ -33,7 +33,7 @@ public class SydSM3 implements ISM3 {
|
||||
|
||||
public String digest() {
|
||||
if (is_finished) {
|
||||
throw new SydApiException(0);
|
||||
throw new SydApiException(0x8007);
|
||||
}
|
||||
this.is_finished = true;
|
||||
if (null == pcProcData) {
|
||||
|
||||
@@ -30,10 +30,10 @@ public class SydSM4 implements ISM4 {
|
||||
}
|
||||
int plength = pcData.length;
|
||||
if (is_finished) {
|
||||
throw new SydApiException(0);
|
||||
throw new SydApiException(0x8007);
|
||||
}
|
||||
if (plength > 4064) {
|
||||
throw new SydApiException(0);
|
||||
throw new SydApiException(0x8006);
|
||||
}
|
||||
if (iFlag == 1) {
|
||||
if (0 == queue.getLength()) {
|
||||
@@ -80,7 +80,7 @@ public class SydSM4 implements ISM4 {
|
||||
|
||||
public byte[] finish() {
|
||||
if (is_finished) {
|
||||
throw new SydApiException(0);
|
||||
throw new SydApiException(0x8007);
|
||||
}
|
||||
this.is_finished = true;
|
||||
if (1 == this.iPkgNum) {
|
||||
|
||||
@@ -32,10 +32,10 @@ public class SydSM4Backup implements ISM4 {
|
||||
}
|
||||
int plength = pcData.length;
|
||||
if (is_finished) {
|
||||
throw new SydApiException(0);
|
||||
throw new SydApiException(0x8007);
|
||||
}
|
||||
if (plength > 4064) {
|
||||
throw new SydApiException(0);
|
||||
throw new SydApiException(0x8006);
|
||||
}
|
||||
if (iFlag == 1) {
|
||||
if (0 == sourceWrap.array().length) {
|
||||
@@ -136,7 +136,7 @@ public class SydSM4Backup implements ISM4 {
|
||||
|
||||
public byte[] finish() {
|
||||
if (is_finished) {
|
||||
throw new SydApiException(0);
|
||||
throw new SydApiException(0x8007);
|
||||
}
|
||||
this.is_finished = true;
|
||||
if (1 == this.iPkgNum) {
|
||||
|
||||
@@ -73,7 +73,7 @@ public class SydSM4Mac implements ISM4Mac {
|
||||
public String disget() {
|
||||
|
||||
if (is_finished) {
|
||||
throw new SydApiException(0);
|
||||
throw new SydApiException(0x8007);
|
||||
}
|
||||
this.is_finished = true;
|
||||
if (1 == this.iPkgNum) {
|
||||
|
||||
Reference in New Issue
Block a user