This is an automated email from the ASF dual-hosted git repository.
lupeng pushed a commit to branch branch-2.6
in repository https://gitbox.apache.org/repos/asf/hbase.git
The following commit(s) were added to refs/heads/branch-2.6 by this push:
new aba17309de3 HBASE-29540 Unhandled IllegalArgumentException in HBase
Web UI When Accessing table.jsp with Invalid Table Name (#7236) (#7268)
aba17309de3 is described below
commit aba17309de3d32b28f5b18dd903492a1aec364a3
Author: wangxiangdong123 <[email protected]>
AuthorDate: Sat Sep 6 21:07:25 2025 +0800
HBASE-29540 Unhandled IllegalArgumentException in HBase Web UI When
Accessing table.jsp with Invalid Table Name (#7236) (#7268)
Signed-off-by: Dávid Paksy <[email protected]>
Signed-off-by: Pankaj Kumar <[email protected]>
Signed-off-by: Nihal Jain <[email protected]>
Signed-off-by: Peng Lu <[email protected]>
---
.../main/resources/hbase-webapps/master/table.jsp | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/hbase-server/src/main/resources/hbase-webapps/master/table.jsp
b/hbase-server/src/main/resources/hbase-webapps/master/table.jsp
index 024f474fcbe..0a61488cf67 100644
--- a/hbase-server/src/main/resources/hbase-webapps/master/table.jsp
+++ b/hbase-server/src/main/resources/hbase-webapps/master/table.jsp
@@ -172,6 +172,26 @@
</div>
<% return;
} %>
+
+<%
+ // handle the case for fqtn is not null with IllegalArgumentException
message + redirect
+ try {
+ TableName tn = TableName.valueOf(fqtn);
+ TableName.isLegalNamespaceName(tn.getNamespace());
+ TableName.isLegalTableQualifierName(tn.getQualifier());
+ } catch (IllegalArgumentException e) {
+%>
+ <div class="container-fluid content">
+ <div class="row inner_header">
+ <div class="page-header">
+ <h1>Table not legal</h1>
+ </div>
+ </div>
+ <p><hr><p>
+ <jsp:include page="redirect.jsp" />
+ </div>
+<% return;
+ } %>
<%
final String escaped_fqtn = StringEscapeUtils.escapeHtml4(fqtn);