- int start = 0;
- int end = 1;
- int comma;
- int length = subject.length();
-
- compare:
- while(start<length) {
- while(Character.isWhitespace(subject.charAt(start))) {
- if(++start>length) {
- break compare;
- }
- }
- comma = subject.indexOf(',',start);
- if(comma<0) {
- end = subject.length();
- } else {
- end = comma<=0?0:comma-1;
- }
- while(Character.isWhitespace(subject.charAt(end))) {
- if(--end < 0) {
- break compare;
- }
- }
- if(subject.regionMatches(start, "OU=", 0, 3) ||
- subject.regionMatches(start, "CN=", 0, 3)) {
- int at = subject.indexOf('@', start);
- if(at<end && at>=0) {
+ int start = 0;
+ int end = 1;
+ int comma;
+ int length = subject.length();
+
+ compare:
+ while(start<length) {
+ while(Character.isWhitespace(subject.charAt(start))) {
+ if(++start>length) {
+ break compare;
+ }
+ }
+ comma = subject.indexOf(',',start);
+ if(comma<0) {
+ end = subject.length();
+ } else {
+ end = comma<=0?0:comma-1;
+ }
+ while(Character.isWhitespace(subject.charAt(end))) {
+ if(--end < 0) {
+ break compare;
+ }
+ }
+ if(subject.regionMatches(start, "OU=", 0, 3) ||
+ subject.regionMatches(start, "CN=", 0, 3)) {
+ int at = subject.indexOf('@', start);
+ if(at<end && at>=0) {