SignUpScreenletSignUpScreenlethttps://liferay.dev/en/c/message_boards/find_thread?p_l_id=119785333&threadId=1183067552024-03-28T13:23:38Z2024-03-28T13:23:38ZRE: SignUpScreenletildar slhttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1183122162020-01-21T17:51:46Z2020-01-21T17:51:46ZThanksildar sl2020-01-21T17:51:46ZRE: SignUpScreenletJavier Gamarrahttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1183041632020-01-20T23:55:15Z2020-01-20T23:55:15ZBy default Liferay needs an authenticated user to do that request. You can create a user with only those permissions and use it as a token access or disable the security (that question would go in the general category, won't be of help there).Javier Gamarra2020-01-20T23:55:15ZSignUpScreenletildar slhttps://liferay.dev/en/c/message_boards/find_message?p_l_id=119785333&messageId=1183067542020-01-20T20:53:36Z2020-01-20T20:53:36Z<html><head></head><body>Hi!<br>Liferay 7.2 GA 2 + Android Studio 3.5.3<br>Trying to register in a mobile application.<br><br><strong>signup.xml</strong><br><pre><code><com.liferay.mobile.screens.auth.signup.signupscreenlet android:id="@+id/signup_screenlet" android:layout_width="match_parent" android:layout_height="match_parent" app:anonymousApiPassword="@string/liferay_anonymousApiPassword" app:anonymousApiUserName="@string/liferay_anonymousApiUserName" /></code></pre><br><br><strong>SignUpActivity.java</strong><br><pre><code>public class SignUpActivity extends ThemeActivity implements SignUpListener {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.signup);
SignUpScreenlet screenlet = findViewById(R.id.signup_screenlet);
screenlet.setListener(this);
}
@Override
public void onSignUpFailure(Exception e) {
error(getString(R.string.signup_error), null);
}
@Override
public void onSignUpSuccess(User user) {
info(getString(R.string.sign_up_success_info) + " " + user.getId());
}
}</code></pre><br><strong>LogError</strong><br><br><pre><code>2020-01-20 14:02:09.891 16631-16631/com.example.testforliferay E/LiferayScreens: Could not sign up
com.liferay.mobile.android.exception.AuthenticationException: java.lang.SecurityException
at com.liferay.mobile.android.http.Response.checkPortalException(Response.java:95)
at com.liferay.mobile.android.http.Response.getBody(Response.java:49)
at com.liferay.mobile.android.http.HttpUtil.post(HttpUtil.java:118)
at com.liferay.mobile.android.http.HttpUtil.post(HttpUtil.java:128)
at com.liferay.mobile.android.service.SessionImpl.invoke(SessionImpl.java:102)
at com.liferay.mobile.screens.service.v70.UserService.addUser(UserService.java:78)
at com.liferay.mobile.screens.auth.login.connector.UserConnector70.addUser(UserConnector70.java:44)
at com.liferay.mobile.screens.auth.signup.interactor.SignUpInteractor.sendSignUpRequest(SignUpInteractor.java:103)
at com.liferay.mobile.screens.auth.signup.interactor.SignUpInteractor.execute(SignUpInteractor.java:60)
at com.liferay.mobile.screens.base.interactor.BaseInteractor$1.run(BaseInteractor.java:29)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1133)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:607)
at java.lang.Thread.run(Thread.java:761)
2020-01-20 14:02:09.895 1