Examples of NFEProperties


Examples of br.com.caelum.stella.nfe.config.NFEProperties

public class NFEPropertiesTest {

  @Test
  public void deveLerOArquivoDeConfiguracaoDefault() {

    NFEProperties nfeProperties = new NFEProperties();

    assertNotNull(nfeProperties.getProperty("arquivo.config.token"));
    assertNotNull(nfeProperties.getProperty("certificado.senha"));
  }
View Full Code Here

Examples of br.com.caelum.stella.nfe.config.NFEProperties

      throw new RuntimeException(e);
    }
  }

  public void enableSSLForServer() {
    String serverCertificateFile = new NFEProperties().getProperty("arquivo.certificado.servidor");
    InputStream is = this.getClass().getResourceAsStream(serverCertificateFile);
    enableSSLForServer(is,defaultPassword);
  }
View Full Code Here

Examples of br.com.caelum.stella.nfe.config.NFEProperties

 
  public static void main(String[] args) {
    try {
     

      NFEProperties prop = new NFEProperties();

      tokenConfigFile = prop.getProperty("arquivo.config.token");

      senhaDoCertificado = prop.getProperty("certificado.senha");
      alias = prop.getProperty("certificado.alias");

      TokenKeyStoreForWindows ks = new TokenKeyStoreForWindows(tokenConfigFile, TokenAlgorithm.PKCS11, senhaDoCertificado);
      ks.getCertificateFor(alias).enableSSLForServer();

      ObjectFactory factoryWS = new ObjectFactory();
View Full Code Here

Examples of br.com.caelum.stella.nfe.config.NFEProperties

  private static String alias = null;

  public static void main(String[] args) {
    try {

      NFEProperties prop = new NFEProperties();

      tokenConfigFile = prop.getProperty("arquivo.config.token");

      senhaDoCertificado = prop.getProperty("certificado.senha");
      alias = prop.getProperty("certificado.alias");

      TokenKeyStoreForWindows ks = new TokenKeyStoreForWindows(tokenConfigFile, TokenAlgorithm.PKCS11,
          senhaDoCertificado);
      ks.getCertificateFor(alias).enableSSLForServer();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.