当我在IOS中集成CCAVINE支付门方式时,我获得了Exe\u Bad\u访问权限(代码=1地址=0X38)
我按照以下步骤集成了非无耻的当我在IOS中集成CCAVINE支付门方式时,我获得了Exe\u Bad\u访问权限(代码=1地址=0X38),ios,objective-c,iphone,encryption,ccavenue,Ios,Objective C,Iphone,Encryption,Ccavenue,我按照以下步骤集成了非无耻的CCAvenue网关 步骤:- 我有我的商户id和访问代码(url、ip) 我正在呼叫我的服务器以获取RSA密钥参数(访问代码、订单id) //我的服务器已在CCAvenue服务器中注册 2.我的服务器正在调用获取RSA密钥的途径 3.我的服务器转发RSA密钥 4.一旦获得,我将删除额外的行“\n”、双引号“--”和“\” 5.我把钥匙放在 rsaKey = [NSString stringWithFormat:@"-----BEGIN PUBLIC KEY-----
CCAvenue
网关
步骤:-
我有我的商户id和访问代码(url、ip)
rsaKey = [NSString stringWithFormat:@"-----BEGIN PUBLIC KEY-----\n%@\n-----END PUBLIC KEY-----\n",newReplacedString1];
//*******//***//****//**// output //*******//***//****//**//
NSString *myRequestString = [NSString stringWithFormat:@"amount=%@¤cy=%@",amount,currency];(2,INR)
CCTool *ccTool = [[CCTool alloc] init];
NSString *encVal = [ccTool encryptRSA:myRequestString key:rsaKey];
如何解决这个问题。请帮帮我伙计们 这一定是您从服务器获取的返回密钥有问题。这里似乎没有正确配置服务器。我们也有同样的问题。只需将此错误报告发送到此电子邮件:service@ccavenue.com
其技术支持电子邮件。您可以询问他们的联系电话以获得技术支持,集成过程中您可能遇到的任何技术问题都会很快得到解答。根据错误消息,可以看到发生了内存泄漏 我也遇到过类似的错误 你可以试试我的方法 Xcode->编辑方案->运行->诊断->选择地址消毒器
运行您的项目。嗨,谢谢您的支持,我终于解决了我的问题 一旦您从您的服务器获得rsa密钥,您需要删除新行“\n”、斜杠“\”和双引号“\” 这里我们需要将其转换为ba64encryption格式的输入 你需要将我们的字符串转换为完全相同的, 1.每行“字符串”必须为64个字符宽。 2.必须以换行符终止 我正在更新我的代码。对我来说,它工作得很好
NSString *rsaKey = [[NSString alloc] initWithData:data encoding:NSASCIIStringEncoding];
//NSString*rsaKey=[[NSString alloc]initWithData:数据编码:NSASCISTRINGEncoding]
NSLog(@"%@",rsaKey);
//rsaKey=[rsaKey stringByTrimmingCharactersInSet:[NSCharacterSet newlineCharacterSet]];
//NSLog(@“%@”,rsaKey)
//删除双四分之一
NSString*newReplacedString2=[rsaKey stringByReplacingOccurrencesOfString:@“\”with string:@”“];
NSLog(@“%@”,rsaKey);
//正在删除注册表项中的\n
NSString*newReplacedString=[newReplacedString2 stringByReplacingOccurrencesOfString:@“\\n”with string:@”“;
NSLog(@“%@”,rsaKey);
//正在删除注册表项中的\项
NSString*newReplacedString1=[newreplacedstringbyreplacingoccurrencesofstring:@“\\”with string:@”“];
NSLog(@“%@”,newReplacedString1);
NSString*abc=[NSString stringWithFormat:@“%@”,newReplacedString1];
NSMutableString*sss=[NSMutableString new];
int j=(int)([abc长度]/63);
对于(int i=0;iGokilani hi),我已经发送了我的报告/Users/hmw-pc1/Downloads/iosrsaformat.txtHi我已经向他们发送了报告他们正在使用此格式,我做了相同的操作,但遇到了相同的问题:(@Bhumi Goklanibhumi我会转发我的代码你能检查一下吗…请,我尝试了所有的方法,但没有得到结果。好的。请给我dropbox链接。我可以试试。没有@Huber J输出没有变化:(应用太多内存空间,释放时间没有完全释放。你应该检查一下,我遇到了这样的错误。
MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAuV7OdmPSutrlOE9lF3YdW4ymGn+qselCOycMk95Tobw1PcqCeAWkrnxUECpAdnHGrUKmFbEDHs3wnwzLTbfa3GvE5dvvmluug78X3RYEFQiMh1QpfS5fBfvs4WQKw7oigko3G0UwZLZFnZ4E4WKTQi4wbCgjwQJFMnMGJfFYNcoSJluVg/q8z3bVxfDOV0ZPWccmvA3bTf9YFHKCC3clscQrGf1NPnBGcBGm+s06t3EljoSmpjtyTgSiGrqBZ8TSCQxoyXxS+RkhNTigg6mqW9hIisxYYqlbzvRnCDhuqgZfmP7t65QG5raELVE7d+Ia+dgh024luZ9+vSk4Qb65DQIDAQAB
NSString *rsaKey = [[NSString alloc] initWithData:data encoding:NSASCIIStringEncoding];
NSLog(@"%@",rsaKey);
// removing double quates
NSString * newReplacedString2 = [rsaKey stringByReplacingOccurrencesOfString:@"\"" withString:@""];
NSLog(@"%@",rsaKey);
//removing \n in the key
NSString * newReplacedString = [newReplacedString2 stringByReplacingOccurrencesOfString:@"\\n" withString:@""];
NSLog(@"%@",rsaKey);
//removing \ in the key
NSString * newReplacedString1 = [newReplacedString stringByReplacingOccurrencesOfString:@"\\" withString:@""];
NSLog(@"%@",newReplacedString1);
NSString * abc = [NSString stringWithFormat:@"%@", newReplacedString1];
NSMutableString *sss=[NSMutableString new];
int j=(int)([abc length]/63);
for (int i=0; i<=j; i++) {
int k= i*63;
NSString * newString;
if (i != j) {
newString = [abc substringWithRange:NSMakeRange(k,63)];
NSLog(@"%lu",(unsigned long)newString.length);
newString=[NSString stringWithFormat:@"%@",newString];
}else{
newString = [abc substringWithRange:NSMakeRange(k,[abc length]-k)];
NSLog(@"%lu",(unsigned long)newString.length);
if (newString.length !=0)
newString=[NSString stringWithFormat:@"%@",newString];
}
if (newString.length !=0)
[sss appendString:[NSString stringWithFormat:@"%@\n",newString]];
}
NSLog(@"%@",sss);
rsaKey = [NSString stringWithFormat:@"-----BEGIN PUBLIC KEY-----\n%@-----END PUBLIC KEY-----\n",sss];
NSLog(@"%@",rsaKey);
//Encrypting Card Details
NSString *myRequestString = [NSString stringWithFormat:@"amount=%@¤cy=%@",amount,currency];
CCTool *ccTool = [[CCTool alloc] init];
NSLog(@"emcrpted data skfjsf jakdfhjklfhjk%@",[ccTool encryptRSA:myRequestString key:rsaKey]);
Happy Coding. :)