X-Git-Url: https://code.wpia.club/?a=blobdiff_plain;f=src%2Forg%2Fcacert%2Fgigi%2Fpages%2Fwot%2FAssuranceForm.java;h=6e37ecc88fdafd8412a344526108f39ace94e167;hb=6887ff6c8341dfafc1caf627b853a1b05eaf5af1;hp=b1cfbae950ae09afecb62ad6610d3a41676f5f1e;hpb=e545cb295b12e3ecb0d777b2f2b6a601c9b27387;p=gigi.git diff --git a/src/org/cacert/gigi/pages/wot/AssuranceForm.java b/src/org/cacert/gigi/pages/wot/AssuranceForm.java index b1cfbae9..6e37ecc8 100644 --- a/src/org/cacert/gigi/pages/wot/AssuranceForm.java +++ b/src/org/cacert/gigi/pages/wot/AssuranceForm.java @@ -37,6 +37,8 @@ public class AssuranceForm extends Form { private String aword; + private User assurer; + private static final Template templ; static { templ = new Template(AssuranceForm.class.getResource("AssuranceForm.templ")); @@ -44,6 +46,7 @@ public class AssuranceForm extends Form { public AssuranceForm(HttpServletRequest hsr, User assuree) { super(hsr); + assurer = Page.getUser(hsr); this.assuree = assuree; assureeName = this.assuree.getName(); dob = this.assuree.getDoB(); @@ -59,7 +62,7 @@ public class AssuranceForm extends Form { res.putAll(vars); res.put("nameExplicit", assuree.getName()); res.put("name", assuree.getName().toString()); - res.put("maxpoints", assuree.getMaxAssurePoints()); + res.put("maxpoints", assurer.getMaxAssurePoints()); res.put("dob", sdf.format(assuree.getDoB())); res.put("dobFmt2", sdf2.format(assuree.getDoB())); res.put("location", location); @@ -105,7 +108,7 @@ public class AssuranceForm extends Form { return false; } try { - Notary.assure(Page.getUser(req), assuree, assureeName, dob, pointsI, location, req.getParameter("date")); + Notary.assure(assurer, assuree, assureeName, dob, pointsI, location, req.getParameter("date")); if (aword != null && !aword.equals("")) { String systemToken = RandomToken.generateToken(32); int id = assuree.generatePasswordResetTicket(Page.getUser(req), systemToken, aword); @@ -113,7 +116,7 @@ public class AssuranceForm extends Form { Language l = Language.getInstance(assuree.getPreferredLocale()); StringBuffer body = new StringBuffer(); body.append(l.getTranslation("Hi,") + "\n\n"); - body.append(l.getTranslation("A password reset was triggered. If you did a password reset by assurance, please enter your secret password using this form: \n")); + body.append(l.getTranslation("A password reset was triggered. If you did a password reset by assurance, please enter your secret password using this form: \nhttps://")); body.append(ServerConstants.getWwwHostNamePortSecure() + PasswordResetPage.PATH); body.append("?id="); body.append(id);