This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo perl -pi -e "s/\[security\]/\[security\]\nforce_https_protocol=PROTOCOL_TLSv1_2/g" /etc/ambari-agent/conf/ambari-agent.ini | |
sudo perl -pi -e "s/platform_default/disable/g" /etc/python/cert-verification.cfg |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$master_script = <<SCRIPT | |
#!/bin/bash | |
apt-get install curl -y | |
curl -s https://archive.cloudera.com/cm6/6.2.0/ubuntu1604/apt/cloudera-manager.list > /etc/apt/sources.list.d/cloudera-manager.list | |
curl -s https://archive.cloudera.com/cm6/6.2.0/ubuntu1804/apt/archive.key > key | |
apt-key add key | |
rm key | |
apt-get update |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <pthread.h> | |
#include <yara.h> | |
#include <stdio.h> | |
int callback_function(int, void*, void*); | |
void *YaraWorker(void *); | |
void *Segfaulter(); | |
void *Safebet(); | |
typedef struct yargs_struct { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "yara.h" | |
#include "stdio.h" | |
int callback_function(int, void*, void*); | |
int main() { | |
int ret = yr_initialize(); | |
YR_COMPILER* compiler = malloc(sizeof(YR_COMPILER)); | |
int compiler_create = yr_compiler_create(&compiler); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
https://github.com/apache/accumulo/blob/master/test/src/main/java/org/apache/accumulo/test/randomwalk/security/WalkingSecurity.java#L253 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SampleClient { | |
com.sun.security.auth.module.Krb5LoginModule required | |
debug=true | |
useTicketCache=true | |
doNotPrompt=true | |
renewTGT=true | |
; | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.{FileOutputStream, BufferedOutputStream, OutputStream, File} | |
import java.security.PrivilegedAction | |
import javax.security.auth.Subject | |
import com.google.common.io.Files | |
import org.apache.accumulo.cluster.ClusterUser | |
import org.apache.accumulo.core.client.impl.Namespaces | |
import org.apache.accumulo.core.client.{BatchWriterConfig, ClientConfiguration} | |
import org.apache.accumulo.core.client.security.tokens.KerberosToken | |
import org.apache.accumulo.core.conf.Property |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
root@miniInstance> createtable foo | |
2016-01-29 15:56:40,399 INFO [MiniShell.main()] Shell.audit (Shell.java:execCommand(685)) - root@miniInstance> createtable foo | |
root@miniInstance foo> setiter -all -class org.apache.accumulo.core.iterators.user.RowDeletingIterator -p 10 | |
2016-01-29 15:57:01,463 INFO [MiniShell.main()] Shell.audit (Shell.java:execCommand(685)) - root@miniInstance foo> setiter -all -class org.apache.accumulo.core.iterators.user.RowDeletingIterator -p 10 | |
2016-01-29 15:57:01,530 WARN [MiniShell.main()] vfs.AccumuloVFSClassLoader (AccumuloVFSClassLoader.java:resolve(160)) - ignoring classpath entry file:///lib/ext/[^.].*.jar | |
The iterator class does not implement OptionDescriber. Consider this for better iterator configuration using this setiter command. | |
Name for iterator (enter to skip): org.apache.accumulo.core.iterators.user.RowDeletingIterator | |
Optional, configure name-value options for iterator: | |
----------> set option (<name> <value>, hit enter to skip): | |
root@miniInstance foo> config -t foo - |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def main(args: Array[String]): Unit = { | |
Logger.getLogger("org.apache.zookeeper").setLevel(Level.OFF) | |
val log = LoggerFactory.getLogger(getClass) | |
val work_dir = Files.createTempDir() | |
log.info("Working dir: {}", work_dir) | |
val password = "secret" | |
val accumulo = new MiniAccumuloCluster(new MiniAccumuloConfig(Files.createTempDir(), password)) | |
var returnCode: Option[Int] = None | |
try { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Similar to setting up the regular MiniAccumuloCluster, but we use the *Impl classes directly | |
object Demo { | |
def main(args : Array[String]): Unit = { | |
var dir: File = null | |
var accumulo: MiniAccumuloClusterImpl = null | |
try { | |
dir = Files.createTempDir(); | |
dir.deleteOnExit() | |
println("Working in " + dir) |
NewerOlder