diff --git a/ChangeLog b/ChangeLog
index 6fd715ce38..11c58d4abd 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+31-AUG-2020: 13.6.6
+
+- Removes PWA for www.draw.io
+- Improves Gliffy import
+
24-AUG-2020: 13.6.5
- Corrects classpath for CacheFacade
diff --git a/VERSION b/VERSION
index b22e91bfa5..4c39112331 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-13.6.5
\ No newline at end of file
+13.6.6
\ No newline at end of file
diff --git a/etc/build/build.xml b/etc/build/build.xml
index 1e3cca3dcc..f6d58ad4a4 100644
--- a/etc/build/build.xml
+++ b/etc/build/build.xml
@@ -138,6 +138,7 @@
+
diff --git a/src/main/java/com/mxgraph/online/AbsAuthServlet.java b/src/main/java/com/mxgraph/online/AbsAuthServlet.java
index 9f027eb1f3..08a79cd55e 100644
--- a/src/main/java/com/mxgraph/online/AbsAuthServlet.java
+++ b/src/main/java/com/mxgraph/online/AbsAuthServlet.java
@@ -16,6 +16,7 @@
import java.security.SecureRandom;
import java.util.HashMap;
import java.util.logging.Logger;
+import java.util.logging.Level;
import javax.cache.Cache;
import javax.cache.CacheException;
@@ -127,7 +128,7 @@ protected void doGet(HttpServletRequest request,
String state = new BigInteger(256, random).toString(32);
String key = new BigInteger(256, random).toString(32);
putCacheValue(key, state);
-// log.log(Level.INFO, "AUTH-SERVLET: [" + request.getRemoteAddr() + "] Added state (" + key + " -> " + state + ")");
+ log.log(Level.INFO, "AUTH-SERVLET: [" + request.getRemoteAddr() + "] Added state (" + key + " -> " + state + ")");
response.setStatus(HttpServletResponse.SC_OK);
//Chrome blocks this cookie when draw.io is running in an iframe. The cookie is added to parent frame. TODO FIXME
response.setHeader("Set-Cookie", STATE_COOKIE + "=" + key + "; Max-Age=" + COOKIE_AGE + ";path=" + cookiePath + "; Secure; HttpOnly; SameSite=none"); //10 min to finish auth
@@ -176,7 +177,7 @@ protected void doGet(HttpServletRequest request,
//Get the cached state based on the cookie key
String cacheKey = cookie.getValue();
cookieToken = (String) tokenCache.get(cacheKey);
-// log.log(Level.INFO, "AUTH-SERVLET: [" + request.getRemoteAddr() + "] Found cookie state (" + cacheKey + " -> " + cookieToken + ")");
+ log.log(Level.INFO, "AUTH-SERVLET: [" + request.getRemoteAddr() + "] Found cookie state (" + cacheKey + " -> " + cookieToken + ")");
//Delete cookie & cache after being used since it is a single use
tokenCache.remove(cacheKey);
response.setHeader("Set-Cookie", STATE_COOKIE + "= ;path=" + cookiePath + "; expires=Thu, 01 Jan 1970 00:00:00 UTC; Secure; HttpOnly; SameSite=none");
@@ -216,7 +217,7 @@ else if ((code == null && refreshToken == null) || client == null || redirectUri
//Non GAE runtimes are excluded from state check. TODO Change GAE stub to return null from CacheFactory
else if (!"Non".equals(SystemProperty.environment.get()) && (stateToken == null || !stateToken.equals(cookieToken)))
{
-// log.log(Level.WARNING, "AUTH-SERVLET: [" + request.getRemoteAddr() + "] STATE MISMATCH (state: " + stateToken + " != cookie: " + cookieToken + ")");
+ log.log(Level.WARNING, "AUTH-SERVLET: [" + request.getRemoteAddr() + "] STATE MISMATCH (state: " + stateToken + " != cookie: " + cookieToken + ")");
response.setStatus(HttpServletResponse.SC_UNAUTHORIZED);
}
else
diff --git a/src/main/webapp/electron.js b/src/main/webapp/electron.js
index b940e7dba7..34eeb14f63 100644
--- a/src/main/webapp/electron.js
+++ b/src/main/webapp/electron.js
@@ -1199,6 +1199,20 @@ function exportDiagram(event, args, directFinalize)
browser.capturePage().then(function(img)
{
//Image is double the given bounds, so resize is needed!
+ var tScale = 1;
+
+ //If user defined width and/or height, enforce it precisely here. Height override width
+ if (args.h)
+ {
+ tScale = args.h / newBounds.height;
+ }
+ else if (args.w)
+ {
+ tScale = args.w / newBounds.width;
+ }
+
+ newBounds.width *= tScale;
+ newBounds.height *= tScale;
img = img.resize(newBounds);
var data = args.format == 'png'? img.toPNG() : img.toJPEG(args.jpegQuality || 90);
diff --git a/src/main/webapp/export-fonts.css b/src/main/webapp/export-fonts.css
new file mode 100644
index 0000000000..747e937e3e
--- /dev/null
+++ b/src/main/webapp/export-fonts.css
@@ -0,0 +1 @@
+/* Add any special fonts css for export3.html (mainly PDF export) */
\ No newline at end of file
diff --git a/src/main/webapp/export3.html b/src/main/webapp/export3.html
index b7eff1e0ff..fa5fe09b96 100644
--- a/src/main/webapp/export3.html
+++ b/src/main/webapp/export3.html
@@ -5,6 +5,21 @@
+