如何删除Java无限强度策略文件?

时间:2016-01-29 11:59:21

标签: java cryptography aes jce

我已经安装了无限制的Java策略文件。我已将其安装在- (void)TcpClientInitialise { NSLog(@"Tcp Client Initialise"); CFReadStreamRef readStream; CFWriteStreamRef writeStream; CFStreamCreatePairWithSocketToHost(NULL, (__bridge CFStringRef)_IPAddress.text,(int)_port.text.integerValue, &readStream, &writeStream); [consoleLog appendString:[NSString stringWithFormat:@"IPAddress - %@ and port %d \n", _IPAddress.text,(int)_port.text.integerValue]]; _console.text = consoleLog; [InputStream setProperty:NSStreamSocketSecurityLevelNegotiatedSSL forKey: (__bridge NSString *)kCFStreamPropertySSLSettings]; InputStream = (__bridge NSInputStream *)readStream; OutputStream = (__bridge NSOutputStream *)writeStream; [InputStream setDelegate:self]; [OutputStream setDelegate:self]; [InputStream scheduleInRunLoop:[NSRunLoop currentRunLoop] forMode:NSDefaultRunLoopMode]; [OutputStream scheduleInRunLoop:[NSRunLoop currentRunLoop] forMode:NSDefaultRunLoopMode]; [InputStream open]; [OutputStream open]; } JavaHome/jre/lib/security

现在,当我运行程序并检查安装这些文件后允许的最大密钥大小时,它会抛出错误。

我不认为在jdk目录中安装文件是一个问题,因为我已经在Eclipse中运行Java一周了,其他一切运行正常(AES 128位程序)但是当我想到如何正确安装我在JavaHome/jdk/jre/lib/security目录中安装文件的文件。在我这样做并使用AES128位加密运行相同程序的那一刻,我得到了error message

有没有办法解决这个问题?

可能是导致此错误的原因是什么?

0 个答案:

没有答案
相关问题